|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.fzj.unicore.wsrflite.security.DefaultSecurityProperties
de.fzj.unicore.uas.security.UASSecurityProperties
public class UASSecurityProperties
security properties
| Field Summary |
|---|
| Fields inherited from interface de.fzj.unicore.uas.security.IUASSecurityProperties |
|---|
UAS_AUTHORISER, UAS_AUTHORISER_PROXY_SUPPORT, UAS_CHECK_CONSIGNOR_SIGNATURE, UAS_CHECKACCESS, UAS_CHECKACCESS_PDP, UAS_CHECKACCESS_PDPCONFIG, UAS_GATEWAY_ALIAS, UAS_INHANDLER_NAME, UAS_OUTHANDLER_NAME, UAS_REQUIRE_SIGNATURES |
| Fields inherited from interface de.fzj.unicore.wsrflite.security.ISecurityProperties |
|---|
WSRF_SSL, WSRF_SSL_CLIENTAUTH, WSRF_SSL_KEYALIAS, WSRF_SSL_KEYPASS, WSRF_SSL_KEYSTORE, WSRF_SSL_KEYTYPE, WSRF_SSL_TRUSTPASS, WSRF_SSL_TRUSTSTORE, WSRF_SSL_TRUSTTYPE |
| Constructor Summary | |
|---|---|
UASSecurityProperties()
for property lookup, this uses a hierarchy of property sources: - supplied input stream (or file name) - UAS properties - WSRFLite kernel properties |
|
UASSecurityProperties(java.io.InputStream is)
|
|
UASSecurityProperties(java.lang.String propertiesFileName)
|
|
| Method Summary | |
|---|---|
IUASSecurityProperties |
clone()
make a copy of these properties |
protected java.lang.String |
doGetProperty(java.lang.String key)
return named property. |
boolean |
doSignMessage()
for outgoing calls, should the message be signed? |
java.security.cert.X509Certificate[] |
getCertChain()
the full X509 certificate chain of the user |
java.lang.ClassLoader |
getClassLoader()
get the classloader to be used e.g. for dynamically loading security handlers |
java.util.Map<java.lang.String,java.lang.Object> |
getExtraSecurityTokens()
for outgoing calls, get extra security information |
java.security.cert.X509Certificate |
getGatewayCertificate()
get the certificate of the gateway, or null if this is not
configured (using the IUASSecurityProperties.UAS_GATEWAY_ALIAS property) |
java.lang.String |
getInHandlerClassName()
returns the name of the security handler class for incoming messages |
java.lang.String |
getOutHandlerClassName()
returns the name of the security handler class for outbound messages |
java.security.PrivateKey |
getPrivateKey()
returns the private key entry identified by getKeystoreAlias() from the keystore |
java.lang.String |
getProperty(java.lang.String key)
get a property |
java.security.cert.X509Certificate |
getPublicKey()
the X509 public key identified by the specified alias |
javax.security.auth.x500.X500Principal |
getReceiver()
for client calls that need to issue trust delegations, return the X500Principal of the receiver |
java.lang.String |
getRequestedUser()
|
java.util.Map<java.lang.String,java.lang.String> |
getRequestedUserAttributes()
Deprecated. use getRequestedUserAttributes2 |
java.util.Map<java.lang.String,java.lang.String[]> |
getRequestedUserAttributes2()
For outgoing calls, get extra security information This will return a modifyable map, never null. |
java.util.List<eu.unicore.security.etd.TrustDelegation> |
getTrustDelegationTokens()
for outgoing calls, get trust delegations to be passed on or extended |
boolean |
isSslClientAuthenticated()
returns true if SSL mode is enabled. |
boolean |
isSslEnabled()
returns true if SSL mode is enabled. |
boolean |
isTrustDelegationEnabled()
for outgoing calls, will a trust assertion be generated? |
void |
setAddTrustDelegation(boolean addTrustDelegation)
select whether trust delegation is enabled for outgoing messages TODO rename to issueTrustDelegation(boolean value) |
void |
setClassLoader(java.lang.ClassLoader classLoader)
set the classloader to be used e.g. for dynamically loading security handlers |
void |
setExtraSecurityTokens(java.util.Map<java.lang.String,java.lang.Object> extraSecurityTokens)
set extra security tokens to be used in outgoing calls |
void |
setProperty(java.lang.String key,
java.lang.String value)
set a property |
void |
setReceiver(javax.security.auth.x500.X500Principal receiver)
for client calls that need to issue trust delegations, set the X500Principal of the receiver |
void |
setRequestedUser(java.lang.String requestedUserDN)
Sets the user under whose identity you want the request to be invoked. |
void |
setSignMessage(boolean signMessage)
select whether the outgoing message should be signed |
void |
setTrustDelegationTokens(java.util.List<eu.unicore.security.etd.TrustDelegation> tdTokens)
|
java.lang.String |
toString()
|
| Methods inherited from class de.fzj.unicore.wsrflite.security.DefaultSecurityProperties |
|---|
getKeystore, getKeystoreAlias, getKeystorePassword, getKeystoreType, getTruststore, getTruststorePassword, getTruststoreType |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface de.fzj.unicore.wsrflite.security.ISecurityProperties |
|---|
getKeystore, getKeystoreAlias, getKeystorePassword, getKeystoreType, getTruststore, getTruststorePassword, getTruststoreType |
| Constructor Detail |
|---|
public UASSecurityProperties()
public UASSecurityProperties(java.io.InputStream is)
public UASSecurityProperties(java.lang.String propertiesFileName)
throws java.io.IOException
java.io.IOException| Method Detail |
|---|
public IUASSecurityProperties clone()
throws java.lang.CloneNotSupportedException
IUASSecurityProperties
clone in interface IUASSecurityPropertiesclone in interface de.fzj.unicore.wsrflite.security.ISecurityPropertiesclone in class de.fzj.unicore.wsrflite.security.DefaultSecurityPropertiesjava.lang.CloneNotSupportedExceptionpublic java.lang.String getInHandlerClassName()
IUASSecurityProperties
getInHandlerClassName in interface IUASSecurityPropertiespublic java.lang.String getOutHandlerClassName()
IUASSecurityProperties
getOutHandlerClassName in interface IUASSecurityPropertiesprotected java.lang.String doGetProperty(java.lang.String key)
doGetProperty in class de.fzj.unicore.wsrflite.security.DefaultSecurityPropertiespublic java.lang.String getProperty(java.lang.String key)
IUASSecurityProperties
getProperty in interface IUASSecurityProperties
public void setProperty(java.lang.String key,
java.lang.String value)
setProperty in interface IUASSecurityPropertieskey - value - public boolean isSslEnabled()
isSslEnabled in interface de.fzj.unicore.wsrflite.security.ISecurityPropertiesisSslEnabled in class de.fzj.unicore.wsrflite.security.DefaultSecurityPropertiespublic boolean isSslClientAuthenticated()
isSslClientAuthenticated in interface de.fzj.unicore.wsrflite.security.ISecurityPropertiesisSslClientAuthenticated in class de.fzj.unicore.wsrflite.security.DefaultSecurityPropertiespublic java.security.cert.X509Certificate getPublicKey()
IUASSecurityProperties
getPublicKey in interface IUASSecurityPropertiespublic java.security.cert.X509Certificate[] getCertChain()
IUASSecurityProperties
getCertChain in interface IUASSecurityPropertiespublic void setReceiver(javax.security.auth.x500.X500Principal receiver)
IUASSecurityPropertiesX500Principal of the receiver
setReceiver in interface IUASSecurityPropertiespublic javax.security.auth.x500.X500Principal getReceiver()
IUASSecurityPropertiesX500Principal of the receiver
getReceiver in interface IUASSecurityPropertiespublic java.security.PrivateKey getPrivateKey()
getPrivateKey in interface IUASSecurityPropertiespublic java.lang.String toString()
toString in class de.fzj.unicore.wsrflite.security.DefaultSecurityPropertiespublic boolean isTrustDelegationEnabled()
IUASSecurityProperties
isTrustDelegationEnabled in interface IUASSecurityPropertiespublic void setAddTrustDelegation(boolean addTrustDelegation)
IUASSecurityProperties
setAddTrustDelegation in interface IUASSecurityPropertiespublic boolean doSignMessage()
IUASSecurityProperties
doSignMessage in interface IUASSecurityPropertiespublic void setSignMessage(boolean signMessage)
IUASSecurityProperties
setSignMessage in interface IUASSecurityPropertiespublic void setTrustDelegationTokens(java.util.List<eu.unicore.security.etd.TrustDelegation> tdTokens)
public java.util.List<eu.unicore.security.etd.TrustDelegation> getTrustDelegationTokens()
IUASSecurityProperties
getTrustDelegationTokens in interface IUASSecurityPropertiespublic java.security.cert.X509Certificate getGatewayCertificate()
IUASSecurityPropertiesnull if this is not
configured (using the IUASSecurityProperties.UAS_GATEWAY_ALIAS property)
getGatewayCertificate in interface IUASSecurityPropertiespublic java.util.Map<java.lang.String,java.lang.Object> getExtraSecurityTokens()
IUASSecurityProperties
getExtraSecurityTokens in interface IUASSecurityPropertiespublic void setExtraSecurityTokens(java.util.Map<java.lang.String,java.lang.Object> extraSecurityTokens)
IUASSecurityProperties
setExtraSecurityTokens in interface IUASSecurityPropertiespublic void setRequestedUser(java.lang.String requestedUserDN)
IUASSecurityPropertiesNote that if you don't use this method but add trust delegations then the requested user will be implicitly set to the initial issuer (custodian) of the ETD chain. This method it therefore useful when the client doesn't send ETD tokens but has anyway rights to invoke operations on the requestedUser behalf (i.e. because of possession of a trusted agent role in the XUUDB/UVOS).
setRequestedUser in interface IUASSecurityPropertiespublic java.lang.String getRequestedUser()
getRequestedUser in interface IUASSecurityPropertiespublic java.util.Map<java.lang.String,java.lang.String[]> getRequestedUserAttributes2()
IUASSecurityPropertiesnull.
To add an attribute request to a client call, do
sec.getRequestedUserAttributes().put("XLOGIN", "test");
getRequestedUserAttributes2 in interface IUASSecurityProperties@Deprecated public java.util.Map<java.lang.String,java.lang.String> getRequestedUserAttributes()
IUASSecurityPropertiesnull.
To add an attribute request to a client call, do
sec.getRequestedUserAttributes().put("XLOGIN", "test");
getRequestedUserAttributes in interface IUASSecurityPropertiespublic java.lang.ClassLoader getClassLoader()
IUASSecurityProperties
getClassLoader in interface IUASSecurityPropertiespublic void setClassLoader(java.lang.ClassLoader classLoader)
IUASSecurityProperties
setClassLoader in interface IUASSecurityPropertiesclassLoader - - the classloader to use
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||