result = 31 * result + keyIdentifierValueType.hashCode(); String keyIdentifierValue = getKeyIdentifierValue(); if (keyIdentifierValue != null) { result = 31 * result + keyIdentifierValue.hashCode();
tokenId = str.getReference().getURI(); } else if(str.containsKeyIdentifier()){ tokenId = str.getKeyIdentifierValue(); tokenId = str.getKeyIdentifierValue();
result = 31 * result + keyIdentifierValueType.hashCode(); String keyIdentifierValue = getKeyIdentifierValue(); if (keyIdentifierValue != null) { result = 31 * result + keyIdentifierValue.hashCode();
private void processValidateTarget()throws TrustException{ OMElement validateTargetElem = this.rstElement .getFirstChildWithName(new QName(this.wstNs, RahasConstants.LocalNames.VALIDATE_TARGET)); if (validateTargetElem != null) { OMElement strElem = validateTargetElem.getFirstChildWithName(new QName(WSConstants.WSSE_NS, "SecurityTokenReference")); Element elem = (Element)OMXMLBuilderFactory.createStAXOMBuilder( OMAbstractFactory.getMetaFactory(OMAbstractFactory.FEATURE_DOM).getOMFactory(), strElem.getXMLStreamReader()).getDocumentElement(); try { SecurityTokenReference str = new SecurityTokenReference((Element)elem); if (str.containsReference()) { tokenId = str.getReference().getURI(); } else if(str.containsKeyIdentifier()){ tokenId = str.getKeyIdentifierValue(); } } catch (WSSecurityException e) { throw new TrustException("errorExtractingTokenId",e); } } }
valueType = ref.getValueType(); } else { uri = getKeyIdentifierValue(); valueType = getKeyIdentifierValueType();
/** * Create a WSDerivedKeyTokenPrincipal from this DerivedKeyToken object */ public Principal createPrincipal() throws WSSecurityException { WSDerivedKeyTokenPrincipal principal = new WSDerivedKeyTokenPrincipal(getID()); principal.setNonce(getNonce()); principal.setLabel(getLabel()); principal.setLength(getLength()); principal.setOffset(getOffset()); principal.setAlgorithm(getAlgorithm()); String basetokenId = null; SecurityTokenReference securityTokenReference = getSecurityTokenReference(); if (securityTokenReference.containsReference()) { basetokenId = securityTokenReference.getReference().getURI(); if (basetokenId.charAt(0) == '#') { basetokenId = basetokenId.substring(1); } } else { // KeyIdentifier basetokenId = securityTokenReference.getKeyIdentifierValue(); } principal.setBasetokenId(basetokenId); return principal; }
valueType = ref.getValueType(); } else { uri = getKeyIdentifierValue(); valueType = getKeyIdentifierValueType();
/** * Create a WSDerivedKeyTokenPrincipal from this DerivedKeyToken object */ public Principal createPrincipal() throws WSSecurityException { WSDerivedKeyTokenPrincipal principal = new WSDerivedKeyTokenPrincipal(getID()); principal.setNonce(getNonce()); principal.setLabel(getLabel()); principal.setLength(getLength()); principal.setOffset(getOffset()); principal.setAlgorithm(getAlgorithm()); String basetokenId = null; SecurityTokenReference securityTokenReference = getSecurityTokenReference(); if (securityTokenReference.containsReference()) { basetokenId = securityTokenReference.getReference().getURI(); if (basetokenId.charAt(0) == '#') { basetokenId = basetokenId.substring(1); } } else { // KeyIdentifier basetokenId = securityTokenReference.getKeyIdentifierValue(); } principal.setBasetokenId(basetokenId); return principal; }
WSDocInfo wsDocInfo ) throws WSSecurityException { String keyIdentifierValue = secRef.getKeyIdentifierValue(); String type = secRef.getKeyIdentifierValueType(); WSSecurityEngineResult result = wsDocInfo.getResult(keyIdentifierValue);
WSDocInfo wsDocInfo ) throws WSSecurityException { String keyIdentifierValue = secRef.getKeyIdentifierValue(); String type = secRef.getKeyIdentifierValueType(); WSSecurityEngineResult result = wsDocInfo.getResult(keyIdentifierValue);
if (WSConstants.WSS_KRB_KI_VALUE_TYPE.equals(valueType)) { secretKey = getSecretKeyFromToken(secRef.getKeyIdentifierValue(), valueType, data); if (secretKey == null) { byte[] keyBytes = secRef.getSKIBytes(); principal = new CustomTokenPrincipal(secRef.getKeyIdentifierValue()); String kiValue = secRef.getKeyIdentifierValue(); List<WSSecurityEngineResult> resultsList = wsDocInfo.getResultsByTag(WSConstants.BST);
) throws WSSecurityException { String valueType = secRef.getKeyIdentifierValueType(); secretKey = getSecretKeyFromToken(secRef.getKeyIdentifierValue(), valueType, data); if (secretKey == null) { AssertionWrapper assertion =
) throws WSSecurityException { String valueType = secRef.getKeyIdentifierValueType(); secretKey = getSecretKeyFromToken(secRef.getKeyIdentifierValue(), valueType, data); if (secretKey == null) { AssertionWrapper assertion =
if (WSConstants.WSS_KRB_KI_VALUE_TYPE.equals(valueType)) { secretKey = getSecretKeyFromToken(secRef.getKeyIdentifierValue(), valueType, data); if (secretKey == null) { byte[] keyBytes = secRef.getSKIBytes(); principal = new CustomTokenPrincipal(secRef.getKeyIdentifierValue()); String kiValue = secRef.getKeyIdentifierValue(); List<WSSecurityEngineResult> resultsList = wsDocInfo.getResultsByTag(WSConstants.BST);
uri = secRef.getKeyIdentifierValue(); if (SecurityTokenReference.THUMB_URI.equals(secRef.getKeyIdentifierValueType())) { referenceType = REFERENCE_TYPE.THUMBPRINT_SHA1;
uri = secRef.getKeyIdentifierValue(); if (SecurityTokenReference.THUMB_URI.equals(secRef.getKeyIdentifierValueType())) { referenceType = REFERENCE_TYPE.THUMBPRINT_SHA1;
return false; if (!compare(getKeyIdentifierValue(), tokenReference.getKeyIdentifierValue())) { return false;
return false; if (!compare(getKeyIdentifierValue(), tokenReference.getKeyIdentifierValue())) { return false;
uri = secRef.getKeyIdentifierValue(); secretKey = getSecretKeyFromToken( secRef.getKeyIdentifierValue(), keyIdentifierValueType, WSPasswordCallback.SECRET_KEY, data ); secretKey = this.getSecretKeyFromToken( secRef.getKeyIdentifierValue(), keyIdentifierValueType, WSPasswordCallback.SECRET_KEY, data );
uri = secRef.getKeyIdentifierValue(); secretKey = getSecretKeyFromToken( secRef.getKeyIdentifierValue(), keyIdentifierValueType, WSPasswordCallback.SECRET_KEY, data ); secretKey = this.getSecretKeyFromToken( secRef.getKeyIdentifierValue(), keyIdentifierValueType, WSPasswordCallback.SECRET_KEY, data );