private String socialRPSupportsOPConfig(String key, ArrayList<String> values) {

        String rpSupportedSignatureAlgorithms = "RS256";
        String rpSupportedTokenEndpointAuthMethods = "client_secret_post client_secret_basic";
        String rpSupportedScopes = "openid profile email";

        if ("alg".equals(key) && values != null) {
            for (String value : values) {
                if (rpSupportedSignatureAlgorithms.contains(value)) {
                    return value;
                }
            }
        }

        if ("authMethod".equals(key) && values != null) {
            for (String value : values) {
                //value = matchingRPValue(value);
                if (rpSupportedTokenEndpointAuthMethods.contains(value)) {
                    return value;
                }
            }
        }

        if ("scope".equals(key) && values != null) {
            String scopes = null;
            for (String value : values) {
                if (rpSupportedScopes.contains(value)) {
                    if (scopes == null) {
                        scopes = value;
                    }
                    else {
                        scopes = scopes + " " + value;
                    }
                }
            }
            return scopes;
        }
        return null;
    }
private String socialRPSupportsOPConfig ( String key , ArrayList < String > values ) { String rpSupportedSignatureAlgorithms = "RS256" ; String rpSupportedTokenEndpointAuthMethods = "client_secret_post client_secret_basic" ; String rpSupportedScopes = "openid profile email" ; if ( "alg" . equals ( key ) && values != null ) { for ( String value : values ) { if ( rpSupportedSignatureAlgorithms . contains ( value ) ) { return value ; } } } if ( "authMethod" . equals ( key ) && values != null ) { for ( String value : values ) { if ( rpSupportedTokenEndpointAuthMethods . contains ( value ) ) { return value ; } } } if ( "scope" . equals ( key ) && values != null ) { String scopes = null ; for ( String value : values ) { if ( rpSupportedScopes . contains ( value ) ) { if ( scopes == null ) { scopes = value ; } else { scopes = scopes + " " + value ; } } } return scopes ; } return null ; }
@param discoveryTokenepAuthMethod
@return