1 19 20 21 package org.netbeans.modules.websvc.wsitmodelext.security; 22 23 import javax.xml.namespace.QName ; 24 import java.util.HashSet ; 25 import java.util.Set ; 26 27 31 public enum SecurityPolicyQName { 32 TRUST10(createSecurityPolicyQName("Trust10")), MUSTSUPPORTISSUEDTOKENS(createSecurityPolicyQName("MustSupportIssuedTokens")), MUSTSUPPORTCLIENTCHALLENGE(createSecurityPolicyQName("MustSupportClientChallenge")), MUSTSUPPORTSERVERCHALLENGE(createSecurityPolicyQName("MustSupportServerChallenge")), REQUIRECLIENTENTROPY(createSecurityPolicyQName("RequireClientEntropy")), REQUIRESERVERENTROPY(createSecurityPolicyQName("RequireServerEntropy")), 39 WSS11(createSecurityPolicyQName("Wss11")), WSS10(createSecurityPolicyQName("Wss10")), MUSTSUPPORTREFKEYIDENTIFIER(createSecurityPolicyQName("MustSupportRefKeyIdentifier")), MUSTSUPPORTREFISSUERSERIAL(createSecurityPolicyQName("MustSupportRefIssuerSerial")), MUSTSUPPORTREFTHUMBPRINT(createSecurityPolicyQName("MustSupportRefThumbprint")), MUSTSUPPORTREFENCRYPTEDKEY(createSecurityPolicyQName("MustSupportRefEncryptedKey")), MUSTSUPPORTREFEXTERNALURI(createSecurityPolicyQName("MustSupportRefExternalURI")), MUSTSUPPORTREFEMBEDDEDTOKEN(createSecurityPolicyQName("MustSupportRefEmbeddedToken")), REQUIRESIGNATURECONFIRMATION(createSecurityPolicyQName("RequireSignatureConfirmation")), REQUESTSECURITYTOKENTEMPLATE(createSecurityPolicyQName("RequestSecurityTokenTemplate")), 50 SIGNEDPARTS(createSecurityPolicyQName("SignedParts")), SIGNEDELEMENTS(createSecurityPolicyQName("SignedElements")), ENCRYPTEDPARTS(createSecurityPolicyQName("EncryptedParts")), ENCRYPTEDELEMENTS(createSecurityPolicyQName("EncryptedElements")), REQUIREDELEMENTS(createSecurityPolicyQName("RequiredElements")), XPATH(createSecurityPolicyQName("XPath")), BODY(createSecurityPolicyQName("Body")), HEADER(createSecurityPolicyQName("Header")), 59 TRANSPORTBINDING(createSecurityPolicyQName("TransportBinding")), SYMMETRICBINDING(createSecurityPolicyQName("SymmetricBinding")), ASYMMETRICBINDING(createSecurityPolicyQName("AsymmetricBinding")), BOOTSTRAPPOLICY(createSecurityPolicyQName("BootstrapPolicy")), 64 INCLUDETIMESTAMP(createSecurityPolicyQName("IncludeTimestamp")), ENCRYPTBEFORESIGNING(createSecurityPolicyQName("EncryptBeforeSigning")), ENCRYPTSIGNATURE(createSecurityPolicyQName("EncryptSignature")), PROTECTTOKENS(createSecurityPolicyQName("ProtectTokens")), ONLYSIGNENTIREHEADERSANDBODY(createSecurityPolicyQName("OnlySignEntireHeadersAndBody")), 70 LAYOUT(createSecurityPolicyQName("Layout")), STRICT(createSecurityPolicyQName("Strict")), LAX(createSecurityPolicyQName("Lax")), LAXTSFIRST(createSecurityPolicyQName("LaxTsFirst")), LAXTSLAST(createSecurityPolicyQName("LaxTsLast")); 76 public static final String SECPOLICY_UTILITY = 77 "http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"; public static final String SECPOLICY_UTILITY_NS_PREFIX = "sp"; 80 public static QName createSecurityPolicyQName(String localName){ 81 return new QName (SECPOLICY_UTILITY, localName, SECPOLICY_UTILITY_NS_PREFIX); 82 } 83 84 SecurityPolicyQName(QName name) { 85 qName = name; 86 } 87 88 public QName getQName(){ 89 return qName; 90 } 91 private static Set <QName > qnames = null; 92 public static Set <QName > getQNames() { 93 if (qnames == null) { 94 qnames = new HashSet <QName >(); 95 for (SecurityPolicyQName wq : values()) { 96 qnames.add(wq.getQName()); 97 } 98 } 99 return qnames; 100 } 101 private final QName qName; 102 103 } 104 | Popular Tags |