protected RefreshToken doCreateNewRefreshToken(ServerAccessToken at) { RefreshToken rt = new RefreshToken(at.getClient(), refreshTokenLifetime); if (at.getAudiences() != null) { List<String> audiences = new LinkedList<>(); audiences.addAll(at.getAudiences()); rt.setAudiences(audiences); } rt.setGrantType(at.getGrantType()); if (at.getScopes() != null) { List<OAuthPermission> scopes = new LinkedList<>(); scopes.addAll(at.getScopes()); rt.setScopes(scopes); } rt.setGrantCode(at.getGrantCode()); rt.setNonce(at.getNonce()); rt.setSubject(at.getSubject()); rt.setClientCodeVerifier(at.getClientCodeVerifier()); return rt; }
protected RefreshToken doCreateNewRefreshToken(ServerAccessToken at) { RefreshToken rt = new RefreshToken(at.getClient(), refreshTokenLifetime); if (at.getAudiences() != null) { List<String> audiences = new LinkedList<>(); audiences.addAll(at.getAudiences()); rt.setAudiences(audiences); } rt.setGrantType(at.getGrantType()); if (at.getScopes() != null) { List<OAuthPermission> scopes = new LinkedList<>(); scopes.addAll(at.getScopes()); rt.setScopes(scopes); } rt.setGrantCode(at.getGrantCode()); rt.setNonce(at.getNonce()); rt.setSubject(at.getSubject()); rt.setClientCodeVerifier(at.getClientCodeVerifier()); return rt; }
if (at.getGrantCode() != null) { claims.setClaim(OAuthConstants.AUTHORIZATION_CODE_GRANT, at.getGrantCode());
if (st.getGrantCode() != null) { code = st.getGrantCode(); } else {
if (at.getGrantCode() != null) { claims.setClaim(OAuthConstants.AUTHORIZATION_CODE_GRANT, at.getGrantCode());
if (st.getGrantCode() != null) { code = st.getGrantCode(); } else {
protected ServerAccessToken(ServerAccessToken token, String key) { super(token.getTokenType(), key, token.getExpiresIn(), token.getIssuedAt(), token.getRefreshToken(), token.getParameters()); this.client = token.getClient(); this.grantType = token.getGrantType(); this.scopes = token.getScopes(); this.audiences = token.getAudiences(); this.subject = token.getSubject(); this.responseType = token.getResponseType(); this.clientCodeVerifier = token.getClientCodeVerifier(); this.nonce = token.getNonce(); this.grantCode = token.getGrantCode(); }
protected ServerAccessToken(ServerAccessToken token, String key) { super(token.getTokenType(), key, token.getExpiresIn(), token.getIssuedAt(), token.getRefreshToken(), token.getParameters()); this.client = token.getClient(); this.grantType = token.getGrantType(); this.scopes = token.getScopes(); this.audiences = token.getAudiences(); this.subject = token.getSubject(); this.responseType = token.getResponseType(); this.clientCodeVerifier = token.getClientCodeVerifier(); this.nonce = token.getNonce(); this.grantCode = token.getGrantCode(); }