public class OAuthServerKeyManagerImpl extends DefaultComponent implements OAuthServerKeyManager
OAuthServerKeyManager
interface. Manages an extention point to configure RSA Key Pair.
Shindig/Nuxeo HMAC shared secret is dynamically generated at startup time (and shared between Nuxeo OAUth Filter and
Shindig directly in memory).Modifier and Type | Class and Description |
---|---|
protected class |
OAuthServerKeyManagerImpl.InternalNuxeoOAuthConsumer |
Modifier and Type | Field and Description |
---|---|
protected NuxeoOAuthConsumer |
consumer |
protected String |
internalKey |
protected String |
internalSecret |
protected ServerKeyDescriptor |
serverKeyDescriptor |
static String |
XP_SERVER_KEY |
lastModified
Constructor and Description |
---|
OAuthServerKeyManagerImpl() |
Modifier and Type | Method and Description |
---|---|
void |
activate(ComponentContext context)
Activates the component.
|
String |
getBarePrivateKey()
Returns the Private Key used by Nuxeo server to do RSA Signing.
|
String |
getBarePublicCertificate()
Returns the Public Key certificate used by Nuxeo server to do RSA Signing.
|
NuxeoOAuthConsumer |
getInternalConsumer()
Returns the
NuxeoOAuthConsumer representing local (embedded) Shindig instance. |
String |
getInternalKey()
Returns the consumerKey used in Shindig => Nuxeo sign fetch.
|
String |
getInternalSecret()
Returns the consumerSecret (HMAC) used in Shindig => Nuxeo sign fetch.
|
String |
getKeyName()
Returns key name (not really used).
|
String |
getPrivateKey()
Returns the Private Key used by Nuxeo server to do RSA Signing.
|
String |
getPublicKeyCertificate()
Returns the Public Key certificate used by Nuxeo server to do RSA Signing.
|
void |
registerContribution(Object contribution,
String extensionPoint,
ComponentInstance contributor) |
protected String |
stripOpenSSL(String key) |
void |
unregisterContribution(Object contribution,
String extensionPoint,
ComponentInstance contributor) |
deactivate, getAdapter, getLastModified, registerExtension, setLastModified, setModifiedNow, start, stop, unregisterExtension
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
applicationStarted, getApplicationStartedOrder
protected ServerKeyDescriptor serverKeyDescriptor
public static final String XP_SERVER_KEY
protected NuxeoOAuthConsumer consumer
protected String internalKey
protected String internalSecret
public OAuthServerKeyManagerImpl()
public void activate(ComponentContext context)
Component
This method is called by the runtime when a component is activated.
activate
in interface Component
activate
in class DefaultComponent
context
- the runtime contextpublic void registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor)
registerContribution
in class DefaultComponent
public void unregisterContribution(Object contribution, String extensionPoint, ComponentInstance contributor)
unregisterContribution
in class DefaultComponent
public String getPublicKeyCertificate()
OAuthServerKeyManager
getPublicKeyCertificate
in interface OAuthServerKeyManager
public String getBarePublicCertificate()
OAuthServerKeyManager
getBarePublicCertificate
in interface OAuthServerKeyManager
public String getPrivateKey()
OAuthServerKeyManager
getPrivateKey
in interface OAuthServerKeyManager
public String getBarePrivateKey()
OAuthServerKeyManager
getBarePrivateKey
in interface OAuthServerKeyManager
public String getKeyName()
OAuthServerKeyManager
getKeyName
in interface OAuthServerKeyManager
protected String stripOpenSSL(String key)
public String getInternalKey()
OAuthServerKeyManager
getInternalKey
in interface OAuthServerKeyManager
public String getInternalSecret()
OAuthServerKeyManager
getInternalSecret
in interface OAuthServerKeyManager
public NuxeoOAuthConsumer getInternalConsumer()
OAuthServerKeyManager
NuxeoOAuthConsumer
representing local (embedded) Shindig instance.getInternalConsumer
in interface OAuthServerKeyManager
Copyright © 2017 Nuxeo. All rights reserved.