File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed
Applet/AndroidSEProviderLib/src/com/android/javacard/seprovider Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change @@ -539,7 +539,27 @@ KMOperation initSymmetricOperation(
539539 short ivStart ,
540540 short ivLength ,
541541 short macLength );
542-
542+
543+ /**
544+ * This function creates an Operation instance only for RKP module.
545+ *
546+ * @param purpose is KMType.ENCRYPT or KMType.DECRYPT for AES and DES algorithm. It will be
547+ * KMType.SIGN and KMType.VERIFY for HMAC algorithm
548+ * @param alg is KMType.HMAC, KMType.AES or KMType.DES.
549+ * @param digest is KMType.SHA2_256 in case of HMAC else it will be KMType.DIGEST_NONE.
550+ * @param padding is KMType.PADDING_NONE or KMType.PKCS7 (in case of AES and DES).
551+ * @param blockMode is KMType.CTR, KMType.GCM. KMType.CBC or KMType.ECB for AES or DES else it is
552+ * 0.
553+ * @param keyBuf is aes, des or hmac key buffer.
554+ * @param keyStart is the start of the key buffer.
555+ * @param keyLength is the length of the key buffer.
556+ * @param ivBuf is the iv buffer (in case on AES and DES algorithm without ECB mode)
557+ * @param ivStart is the start of the iv buffer.
558+ * @param ivLength is the length of the iv buffer. It will be zero in case of HMAC and AES/DES
559+ * with ECB mode.
560+ * @param macLength is the mac length in case of signing operation for hmac algorithm.
561+ * @return KMOperation instance.
562+ */
543563 KMOperation getRkpOperation (byte purpose ,
544564 byte alg ,
545565 byte digest ,
You can’t perform that action at this time.
0 commit comments