public class PlaintextKeys extends GPCardKeys
| Modifier and Type | Class and Description |
|---|---|
static class |
PlaintextKeys.Diversification |
GPCardKeys.KeyPurpose| Modifier and Type | Field and Description |
|---|---|
static Map<GPCardKeys.KeyPurpose,byte[]> |
SCP02_CONSTANTS |
static Map<GPCardKeys.KeyPurpose,Byte> |
SCP03_CONSTANTS |
static Map<GPCardKeys.KeyPurpose,byte[]> |
SCP03_KDF_CONSTANTS |
kdd, scpgetKDDpublic static final Map<GPCardKeys.KeyPurpose,byte[]> SCP02_CONSTANTS
public static final Map<GPCardKeys.KeyPurpose,Byte> SCP03_CONSTANTS
public static final Map<GPCardKeys.KeyPurpose,byte[]> SCP03_KDF_CONSTANTS
public static PlaintextKeys fromMasterKey(byte[] master)
public static PlaintextKeys fromMasterKey(byte[] master, byte[] kcv)
public static PlaintextKeys defaultKey()
public static PlaintextKeys derivedFromMasterKey(byte[] master, byte[] kcv, PlaintextKeys.Diversification div)
public static PlaintextKeys fromKeys(byte[] enc, byte[] mac, byte[] dek)
public static byte[] diversify(byte[] k,
GPCardKeys.KeyPurpose usage,
byte[] kdd,
PlaintextKeys.Diversification method)
throws GPException
GPExceptionpublic static final byte[] fillVisa2(byte[] kdd,
GPCardKeys.KeyPurpose key)
public static final byte[] fillVisa(byte[] kdd,
GPCardKeys.KeyPurpose key)
public static final byte[] fillEmv(byte[] kdd,
GPCardKeys.KeyPurpose key)
public GPKeyInfo getKeyInfo()
getKeyInfo in class GPCardKeyspublic byte[] encrypt(byte[] data)
throws GeneralSecurityException
encrypt in class GPCardKeysGeneralSecurityExceptionpublic byte[] encryptKey(GPCardKeys key, GPCardKeys.KeyPurpose p) throws GeneralSecurityException
encryptKey in class GPCardKeysGeneralSecurityExceptionpublic GPSessionKeys getSessionKeys(byte[] kdd)
getSessionKeys in class GPCardKeyspublic byte[] kcv(GPCardKeys.KeyPurpose p)
kcv in class GPCardKeyspublic void setVersion(int version)
public GPCardKeys diversify(GPSecureChannel scp, byte[] kdd)
diversify in class GPCardKeyspublic String toString()
toString in class GPCardKeyspublic void setDiversifier(PlaintextKeys.Diversification diversifier)
Copyright © 2019. All rights reserved.