From patchwork Thu Jan 25 09:00:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Github ODP bot X-Patchwork-Id: 125777 Delivered-To: patch@linaro.org Received: by 10.46.66.141 with SMTP id h13csp972090ljf; Thu, 25 Jan 2018 01:02:09 -0800 (PST) X-Google-Smtp-Source: AH8x225ESHlNALGw00s/oWG/JZ8NHq7N2bikvyCmU4J58WFKj7wCsR2l7Uf7dwBLZ/jK9R0LToPH X-Received: by 10.55.20.228 with SMTP id 97mr12965758qku.24.1516870928915; Thu, 25 Jan 2018 01:02:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516870928; cv=none; d=google.com; s=arc-20160816; b=g3oX0VxWHUaCDfGZVvmzlg9AD6NNlDiTT1wFGPRiLh5pkVAPjKisKUXi/IQdpaAZ// exiqW8n6WTIMLLr5J3h/qsU1wVHDzFGyYZmB5+cW+J/4uCzDQw/7hkOChZZ4S1payzOe ZWLCweOE4nPUPZaAJ+0hcQmsPwfxXJoEtKC/B6CHKVOj/8XNS65bZaR37zF5T252m3ax R6Gbbfr6hUlx+iDbnsnUxk96fsHON2boqmooJK9aGSvhwAxXWyCCL6va8E83xlDGBL/c r8BNw2dhpTJTQUqac1G2Oo5AstEvoFUzZO9O+zfBI/FXaaAKJ95CVBez1rS6Z1pA3mBh nMeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:github-pr-num :references:in-reply-to:message-id:date:to:from:delivered-to :arc-authentication-results; bh=Wt6zIXpMhhveWhAKHAGliihAdiDnDP5O1l3x/elZV6w=; b=iF6Ob0ijKXp9N59MBLKGmsmxGuKDkA5Bn4unGwRS2aFcqnnCVpf4yagOoZxyaQJqGI SRFoIIuSpFmLYd5Y6ZKWwDNSklX1sxqre6WXLhpCAfMvw29q1Go3N3uDB7mGvXAF8Hog LPRlIB5DhbSDTa/v0v3YZL1464ZgSDpsWshiSF3S2eUjc0JTZOzH0wtKDiuQKTQRmKrz B8+DYr3/XyP02OsDLekg/Gpu81ndeJou5dhjz9elRtwCuAhc9IYTcN9s1Z1J3zhi/63m YsYGr7GJfDwggLz2HaWdHFOFECfcxzI+C0i1OCZNCDWN+B6eBLrzxrW8M7+l+qSMKS/C 874g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Return-Path: Received: from lists.linaro.org (ec2-54-197-127-237.compute-1.amazonaws.com. [54.197.127.237]) by mx.google.com with ESMTP id l10si4812457qtc.79.2018.01.25.01.02.08; Thu, 25 Jan 2018 01:02:08 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) client-ip=54.197.127.237; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.197.127.237 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=yandex.ru Received: by lists.linaro.org (Postfix, from userid 109) id 7790261777; Thu, 25 Jan 2018 09:02:08 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2 autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 4989361782; Thu, 25 Jan 2018 09:00:30 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 8380F61719; Thu, 25 Jan 2018 09:00:22 +0000 (UTC) Received: from forward103p.mail.yandex.net (forward103p.mail.yandex.net [77.88.28.106]) by lists.linaro.org (Postfix) with ESMTPS id B64CB6176D for ; Thu, 25 Jan 2018 09:00:11 +0000 (UTC) Received: from mxback12g.mail.yandex.net (mxback12g.mail.yandex.net [IPv6:2a02:6b8:0:1472:2741:0:8b7:91]) by forward103p.mail.yandex.net (Yandex) with ESMTP id 2B1452181791 for ; Thu, 25 Jan 2018 12:00:10 +0300 (MSK) Received: from smtp4o.mail.yandex.net (smtp4o.mail.yandex.net [2a02:6b8:0:1a2d::28]) by mxback12g.mail.yandex.net (nwsmtp/Yandex) with ESMTP id wF3tQ6ukgL-0AXi4FKw; Thu, 25 Jan 2018 12:00:10 +0300 Received: by smtp4o.mail.yandex.net (nwsmtp/Yandex) with ESMTPSA id FBe3SFa4XG-09A8wTtq; Thu, 25 Jan 2018 12:00:09 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (Client certificate not present) From: Github ODP bot To: lng-odp@lists.linaro.org Date: Thu, 25 Jan 2018 12:00:07 +0300 Message-Id: <1516870807-20028-3-git-send-email-odpbot@yandex.ru> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516870807-20028-1-git-send-email-odpbot@yandex.ru> References: <1516870807-20028-1-git-send-email-odpbot@yandex.ru> Github-pr-num: 430 Subject: [lng-odp] [PATCH API-NEXT v1 2/2] api: crypto: add enumeration for AES-CCM X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" From: Petri Savolainen Added enumerations for AES CCM authentication / encryption algorithm. Signed-off-by: Petri Savolainen --- /** Email created from pull request 430 (psavol:next-crypto-algo) ** https://github.com/Linaro/odp/pull/430 ** Patch: https://github.com/Linaro/odp/pull/430.patch ** Base sha: 44974a09b01c79adb9637a5dff38539598a76737 ** Merge commit sha: 4e9d485380d67649f29ff063ae80352f19fadf74 **/ include/odp/api/spec/crypto.h | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/include/odp/api/spec/crypto.h b/include/odp/api/spec/crypto.h index e4b0e8cef..b8c7b9d80 100644 --- a/include/odp/api/spec/crypto.h +++ b/include/odp/api/spec/crypto.h @@ -92,6 +92,15 @@ typedef enum { */ ODP_CIPHER_ALG_AES_GCM, + /** AES-CCM + * + * AES in Counter with CBC-MAC (CCM) mode algorithm. CCM provides both + * authentication and ciphering of data (authenticated encryption) + * in the same operation. Hence this algorithm must be paired always + * with ODP_AUTH_ALG_AES_CCM authentication. + */ + ODP_CIPHER_ALG_AES_CCM, + /** @deprecated Use ODP_CIPHER_ALG_AES_CBC instead */ ODP_DEPRECATE(ODP_CIPHER_ALG_AES128_CBC), @@ -157,6 +166,15 @@ typedef enum { */ ODP_AUTH_ALG_AES_GMAC, + /** AES-CCM + * + * AES in Counter with CBC-MAC (CCM) mode algorithm. CCM provides both + * authentication and ciphering of data (authenticated encryption) + * in the same operation. Hence this algorithm must be paired always + * with ODP_CIPHER_ALG_AES_CCM cipher. + */ + ODP_AUTH_ALG_AES_CCM, + /** @deprecated Use ODP_AUTH_ALG_MD5_HMAC instead */ ODP_DEPRECATE(ODP_AUTH_ALG_MD5_96), @@ -192,6 +210,9 @@ typedef union odp_crypto_cipher_algos_t { /** ODP_CIPHER_ALG_AES_GCM */ uint32_t aes_gcm : 1; + /** ODP_CIPHER_ALG_AES_CCM */ + uint32_t aes_ccm : 1; + /** @deprecated Use aes_cbc instead */ uint32_t ODP_DEPRECATE(aes128_cbc) : 1; @@ -234,6 +255,9 @@ typedef union odp_crypto_auth_algos_t { /** ODP_AUTH_ALG_AES_GMAC*/ uint32_t aes_gmac : 1; + /** ODP_AUTH_ALG_AES_CCM */ + uint32_t aes_ccm : 1; + /** @deprecated Use md5_hmac instead */ uint32_t ODP_DEPRECATE(md5_96) : 1;