How to connect STAN to NATS using NKeys?

815 views Asked by At

We're setting up a NATS and STAN cluster. The STAN cluster needs to connect to our NATS cluster, obviously. But now I'm having trouble to authenticate, when connecting the STAN cluster to the NATS cluster.

We are using NKeys for authentication (https://docs.nats.io/developing-with-nats/security/nkey). When I try to connect with the STAN credentials with the python client (nats.py), then I have no problem at all.

STAN asks for a credentials file for authentication. I tried giving a file with only the seed, also seed and user pubkey... How should I do it?

Thanks for the help in advance!

1

There are 1 answers

0
SimonVHB On BEST ANSWER

https://github.com/nats-io/nats-streaming-server/issues/1095

Asked the question on GitHub. Nkeys are not supported by NATS Streaming. JWT is the only option.