Examples of validateAuthenticationRequest()


Examples of org.apache.stratos.rest.endpoint.oauth2.ValidationServiceClient.validateAuthenticationRequest()

            HttpHeaders httpHeaders = new HttpHeadersImpl(message);
            String header = httpHeaders.getRequestHeaders().getFirst("Authorization");
            // if the authorization token has Bearer..
            if (header.startsWith("Bearer ")) {
                String accessToken = header.substring(7).trim();
                respDTO = validationServiceClient.validateAuthenticationRequest(accessToken); //TODO : send scope params
                boolean valid = respDTO.getValid();
                if (!valid) {
                    // authorization failure..
                    return Response.status(Response.Status.FORBIDDEN).build();
                }
View Full Code Here

Examples of org.wso2.carbon.identity.samples.oauth.admin.OAuthServiceStub.validateAuthenticationRequest()

        oauth = new OAuthServiceStub(configCtx, serviceURL);
        client = oauth._getServiceClient();
        option = client.getOptions();
        option.setManageSession(true);
        option.setProperty(org.apache.axis2.transport.http.HTTPConstants.COOKIE_STRING, authCookie);
        return oauth.validateAuthenticationRequest(consumer, shortLivedToken);
    }

}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.