SecurityContext.java revision 4a2f0f0be43dfd4c1b490cbf3cc48b6ba6084b1c
/**
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2007 Sun Microsystems Inc. All Rights Reserved
*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the License at
* See the License for the specific language governing
* permission and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at opensso/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* your own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* $Id: SecurityContext.java,v 1.1 2009/08/29 03:05:58 mallas Exp $
*
*/
/**
* This class represents the security context for signing/verification
* and encryption/decryption etc.
*/
public class SecurityContext {
/**
* Returns the signing key.
* @return the signing key.
*/
public Key getSigningKey() {
return signingKey;
}
/**
* Sets the signing key
* @param signingKey the signing key
*/
this.signingKey = signingKey;
}
/**
* Returns the signature verification key.
*
* @return the signature verification key.
*/
public Key getVerificationKey() {
return verificationKey;
}
/**
* Sets the signature verification key
* @param verificationKey signature verification key
*/
this.verificationKey = verificationKey;
}
/**
* Returns the encryption key
* @return the encryption key
*/
public Key getEncryptionKey() {
return encryptionKey;
}
this.encryptionKey = encryptionKey;
}
/**
* Returns the decryption key.
* return the decryption key.
*/
public Key getDecryptionKey() {
return decryptionKey;
}
/**
* Sets the decryption key
* @param decryptionKey the decryption key
*/
this.decryptionKey = decryptionKey;
}
/**
* Returns the key type. The possible types are SYMMETRIC_KEY or
* ASYMMETRIC_KEY.
* @return the key type.
*/
public String getKeyType() {
return keyType;
}
/**
* Sets the key type.
* @param keyType the key type.
*/
}
/**
* Return the signing certificate alias
* @return the signing certificate alias
*/
public String getSigningCertAlias() {
return signingCertAlias;
}
/**
* Sets the signing certificate alias.
* @param alias the signature certificate alias.
*/
this.signingCertAlias = alias;
}
/**
* Returns the signature verification certificate alias.
* @return the signature verification certificate alias.
*/
public String getVerificationCertAlias() {
return verificationCertAlias;
}
/**
* Sets the signature certificate alias
* @param alias the signature certificate alias
*/
this.verificationCertAlias = alias;
}
/**
* Returns the encryption key alias.
* @return the encryption key alias.
*/
public String getEncryptionKeyAlias() {
return encryptionAlias;
}
/**
* Sets the encryption key alias.
* @param alias the encryption key alias.
*/
this.encryptionAlias = alias;
}
/**
* Returns the certificate alias for the decryption.
* @return the decryption certificate alias.
*/
public String getDecryptionAlias() {
return decryptionAlias;
}
/**
* Sets the certificate alias for the decryption.
* @param alias the certificate alias for the decryption.
*/
this.decryptionAlias = alias;
}
/**
* Returns the signing reference type.
* @return the signing reference type.
*/
public String getSigningRef() {
return signingRef;
}
/**
* Sets the signing reference type.
* @param signingRef the signing reference type.
*/
this.signingRef = signingRef;
}
}