5.3 Lock/Unlock Binary Data
5.3.1 Lock Binary Data
The lockData
function of BayunCore
class locks binary data with default encryption-policy dictated by server settings.
The function takes the following parameters :
sessionId : Unique SessionId which is received in the authenticate function response.
data : Data to be locked.
dataType :
bytes
data_len : Length of the data to be locked.
5.3.2 Lock Binary Data with encryption-policy
The lockData
function with encryption-policy as an optional parameter locks data with the encryption key dictated by the policy. The function takes the following parameters :
sessionId : Unique SessionId which is received in the authenticate function response.
data : Data to be locked.
dataType :
bytes
data_len : Length of the data to be locked.
encryptionPolicy : BayunEncryptionPolicy determines the key for locking.
keyGenerationPolicy : BayunKeyGenerationPolicy determines the policy to generate the data encryption key.
groupId : GroupId is required if encryptionPolicy is
BayunEncryptionPolicyGroup
.
Note : If encryption-policy is other than BayunEncryptionPolicyGroup
then groupId should be empty string.
5.3.3 Unlock Binary Data
The unlockData
function of BayunCore
class unlocks a locked binary data. The function takes the following parameters :
sessionId : Unique SessionId which is received in the authenticate function response.
data : Data to be unlocked.
dataType :
bytes
data_len : Length of data to be unlocked.
Last updated