Uploaded image for project: 'Qpid Proton'
  1. Qpid Proton
  2. PROTON-1473

[cpp] Cryptic error message when connection fails because server end requires SASL

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • proton-c-0.17.0
    • proton-c-0.29.0
    • cpp-binding
    • Fedora 25
      Client: examples/cpp/helloworld
      Server: Dispatch router listener configured with authenticatePeer: yes and a suitable common sasl mechanism

    Description

      If you specify the URL with no credentials:

      cpp> ./helloworld 192.168.0.16:5674/aaa
      amqp:connection:framing-error: AMQP header mismatch: Insufficient data to determine protocol [''] (connection aborted)
      

      This error message is true in a strict sense but does not give a user much of a clue about what's wrong.

      The same setup with good URL credentials:

      cpp> ./helloworld user:password@192.168.0.16:5674/aaa
      Hello World!
      

      The same setup with bad URL credentials:

      cpp> ./helloworld user:passwords@192.168.0.16:5674/aaa
      amqp:unauthorized-access: Authentication failed [mech=DIGEST-MD5]
      

      This error message is good.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            astitcher Andrew Stitcher
            chug Charles E. Rolke
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment