You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fx-dev@ws.apache.org by mu...@apache.org on 2004/07/31 11:41:29 UTC

cvs commit: ws-fx/wss4j/src/org/apache/ws/security/trust TrustConstants.java

muthulee    2004/07/31 02:41:29

  Modified:    wss4j/src/org/apache/ws/security/trust TrustConstants.java
  Log:
  Committing Kaushalye's code
  
  Revision  Changes    Path
  1.2       +83 -7     ws-fx/wss4j/src/org/apache/ws/security/trust/TrustConstants.java
  
  Index: TrustConstants.java
  ===================================================================
  RCS file: /home/cvs/ws-fx/wss4j/src/org/apache/ws/security/trust/TrustConstants.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- TrustConstants.java	18 Jun 2004 11:33:03 -0000	1.1
  +++ TrustConstants.java	31 Jul 2004 09:41:29 -0000	1.2
  @@ -16,23 +16,99 @@
    */
   package org.apache.ws.security.trust;
   
  +
   /**
  - * @author Malinda Kaushalye
    *
  - * Place to keep constants for WS-Trust.
  - * Please refer the specification for further clarification.
  + * @author Malinda Kaushalye 
  + * 
  + * @version 1.0
  + * 
  + * TrustConstants is the class where all the constants of the WS-Trust implementation are kept. 
  + * Primarily all the namespaces, prefixes and local names of the tokens are kept here.
  + * Then all the codes used in message exchanges are also listed here. 
  + * all the configuration parameters are also kept here.
  + * 
    */
  +
   public class TrustConstants {
   
  + //local names of the token used in WS-Trust
     public static final String SECURITY_CONTEXT_TOKEN_RESPONSE_LN ="SecurityContextTokenResponse";
  +  public static final String REQUEST_SECURITY_TOKEN_RESPONSE_LN ="RequestSecurityTokenResponse";//trust
     public static final String TOKEN_TYPE_LN = "TokenType";
  +  public static final String REQUEST_TYPE_LN = "RequestType";
     public static final String KEY_TYPE_LN = "KeyType";
     public static final String KEY_SIZE_LN = "KeySize";
   
     public static final String LIFE_TIME_LN = "Lifetime";
  -  public static final String REQUESTED_SECURITY_TOKEN_LN = "RequestedSecurityToken";
  -
  -  public static final String SECURITY_CONTEXT_TOKEN_LN = "String SecurityContextToken";
  -
  +  public static final String CREATED_LN = "Created";
  +  public static final String EXPIRES_LN = "Expires";
  +  public static final String BASE_LN = "Base";
  +  public static final String STATUS_LN = "Status";
  +  public static final String CODE_LN = "Code";
  +  public static final String REASON_LN = "Reason";
  +  public static final String RENEWING_LN = "Renewing";
  +  public static final String ALLOWPOSTDATING_LN ="AllowPostdating";
  +  public static final String APPLIESTO_LN ="AppliesTo";
  +    
  +  public static final String REQUEST_SECURITY_TOKEN_LN = "RequestSecurityToken";
  +   public static final String REQUESTED_SECURITY_TOKEN_LN = "RequestedSecurityToken";
  +  public static final String REQUESTED_PROOF_TOKEN_LN = "RequestedProofToken";
  +  public static final String SECURITY_CONTEXT_TOKEN_LN = "SecurityContextToken";
  +  
  + // The request type is specified using following URIs as specified in the WS-Trust specification
  +  public static final String ISSUE_SECURITY_TOKEN = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/Issue";//RequestTypeEnum._value1.toString();//"http://schemas.xmlsoap.org/ws/2004/04/security/trust/Issue";
  +  public static final String RENEW_SECURITY_TOKEN = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/Renew";
  +  public static final String VALIDATE_SECURITY_TOKEN = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/Validate";
  +  
  +  public static final String ISSUE_SECURITY_TOKEN_RSTR = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RSTR/Issue";
  +  public static final String RENEW_SECURITY_TOKEN_RSTR = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RSTR/Renew";
  +  public static final String VALIDATE_SECURITY_TOKEN_RSTR = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RSTR/Validate";
  +  
  +  public static final String ISSUE_SECURITY_TOKEN_RST = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RST/Issue";
  +  public static final String RENEW_SECURITY_TOKEN_RST = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RST/Renew";
  +  public static final String VALIDATE_SECURITY_TOKEN_RST = "http://schemas.xmlsoap.org/ws/2004/04/security/trust/RST/Validate";
  +  
  +  
  +//  public static final URI ISSUE_SECURITY_TOKEN_URI = new URI("http://schemas.xmlsoap.org/ws/2004/04/security/trust/Issue");
  +//  public static final URI RENEW_SECURITY_TOKEN_URI = new URI("http://schemas.xmlsoap.org/ws/2004/04/security/trust/Renew");
  +//  public static final URI VALIDATE_SECURITY_TOKEN_URI = new URI("http://schemas.xmlsoap.org/ws/2004/04/security/trust/Validate"); 
  +	public static final String WST_NS = "http://schemas.xmlsoap.org/ws/2004/04/trust";
  +	public static final String WSP_NS = "http://schemas.xmlsoap.org/ws/2002/12/policy";
  +	
  +	public static final String WST_PREFIX = "wst";
  +	public static final String WSP_PREFIX = "wsp";
  +	
  +	//For STS there should be an issuer class specified in the server-config.wsdd
  +	public static final String ISSUER_CLASS = "issuerClass";
  +	//	For STS there should be a renewer class specified in the server-config.wsdd
  +	public static final String RENEWER_CLASS = "renewerClass";
  +	//	For STS there should be a validator class specified in the server-config.wsdd
  +	public static final String VALIDATOR_CLASS = "validatorClass";
  +	
  +	//In the request, The token type can be specified in the client-config
  +	public static final String TOKEN_TYPE="TokenType";	
  +	//The request type , issue/renew or validate 
  +	public static final String REQUEST_TYPE="RequestType";
  +	
  +//	...commented.... no need of having these params.
  +// architectural change in the STSClientHandler. Now we have more distributed requesters....
  +//	//basedon params
  +//	public static final String BASED_ON="BasedOn";
  +//	//based on values
  +//	public static final String BASED_ON_X509="X509Certificate";
  +//	public static final String BASED_ON_USERNAME_TOKEN="UsernameToken";
  +//	public static final String BASED_ON_SAML="SAML";
  +	
  +	//for BASED_ON_X509
  +	public static final String BASE_CERT_FILE="BaseCertFile";
  +	public static final String USER="user";//alias of the certificate
  +	
  +	//for BASED_ON_USERNAME_TOKEN
  +	public static final String UNT_USER="UNTUser";
  +	public static final String UNT_PWCALLBACK_CLASS="passwordCallbackClass";
  +	
  +	//requester class
  +	public static final String REQUESTER_CLASS="requesterClass";
    }