Class KeyTransferBean
- java.lang.Object
-
- com.atlassian.confluence.security.persistence.dao.hibernate.KeyTransferBean
-
- All Implemented Interfaces:
Serializable
public class KeyTransferBean extends Object implements Serializable
Allows conversion to and from serialized form.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
TYPE_PRIVATE
static String
TYPE_PUBLIC
-
Constructor Summary
Constructors Constructor Description KeyTransferBean(String asCData)
This is really messy.KeyTransferBean(String type, String algorithm, String encodedKey)
KeyTransferBean(Key key)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
asCDataEncodedString()
Yuck this makes me sick.Key
asKey()
static String
CDatafyString(String s)
String
encodeKey(Key key)
Encode aKey
in string form for storage as a database CLOB fieldString
getAlgorithm()
String
getEncodedKey()
protected com.atlassian.security.auth.trustedapps.EncryptionProvider
getEncryptionProvider()
String
getKeyType()
void
setAlgorithm(String algorithm)
void
setEncodedKey(String encodedKey)
void
setKeyType(String keyType)
-
-
-
Field Detail
-
TYPE_PRIVATE
public static final String TYPE_PRIVATE
- See Also:
- Constant Field Values
-
TYPE_PUBLIC
public static final String TYPE_PUBLIC
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
KeyTransferBean
public KeyTransferBean(String asCData)
This is really messy. This works assuming that there are not any spaces in the fields.
-
KeyTransferBean
public KeyTransferBean(String type, String algorithm, String encodedKey)
- Parameters:
encodedKey
- the encoded keytype
- the key typealgorithm
- String denoting the crypto algorithm used
-
KeyTransferBean
public KeyTransferBean(Key key)
-
-
Method Detail
-
getKeyType
public String getKeyType()
-
getAlgorithm
public String getAlgorithm()
-
getEncodedKey
public String getEncodedKey()
-
setKeyType
public void setKeyType(String keyType)
-
setEncodedKey
public void setEncodedKey(String encodedKey)
-
setAlgorithm
public void setAlgorithm(String algorithm)
-
asKey
public Key asKey()
-
getEncryptionProvider
protected com.atlassian.security.auth.trustedapps.EncryptionProvider getEncryptionProvider()
-
encodeKey
public String encodeKey(Key key)
Encode aKey
in string form for storage as a database CLOB field- Parameters:
key
- Opaque key- Returns:
- String encoded form
-
asCDataEncodedString
public String asCDataEncodedString()
Yuck this makes me sick.
-
-