Skip to content

HttpAuthorizer only accepts auth responses with status 200 OK #62

@hovsater

Description

@hovsater

Currently, the HttpAuthorizer only accepts auth responses that have the HTTP status 200 OK. See https://github.com/pusher/pusher-websocket-java/blob/master/src/main/java/com/pusher/client/util/HttpAuthorizer.java#L141.

If an auth endpoint returns a correct auth signature but the response status is 201 Created, the HttpAuhorizer will simply fail the authorization. I went through the documentation of auth signatures but couldn't find any references to what status code the auth endpoint is expected to return.

If the only valid status code is 200 OK, I'd think it would be great to add it to the documentation. If, 201 OK is considered a valid status code as well, I'd be happy to create a pull request for it.

Cheers!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions