Author: coheigea
Date: Mon Oct 19 13:15:48 2015
New Revision: 1709411
URL: http://svn.apache.org/viewvc?rev=1709411&view=rev
Log:
Minor changes
Conflicts:
ws-security-common/src/main/java/org/apache/wss4j/common/util/XMLUtils.java
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/SignatureEncryptionActionToken.java
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/handler/WSHandler.java
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/processor/EncryptedKeyProcessor.java
webservices/wss4j/branches/2_0_x-fixes/ws-security-policy-stax/src/main/java/org/apache/wss4j/policy/stax/PolicyInputProcessor.java
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/EncryptOutputProcessor.java
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/WSSSignatureOutputProcessor.java
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/SignatureEncryptionActionToken.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/SignatureEncryptionActionToken.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/SignatureEncryptionActionToken.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-common/src/main/java/org/apache/wss4j/common/SignatureEncryptionActionToken.java
Mon Oct 19 13:15:48 2015
@@ -100,7 +100,7 @@ public abstract class SignatureEncryptio
return crypto;
}
- public void setCrypto(Crypto crypto) {
+ public synchronized void setCrypto(Crypto crypto) {
this.crypto = crypto;
}
public String getKeyIdentifier() {
@@ -133,12 +133,15 @@ public abstract class SignatureEncryptio
public void setParts(List<WSEncryptionPart> parts) {
this.parts = parts;
}
- public String getCryptoProperties() {
- return cryptoProperties;
- }
- public void setCryptoProperties(String cryptoProperties) {
+
+ public synchronized void setCryptoProperties(String cryptoProperties) {
this.cryptoProperties = cryptoProperties;
}
+
+ public synchronized String getCryptoProperties() {
+ return cryptoProperties;
+ }
+
public String getTokenType() {
return tokenType;
}
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/handler/WSHandler.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/handler/WSHandler.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/handler/WSHandler.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/handler/WSHandler.java
Mon Oct 19 13:15:48 2015
@@ -207,7 +207,7 @@ public abstract class WSHandler {
actionsToPerform = new ArrayList<HandlerAction>(actions);
Collections.copy(actionsToPerform, actions);
- int signatureIndex = actions.indexOf(WSConstants.SIGN);
+ int signatureIndex = actions.indexOf(signingAction);
actionsToPerform.remove(signingAction);
actionsToPerform.add(signingAction);
reqData.setAppendSignatureAfterTimestamp(true);
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/processor/EncryptedKeyProcessor.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/processor/EncryptedKeyProcessor.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/processor/EncryptedKeyProcessor.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-dom/src/main/java/org/apache/wss4j/dom/processor/EncryptedKeyProcessor.java
Mon Oct 19 13:15:48 2015
@@ -530,7 +530,10 @@ public class EncryptedKeyProcessor imple
// EncryptionAlgorithm cannot be null
if (symEncAlgo == null) {
- data.getBSPEnforcer().handleBSPRule(BSPRule.R5601);
+ LOG.debug("No encryption algorithm was specified in the request");
+ throw new
WSSecurityException(WSSecurityException.ErrorCode.UNSUPPORTED_ALGORITHM,
"badEncAlgo",
+ new Object[] {null});
+
}
// EncryptionAlgorithm must be 3DES, or AES128, or AES256
if (!WSConstants.TRIPLE_DES.equals(symEncAlgo)
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-policy-stax/src/main/java/org/apache/wss4j/policy/stax/PolicyInputProcessor.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-policy-stax/src/main/java/org/apache/wss4j/policy/stax/PolicyInputProcessor.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-policy-stax/src/main/java/org/apache/wss4j/policy/stax/PolicyInputProcessor.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-policy-stax/src/main/java/org/apache/wss4j/policy/stax/PolicyInputProcessor.java
Mon Oct 19 13:15:48 2015
@@ -225,7 +225,7 @@ public class PolicyInputProcessor extend
protected String getId(XMLSecEvent xmlSecEvent) {
XMLSecStartElement xmlSecStartElement = xmlSecEvent.asStartElement();
- if (xmlSecStartElement.getOnElementDeclaredAttributes().size() >= 0) {
+ if (!xmlSecStartElement.getOnElementDeclaredAttributes().isEmpty()) {
Attribute attribute =
xmlSecStartElement.getAttributeByName(WSSConstants.ATT_wsu_Id);
if (attribute != null) {
return attribute.getValue();
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/EncryptOutputProcessor.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/EncryptOutputProcessor.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/EncryptOutputProcessor.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/EncryptOutputProcessor.java
Mon Oct 19 13:15:48 2015
@@ -143,7 +143,7 @@ public class EncryptOutputProcessor exte
@Override
protected SecurePart securePartMatches(XMLSecStartElement
xmlSecStartElement, Map<Object, SecurePart> secureParts) {
- if (xmlSecStartElement.getOnElementDeclaredAttributes().size() >= 0) {
+ if (!xmlSecStartElement.getOnElementDeclaredAttributes().isEmpty()) {
Attribute attribute =
xmlSecStartElement.getAttributeByName(WSSConstants.ATT_wsu_Id);
if (attribute != null) {
SecurePart securePart = secureParts.get(attribute.getValue());
Modified:
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/WSSSignatureOutputProcessor.java
URL:
http://svn.apache.org/viewvc/webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/WSSSignatureOutputProcessor.java?rev=1709411&r1=1709410&r2=1709411&view=diff
==============================================================================
---
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/WSSSignatureOutputProcessor.java
(original)
+++
webservices/wss4j/branches/2_0_x-fixes/ws-security-stax/src/main/java/org/apache/wss4j/stax/impl/processor/output/WSSSignatureOutputProcessor.java
Mon Oct 19 13:15:48 2015
@@ -252,7 +252,7 @@ public class WSSSignatureOutputProcessor
@Override
protected SecurePart securePartMatches(XMLSecStartElement
xmlSecStartElement, Map<Object, SecurePart> secureParts) {
- if (xmlSecStartElement.getOnElementDeclaredAttributes().size() >= 0) {
+ if (!xmlSecStartElement.getOnElementDeclaredAttributes().isEmpty()) {
Attribute attribute =
xmlSecStartElement.getAttributeByName(WSSConstants.ATT_wsu_Id);
if (attribute != null) {
SecurePart securePart = secureParts.get(attribute.getValue());