But it didn't seem to work. I tried to looked up to /var/log/mosquitto/mosquitto.log and it didn't provide detail error:
1539071610: mosquitto version 1.4.10 (build date Fri, 22 Dec 2017 08:19:25 +0000) starting
1539071610: Config loaded from /etc/mosquitto/mosquitto.conf.
1539071611: * auth-plug: startup
1539071611: Configured order: http
1539071611: Opening ipv4 listen socket on port 1883.
1539071611: Opening ipv6 listen socket on port 1883.
1539071618: New connection from 192.168.1.8 on port 1883.
1539071618: New client connected from 192.168.1.8 as mosqsub|4684-SAM (c1, k60).
1539071634: New connection from 192.168.1.117 on port 1883.
1539071634: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071648: Socket error on client 87311790559294, disconnecting.
1539071649: New connection from 192.168.1.117 on port 1883.
1539071649: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071655: Socket error on client 87311790559294, disconnecting.
1539071656: New connection from 192.168.1.117 on port 1883.
1539071656: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071662: Socket error on client 87311790559294, disconnecting.
1539071663: New connection from 192.168.1.117 on port 1883.
1539071663: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071669: Socket error on client 87311790559294, disconnecting.
1539071670: New connection from 192.168.1.117 on port 1883.
1539071670: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071676: Socket error on client 87311790559294, disconnecting.
1539071677: New connection from 192.168.1.117 on port 1883.
1539071677: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071683: Socket error on client 87311790559294, disconnecting.
1539071684: New connection from 192.168.1.117 on port 1883.
1539071684: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071692: Socket error on client 87311790559294, disconnecting.
1539071693: New connection from 192.168.1.117 on port 1883.
1539071693: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071700: Socket error on client 87311790559294, disconnecting.
1539071701: New connection from 192.168.1.117 on port 1883.
1539071701: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071708: Socket error on client 87311790559294, disconnecting.
1539071709: New connection from 192.168.1.117 on port 1883.
1539071709: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071717: Socket error on client 87311790559294, disconnecting.
1539071718: New connection from 192.168.1.117 on port 1883.
1539071718: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071732: Socket error on client 87311790559294, disconnecting.
1539071733: New connection from 192.168.1.117 on port 1883.
1539071733: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071741: Socket error on client 87311790559294, disconnecting.
1539071742: New connection from 192.168.1.117 on port 1883.
1539071742: New client connected from 192.168.1.117 as 87311790559294 (c1, k60).
1539071784: Socket error on client 87311790559294, disconnecting.`
And I still to have access to both sub and pub without username & pwd supplied while it should be not.
Hello there,
I am trying to use http api with the following config: The api url should be like this: https://test.mydomain.com.
auth_plugin /etc/mosquitto/auth-plug.so auth_opt_acl_cacheseconds 0 auth_opt_backends http auth_opt_http_hostname test.mydomain.com auth_opt_http_port 80 auth_opt_http_with_tls true auth_opt_http_basic_auth_key base64usernamewd auth_opt_http_getuser_uri /users auth_opt_http_superuser_uri /superusers auth_opt_http_aclcheck_uri /acl
But it didn't seem to work. I tried to looked up to /var/log/mosquitto/mosquitto.log and it didn't provide detail error:
1539071610: mosquitto version 1.4.10 (build date Fri, 22 Dec 2017 08:19:25 +0000) starting 1539071610: Config loaded from /etc/mosquitto/mosquitto.conf. 1539071611: * auth-plug: startup 1539071611: Configured order: http
1539071611: Opening ipv4 listen socket on port 1883. 1539071611: Opening ipv6 listen socket on port 1883. 1539071618: New connection from 192.168.1.8 on port 1883. 1539071618: New client connected from 192.168.1.8 as mosqsub|4684-SAM (c1, k60). 1539071634: New connection from 192.168.1.117 on port 1883. 1539071634: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071648: Socket error on client 87311790559294, disconnecting. 1539071649: New connection from 192.168.1.117 on port 1883. 1539071649: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071655: Socket error on client 87311790559294, disconnecting. 1539071656: New connection from 192.168.1.117 on port 1883. 1539071656: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071662: Socket error on client 87311790559294, disconnecting. 1539071663: New connection from 192.168.1.117 on port 1883. 1539071663: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071669: Socket error on client 87311790559294, disconnecting. 1539071670: New connection from 192.168.1.117 on port 1883. 1539071670: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071676: Socket error on client 87311790559294, disconnecting. 1539071677: New connection from 192.168.1.117 on port 1883. 1539071677: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071683: Socket error on client 87311790559294, disconnecting. 1539071684: New connection from 192.168.1.117 on port 1883. 1539071684: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071692: Socket error on client 87311790559294, disconnecting. 1539071693: New connection from 192.168.1.117 on port 1883. 1539071693: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071700: Socket error on client 87311790559294, disconnecting. 1539071701: New connection from 192.168.1.117 on port 1883. 1539071701: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071708: Socket error on client 87311790559294, disconnecting. 1539071709: New connection from 192.168.1.117 on port 1883. 1539071709: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071717: Socket error on client 87311790559294, disconnecting. 1539071718: New connection from 192.168.1.117 on port 1883. 1539071718: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071732: Socket error on client 87311790559294, disconnecting. 1539071733: New connection from 192.168.1.117 on port 1883. 1539071733: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071741: Socket error on client 87311790559294, disconnecting. 1539071742: New connection from 192.168.1.117 on port 1883. 1539071742: New client connected from 192.168.1.117 as 87311790559294 (c1, k60). 1539071784: Socket error on client 87311790559294, disconnecting.`
And I still to have access to both sub and pub without username & pwd supplied while it should be not.