|
Cumulus4j API (1.2.0) |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.cumulus4j.keymanager.back.shared.Message org.cumulus4j.keymanager.back.shared.Request org.cumulus4j.keymanager.back.shared.GetKeyRequest
public class GetKeyRequest
Request
implementation to get a specific symmetric secret key.
In order to prevent an attacker dumping an app-server's memory from gaining access to all the data, Cumulus4j uses many different keys for encryption. Usually, it rotates the encryption key once per day, but different settings are possible (e.g. once per hour for the very paranoid).
Which key was used to encrypt which record is stored together with the record in the keyID
.
Whenever a record (data or index) needs to be decrypted, the corresponding key is requested from the key-manager
via this request.
GetKeyResponse
,
Serialized FormConstructor Summary | |
---|---|
GetKeyRequest()
Create an empty instance of GetKeyRequest . |
|
GetKeyRequest(String cryptoSessionID,
long keyID,
String keyEncryptionTransformation,
byte[] keyEncryptionPublicKey)
Create an instance of GetKeyRequest for asking the key-manager about
a certain symmetric secret key. |
Method Summary | |
---|---|
byte[] |
getKeyEncryptionPublicKey()
Get the public key to be used to encrypt the symmetric secret key. |
String |
getKeyEncryptionTransformation()
Get the asymmetric encryption algorithm to be used to encrypt the symmetric secret key. |
long |
getKeyID()
Get the identifier of the requested symmetric secret key. |
void |
setKeyEncryptionPublicKey(byte[] keyEncryptionPublicKey)
Set the public key to be used to encrypt the symmetric secret key. |
void |
setKeyEncryptionTransformation(String keyEncryptionTransformation)
Set the asymmetric encryption algorithm to be used when encrypting the symmetric secret key. |
void |
setKeyID(long keyID)
Set the identifier of the requested symmetric secret key. |
Methods inherited from class org.cumulus4j.keymanager.back.shared.Request |
---|
getCryptoSessionID, getCryptoSessionIDPrefix, setCryptoSessionID, toString |
Methods inherited from class org.cumulus4j.keymanager.back.shared.Message |
---|
equals, getRequestID, hashCode, setRequestID |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public GetKeyRequest()
GetKeyRequest
.
Only used for serialisation/deserialisation.
public GetKeyRequest(String cryptoSessionID, long keyID, String keyEncryptionTransformation, byte[] keyEncryptionPublicKey)
GetKeyRequest
for asking the key-manager about
a certain symmetric secret key.
cryptoSessionID
- the identifier of the crypto-session in which the request should be processed.
It must exist and be unlocked for this request to succeed.keyID
- the identifier of the key requested by the app-server.keyEncryptionTransformation
- the asymmetric encryption algorithm (with padding) that should be
used by the key-manager to encrypt the symmetric secret key, before sending it to the app-server. For example
"RSA//OAEPWITHSHA1ANDMGF1PADDING".keyEncryptionPublicKey
- the public key to be used by the key-manager to encrypt the
key when sending it back to the app-server.Method Detail |
---|
public long getKeyID()
setKeyID(long)
public void setKeyID(long keyID)
keyID
- the identifier of the requested symmetric secret key.getKeyID()
public String getKeyEncryptionTransformation()
Get the asymmetric encryption algorithm to be used to encrypt the symmetric secret key.
The key-manager uses this transformation
(which should include a padding, e.g. "RSA//OAEPWITHSHA1ANDMGF1PADDING") to
obtain a Cipher
for encrypting the secret key
before sending it to the app-server.
setKeyEncryptionTransformation(String)
public void setKeyEncryptionTransformation(String keyEncryptionTransformation)
keyEncryptionTransformation
- the asymmetric encryption algorithm to be used when encrypting the symmetric secret key.getKeyEncryptionTransformation()
public byte[] getKeyEncryptionPublicKey()
public void setKeyEncryptionPublicKey(byte[] keyEncryptionPublicKey)
keyEncryptionPublicKey
- the public key to be used to encrypt the symmetric secret key.
|
Cumulus4j API (1.2.0) |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |