Add support for CCM*-no-tag to PSA.
Signed-off-by: Mateusz Starzyk <mateusz.starzyk@mobica.com>
diff --git a/include/psa/crypto_sizes.h b/include/psa/crypto_sizes.h
index 4c67f10..e9a7a35 100644
--- a/include/psa/crypto_sizes.h
+++ b/include/psa/crypto_sizes.h
@@ -959,7 +959,8 @@
(alg) == PSA_ALG_CBC_PKCS7) ? PSA_BLOCK_CIPHER_BLOCK_LENGTH(key_type) : \
(key_type) == PSA_KEY_TYPE_CHACHA20 && \
(alg) == PSA_ALG_STREAM_CIPHER ? 12 : \
- 0)
+ (alg) == PSA_ALG_CCM_STAR_NO_TAG ? 13 : \
+ 0)
/** The maximum IV size for all supported cipher algorithms, in bytes.
*
diff --git a/include/psa/crypto_values.h b/include/psa/crypto_values.h
index daef941..9f0b751 100644
--- a/include/psa/crypto_values.h
+++ b/include/psa/crypto_values.h
@@ -1195,6 +1195,17 @@
*/
#define PSA_ALG_CCM ((psa_algorithm_t)0x05500100)
+/** The CCM* cipher mode without authentication.
+ *
+ * This is CCM* as specified in IEEE 802.15.4 §7, with a tag length of 0.
+ * For CCM* with a nonzero tag length, use the AEAD algorithm #PSA_ALG_CCM.
+ *
+ * The underlying block cipher is determined by the key type.
+ *
+ * Currently only 13-byte long IV's are supported.
+ */
+#define PSA_ALG_CCM_STAR_NO_TAG ((psa_algorithm_t)0x04c01300)
+
/** The GCM authenticated encryption algorithm.
*
* The underlying block cipher is determined by the key type.