I am using Restlet Version 2.0 Milestone 5 (testing). When i try to create ChallengeResponse and set in ClientResource i get the below warning:
org.restlet.engine.security.AuthenticatorUtils format WARNING: Challenge scheme SID6 not supported by the Restlet engine. Below is the code: Context context = new Context(); context.getParameters().add(ADAPTER_PARAM, ADAPTER_VALUE); ClientResource clientResource = new ClientResource(context, clientUrl); ClientInfo clientInfo = new ClientInfo(); clientInfo.getAcceptedMediaTypes() .add(new Preference<MediaType>(MEDIA_UDS)); clientResource.setClientInfo(clientInfo); Form requestHeaders = new Form(); requestHeaders.add(HEADER_CORRELATION_ID, _responseId); requestHeaders.add(HEADER_DATE, DateUtils.format(new Date())); clientResource.getRequestAttributes().put(ATTRIBUTE_HEADERS, requestHeaders); ChallengeResponse challengeResponse = new ChallengeResponse(ChallengeScheme, "5J17HSDFSFWRWER:WERSDSDSFSDF//dssdfsz"); clientResource.setChallengeResponse(challengeResponse); ChallengeAuthenticator authenticator = new ChallengeAuthenticator(context, ChallengeScheme, "realm"); Now if i comment the ChallengeResponse code and add the scheme in Form directly it works fine. But doing this is a hack. I want to know how i can register my own scheme. below is the code for setting in Form . // This is a hack and should be done with ChallengeResponse /* Form.add("Authorization", "SID6 5J17HSDFSFWRWER:WERSDSDSFSDF//dssdfsz"); */ Appreciate prompt response. Thanks, Cobse -- View this message in context: http://n2.nabble.com/How-to-register-scheme-in-restlet-engine-tp3861417p3861417.html Sent from the Restlet Discuss mailing list archive at Nabble.com. ------------------------------------------------------ http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=2409555