DEVICE DRIVERS
iPS_LoadMasterEncKey()
M
X
800 SERIES PROGRAMMERS GUIDE 63
iPS_LoadMasterEncKey()
This function loads the security script’s master keys without deleting the keys
already loaded. The new values must be presented encrypted under the current
value of VSS_KLK.
This function can be used to load the keys defined by the Security Scripts if the
option has not been disabled in the script.
An error code will be returned if the VSS_KLK is not present.
Prototype
int iPS_LoadMasterEncKey(unsigned char ucKeySetID, unsigned char
ucKeyID, unsigned char * pucINKeyValue)
Parameters
Return Values
ucKeyID The key set identifier.
ucKeyID The key identifier.
pucINKeyValue pointer to the 8-byte buffer containing the cleartext value Master
Key.
0 Successful execution
E_KM_NO_KEY_LOADED VSS_KLK is absent. No encrypted loading
possible
E_KM_KEY_INTEGRITY_ERROR VSS_KLK is corrupted
E_KM_OUT_OF_RANGE ucKeySetID or ucKeyID is out of range or
script is not loaded.
E_KM_FEATURE_DISABLED Master/Session support disabled by a script
E_KM_SYSTEM_ERROR
00 Key set defined in VeriShield Security Script #0
01 Key set defined in VeriShield Security Script #1
...
07 Key set defined in VeriShield Security Script #7
Master key number / Key index in the selected set