I have the fallowing code
public Restlet createRoot() {
Router router = new Router(getContext());
Guard guard = new Guard(getContext(), ChallengeScheme.HTTP_BASIC, "XXX
Server");
guard.getSecrets().put("scott", "tiger".toCharArray());
guard.setNext(ItemsResource.class);
router.attach("/items", guard );
return router;
}
When I hit the browser using
https://localhost/items
I get a window to enter username and password.
I put in "scott" and "tiger" and press login.
I keep getting window to enter username and password.After 5 attempts I get a
message on the server side, that the user "scott" is getting locked for 30
mins.
Why is it not accepting the correct username and password
I even used Fiddler's Request Builder. Used the Base64-encoded string of
username scott and and password as tiger, which is c2NvdHQ6dGlnZXI= and sent
the below request
User-Agent: Fiddler
Host: localhost
Authorization: Basic c2NvdHQ6dGlnZXI=
I still get the response as
HTTP/1.1 401 Unauthorized
------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2455223