Quantcast
Channel: Active questions tagged ubuntu - Stack Overflow
Viewing all articles
Browse latest Browse all 6096

Can't create new roles using mosquitto dynamic security Connection error: Not authorized

$
0
0

The permissions on my dynamic-security.json file is the following:

-rw-r--r-- 1 mosquitto mosquitto 1247 Mar  6 06:51 dynamic-security.json

After trying to add a new role:

mosquitto_ctrl -u myadmin -P admin333 dynsec createRole firstRole

Also tried:

sudo mosquitto_ctrl -u myadmin -P <mypassword> dynsec createRole firstRole

I also tried it with all permissions allowed, and with the owner being the root. It all gave me the same error.

Connection error: Not authorized

The dynamic-security.json file was generated with:

sudo mosquitto_ctrl dynsec init /var/lib/mosquitto/dynamic-security.json myadmin

And this is the contents of the mosquitto.conf file:

persistence truepersistence_location /etc/mosquitto/datauser mosquittolistener 1883per_listener_settings falseallow_anonymous false password_file /etc/mosquitto/conf.d/credentialslog_dest file /etc/mosquitto/log/mosquitto.loglog_dest stdoutplugin /usr/lib/x86_64-linux-gnu/mosquitto_dynamic_security.soplugin_opt_config_file /usr/lib/x86_64-linux-gnu/dynamic-security.json

Viewing all articles
Browse latest Browse all 6096

Trending Articles