public class OAuth2Client extends Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
autoGrant |
protected boolean |
enabled |
protected String |
id |
protected static Pattern |
LOCALHOST_PATTERN |
protected String |
name |
protected List<String> |
redirectURIs |
protected String |
secret |
Modifier | Constructor and Description |
---|---|
protected |
OAuth2Client(String name,
String id,
String secret,
List<String> redirectURIs,
boolean autoGrant,
boolean enabled) |
Modifier and Type | Method and Description |
---|---|
static OAuth2Client |
fromDocumentModel(DocumentModel doc) |
String |
getId() |
String |
getName() |
List<String> |
getRedirectURIs() |
boolean |
isAutoGrant() |
boolean |
isEnabled() |
static boolean |
isRedirectURIValid(String redirectURI)
A redirect URI is considered as valid if and only if:
It is not empty
It starts with https, e.g.
|
boolean |
isValidWith(String clientId,
String clientSecret) |
String |
toString() |
protected static final Pattern LOCALHOST_PATTERN
protected List<String> redirectURIs
protected boolean autoGrant
protected boolean enabled
public List<String> getRedirectURIs()
public boolean isAutoGrant()
public boolean isEnabled()
public static OAuth2Client fromDocumentModel(DocumentModel doc)
public static boolean isRedirectURIValid(String redirectURI)
public boolean isValidWith(String clientId, String clientSecret)
Copyright © 2018 Nuxeo. All rights reserved.