Created attachment 756658 [details] server.log Description of problem: I am not able to login through REST API as a LDAP user when this LDAP user did not yet logged in through UI => does not yet exist in rhq database. Version-Release number of selected component (if applicable): RHQ 4.8-master How reproducible:always Steps to Reproduce: 1.have a LDAP user, not yet "imported" to RHQ 2.login to REST API Actual results: you get server errror with UndeclaredThrowable Expected results:user should be able to login Additional info:
I understand this is the same restriction as for the CLI
master 764f68b5674 now prints a message for the LDAP user case: /devel/ZwitscherA hrupp$ curl -i -u user:pass http://localhost:7080/rest/.json HTTP/1.1 403 Forbidden Server: Apache-Coyote/1.1 Content-Type: application/json Transfer-Encoding: chunked Date: Tue, 04 Jun 2013 12:29:18 GMT {"message":"User was authorized, but has no rights for the operation. If this is an LDAP user, the user needs to log in to the UI and complete registration."} If the user is completely invalid we return a normal 401 response (actually the container does this for us)
We should open a new BZ that lists that restriction for CLI and REST.