A couple of suggestions: - Try running `pluginviewer -c` to see if SCRAM-SHA-256 shows up as supported. - Make sure e.g. using ccmake that your proton library is correctly built to include sasl - Turn on protocol tracing in order to see what mechanisms are actually being offered by the server
On Wed, Mar 20, 2024 at 1:38 PM abdelrhman abdelhmaed <abdel....@gmail.com> wrote: > > after installing Cyrus i get the following message when i try to > connect to Broker: > > amqp:unauthorized-access: Authentication failed [mech=SCRAM-SHA-256] > std::string MECHANISM = "SCRAM-SHA-256"; > ConnectionOptions.sasl_allowed_mechs(MECHANISM); > ConnectionOptions.sasl_allow_insecure_mechs(true); > ConnectionOptions.sasl_enabled(true); > ConnectionOptions.user("guest"); > ConnectionOptions.password("guest"); > > when i change the mechanism to PLAIN, the client connect the broker > without any problem > std::string MECHANISM = "PLAIN"; > ConnectionOptions.sasl_allowed_mechs(MECHANISM); > ConnectionOptions.sasl_allow_insecure_mechs(true); > ConnectionOptions.sasl_enabled(true); > ConnectionOptions.user("guest"); > ConnectionOptions.password("guest"); > > i have configured the broker to support both PLAIN and SCRAM-SHA-256 > > the broker.xml > <!-- AMQP Acceptor. Listens on default AMQP port for AMQP traffic.--> > <acceptor name="amqp">tcp://0.0.0.0:7014?saslMechanisms=PLAIN, > SCRAM-SHA-256,tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=AMQP;useEpoll=true;amqpCredits=1000;amqpLowCredits=300;amqpMinLargeMessageSize=102400;amqpDuplicateDetection=true > </acceptor> > > > On 2024/03/19 07:57:31 abdelrhman abdelhmaed wrote: > > Hi, > > I am using the qpid proton library to connect to Broker( Apache ActiveMQ > > Artemis). > > The authentication mechanism must be SALS SCRAM_SHA-256. > > i tried to configure Qpid proton client to use this mechanism via the > > following methods > > > > std::string MECHANISM = "SCRAM-SHA-256"; > > ConnectionOptions.sasl_allowed_mechs(MECHANISM); > > ConnectionOptions.sasl_allow_insecure_mechs(true); > > ConnectionOptions.sasl_enabled(true); > > ConnectionOptions.user("guest"); > > ConnectionOptions.password("guest"); > > > > but it dont work out. I got the following error message > > > > amqp:unauthorized-access: Authentication failed [mech=none] > > > > so my question wether qpid proton client support this mechanism and if > so, > > how i am supposed to configure it > > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@qpid.apache.org For additional commands, e-mail: users-h...@qpid.apache.org