Search in sources :

Example 1 with JwtRequestCodeGrant

use of org.apache.cxf.rs.security.oauth2.grants.code.JwtRequestCodeGrant in project cxf by apache.

the class ClientCodeRequestFilter method prepareCodeGrant.

private AuthorizationCodeGrant prepareCodeGrant(String codeParam, URI absoluteRedirectUri) {
    if (codeRequestJoseProducer == null) {
        return new AuthorizationCodeGrant(codeParam, absoluteRedirectUri);
    }
    JwtRequestCodeGrant grant = new JwtRequestCodeGrant(codeParam, absoluteRedirectUri, consumer.getClientId());
    grant.setClientSecret(consumer.getClientSecret());
    grant.setJoseProducer(codeRequestJoseProducer);
    return grant;
}
Also used : JwtRequestCodeGrant(org.apache.cxf.rs.security.oauth2.grants.code.JwtRequestCodeGrant) AuthorizationCodeGrant(org.apache.cxf.rs.security.oauth2.grants.code.AuthorizationCodeGrant)

Aggregations

AuthorizationCodeGrant (org.apache.cxf.rs.security.oauth2.grants.code.AuthorizationCodeGrant)1 JwtRequestCodeGrant (org.apache.cxf.rs.security.oauth2.grants.code.JwtRequestCodeGrant)1