I am using the use-authorization-key, have granted the user with publish/subscribe permission. I got connection failed[code: not authorized]. Do you know why it fails? What the password salt, iteration here?
The client information is
var options = new HiveMQClientOptions
ClientId = “Client_1”,
Host = hostName,
Port = 1883,
UseTLS = false,
UserName = “admin2”,
Password = “hivemq”,
CleanStart = false
The user table is this:
id username password
1 admin1 hivemq
2 admin2 hivemq
The permission table is:
id topic publish_allowed subscribe_allowed
1 t1 true false
2 t1 false true
The user_permission table is:
the configure is
I’m sorry to hear that you’re facing difficulties.
To help you troubleshoot and identify the root cause, please follow these steps:
- Update HiveMQ Broker Log Level to DEBUG: You can find detailed instructions on how to change the log level in the HiveMQ user guide here.
- Enable ESE Access Log: The Enterprise Security Extension (ESE) access log is crucial for diagnosing authentication issues. You can enable it by following the steps outlined here.
- Stop and start the Broker: After making the above changes, be sure to restart the broker to apply the configurations.
Once these steps are completed, check the hivemq.log and access/access.log files for relevant log statements. These logs should provide valuable information about why the login attempts are failing.
I hope this guidance proves helpful in resolving your issue.
Dasha from HvieMQ team