Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stomp-Client: add authentication to connection process #18

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

wherget
Copy link

@wherget wherget commented Sep 5, 2013

This should fix #15

Known issues: you can't have passwords or usernames with colons in them. (Anyone know of suitable framework code to parse a URI.getUserInfo() in a standards-compliant way?)

@swistaczek
Copy link

👍


@Override
public String getPassword() {
return client.getAuthentiactionPassword();
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a typo, should be client.getAuthenticationPassword().

@wherget
Copy link
Author

wherget commented Nov 27, 2013

An Idea I had to get around the colon-separation issue is to require username and password to be url-encoded and throw an error if there's more than one colon in the getUserInfo() string. What do you think?

This should now be more compliant to RFC3986.
RFC3986 (3.2.1) states that the username ends at the first colon,
and everything after that is to be considered parameters for the
authorization scheme. (Here, it will be the password only.)
@wherget
Copy link
Author

wherget commented Jan 28, 2014

I had a good re-read of RFC3986 (URI syntax) and rewrote the Authorization extraction to reflect that.
URL en/decoding ist done by the URI class already, so if you have no remaining issues, I'd be glad if you could merge those changes for the next version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support for username & password authentication in stomp-client
3 participants