You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by ru...@apache.org on 2006/03/25 12:01:24 UTC
svn commit: r388738 - in /webservices/axis2/trunk/java/modules/security: ./
src/META-INF/ src/org/apache/axis2/security/trust/impl/
test-resources/trust/impl/
Author: ruchithf
Date: Sat Mar 25 03:01:22 2006
New Revision: 388738
URL: http://svn.apache.org/viewcvs?rev=388738&view=rev
Log:
Adding the resource files required by the generated STS
Added:
webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/
webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties (with props)
webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/wss4j.keystore (with props)
Modified:
webservices/axis2/trunk/java/modules/security/maven.xml
webservices/axis2/trunk/java/modules/security/src/META-INF/sts-services.xml
webservices/axis2/trunk/java/modules/security/src/org/apache/axis2/security/trust/impl/SCTIssuer.java
Modified: webservices/axis2/trunk/java/modules/security/maven.xml
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/security/maven.xml?rev=388738&r1=388737&r2=388738&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/security/maven.xml (original)
+++ webservices/axis2/trunk/java/modules/security/maven.xml Sat Mar 25 03:01:22 2006
@@ -71,6 +71,8 @@
<copy file="${maven.repo.local}/wss4j/jars/wss4j-${wss4j.version}.jar" todir="target/sts/lib"/>
<copy file="target/classes/META-INF/sts-services.xml" toFile="target/sts/META-INF/services.xml"/>
+ <copy file="test-resources/trust/impl/sctIssuer.properties" toFile="target/sts/sctIssuer.properties"/>
+ <copy file="test-resources/trust/impl/wss4j.keystore" toFile="target/sts/wss4j.keystore"/>
<jar jarfile="target/SecurityTokenService.aar" basedir="target/sts/">
<include name="**/*"/>
Modified: webservices/axis2/trunk/java/modules/security/src/META-INF/sts-services.xml
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/security/src/META-INF/sts-services.xml?rev=388738&r1=388737&r2=388738&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/security/src/META-INF/sts-services.xml (original)
+++ webservices/axis2/trunk/java/modules/security/src/META-INF/sts-services.xml Sat Mar 25 03:01:22 2006
@@ -17,4 +17,12 @@
</issuer>
</token-dispatcher-configuration>
</parameter>
+
+ <!-- Configuration of org.apache.axis2.security.trust.impl.SCTIssuer -->
+ <parameter name="sct-issuer-config">
+ <sct-issuer-config>
+ <proofToken>EncryptedKey</proofToken>
+ <crypto-properties>sctIssuer.properties</crypto-properties>
+ </sct-issuer-config>
+ </parameter>
</service>
Modified: webservices/axis2/trunk/java/modules/security/src/org/apache/axis2/security/trust/impl/SCTIssuer.java
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/security/src/org/apache/axis2/security/trust/impl/SCTIssuer.java?rev=388738&r1=388737&r2=388738&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/security/src/org/apache/axis2/security/trust/impl/SCTIssuer.java (original)
+++ webservices/axis2/trunk/java/modules/security/src/org/apache/axis2/security/trust/impl/SCTIssuer.java Sat Mar 25 03:01:22 2006
@@ -50,7 +50,7 @@
public final static String SCT_ISSUER_CONFIG_PARAM = "sct-issuer-config";
/**
- * Issue a SecuritycontextToken based on the wsse:Signature
+ * Issue a SecuritycontextToken based on the wsse:Signature or wsse:UsernameToken
*
* This will support returning the SecurityContextToken with the following
* types of wst:RequestedProof tokens:
@@ -90,7 +90,8 @@
Parameter param = inMsgCtx.getParameter(SCT_ISSUER_CONFIG_PARAM);
SCTIssuerConfig config = new SCTIssuerConfig(param
- .getParameterElement());
+ .getParameterElement().getFirstChildWithName(
+ new QName(SCT_ISSUER_CONFIG_PARAM)));
if(ENCRYPTED_KEY.equals(config.proofTokenType)) {
SOAPEnvelope responseEnv = this.doEncryptedKey(config, inMsgCtx, principal);
return responseEnv;
@@ -141,8 +142,18 @@
}
+
+ public String getResponseAction(OMElement request, MessageContext inMsgCtx) throws TrustException {
+ return Constants.RSTR_ACTON_SCT;
+ }
+
+
+ /**
+ * SCTIssuer Configuration processor
+ *
+ */
protected class SCTIssuerConfig {
protected String proofTokenType = SCTIssuer.ENCRYPTED_KEY;
@@ -153,13 +164,6 @@
new QName("proofToken")).next();
this.proofTokenType = proofTokenElem.getText();
}
- }
-
-
-
-
- public String getResponseAction(OMElement request, MessageContext inMsgCtx) throws TrustException {
- return Constants.RSTR_ACTON_SCT;
}
}
Added: webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties?rev=388738&view=auto
==============================================================================
--- webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties (added)
+++ webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties Sat Mar 25 03:01:22 2006
@@ -0,0 +1,4 @@
+org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin
+org.apache.ws.security.crypto.merlin.keystore.type=jks
+org.apache.ws.security.crypto.merlin.keystore.password=security
+org.apache.ws.security.crypto.merlin.file=wss4j.keystore
Propchange: webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/sctIssuer.properties
------------------------------------------------------------------------------
svn:executable = *
Added: webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/wss4j.keystore
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/wss4j.keystore?rev=388738&view=auto
==============================================================================
Binary file - no diff available.
Propchange: webservices/axis2/trunk/java/modules/security/test-resources/trust/impl/wss4j.keystore
------------------------------------------------------------------------------
svn:mime-type = application/octet-stream