Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mosquitto-dev] Supporting both tls-psk and username/password

Jeff,

Your still trying to connect to the TLS port so you will also need to
have a --cafile or --capath on the command line to point to the CA cert
to identify the broker with (and also enable TLS support)

Ben

On 02/02/17 21:41, Jeff Armstrong wrote:
> I'm trying to set up a broker to allow clients who authenticate either
> by tls-psk OR by username/password. I've configured psk_file, psk_hint,
> and password_file and I've added different users to the psk file and
> password_file.
> 
> Clients using psk work fine, but clients using username and password
> don't. Here is how I'm connecting with the client that fails:
> 
> $ mosquitto_sub -p 8883 -u admin -P password -t '2.1/LOC/+/+/MGR'
> 
> Here is the error log I see in the broker:
> 
> 1486070537: Client connection from ::1 failed: error:140760FC:SSL
> routines:SSL23_GET_CLIENT_HELLO:unknown protocol.
> 
> Is there something else I need to configure to get this to work?
> 
> For some background as to WHY I need to do this: I have external clients
> who only use tls-psk to connect which I have no control over. I also
> need to write my own client, preferably in Go
> (https://github.com/eclipse/paho.mqtt.golang). The problem is that the
> Go libraries don't seem to support tls-psk (and either does the Python
> library), which is why I need support for normal username/password. If
> there is another way I could authenticate using my client I would be
> open to that as well.
> 
> Thanks for any help you can give!
> 
> -- 
> Jeff Armstrong
> Software Engineer
> Greenfield Labs
> 
> 
> _______________________________________________
> mosquitto-dev mailing list
> mosquitto-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from this list, visit
> https://dev.eclipse.org/mailman/listinfo/mosquitto-dev
> 

-- 
http://www.hardill.me.uk/wordpress
http://about.me/hardillb
http://flickr.com/photos/hardillb/
http://last.fm/user/hardillb
https://keybase.io/hardillb


Back to the top