From: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
To: Patrick McHardy <kaber@trash.net>
Cc: Herbert Xu <herbert@gondor.apana.org.au>, linux-crypto@vger.kernel.org
Subject: Re: HIFN+IPsec crashes in current -git
Date: Wed, 20 Feb 2008 16:19:03 +0300 [thread overview]
Message-ID: <20080220131903.GA1965@2ka.mipt.ru> (raw)
In-Reply-To: <47BC1E12.9050201@trash.net>
Hi Patrick.
On Wed, Feb 20, 2008 at 01:33:22PM +0100, Patrick McHardy (kaber@trash.net) wrote:
> I saw the discrepancy between the elen value used
> for aead_request_set_crypt() in esp_input() and the
> req->nbytes value seen in hifn_setup_session().
What iv generation scheme do you use? It looks like only gcm and ccm add
16 bytes to cryptlen and set nbytes to them. Although they both install
two scatterlists for crypto operation: one for data and one for above
addition block of 16 bytes.
Btw, Herbert, I've found a tiny typo in both ccm and gcm modules, which
do not set correct cra_aead.geniv name.
Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
diff --git a/crypto/ccm.c b/crypto/ccm.c
index 7cf7e5a..118b6f5 100644
--- a/crypto/ccm.c
+++ b/crypto/ccm.c
@@ -821,7 +821,7 @@ static struct crypto_instance *crypto_rfc4309_alloc(struct rtattr **tb)
inst->alg.cra_aead.encrypt = crypto_rfc4309_encrypt;
inst->alg.cra_aead.decrypt = crypto_rfc4309_decrypt;
- inst->alg.cra_aead.geniv = "seqiv";
+ inst->alg.cra_aead.geniv = "ccm";
out:
return inst;
diff --git a/crypto/gcm.c b/crypto/gcm.c
index e70afd0..058de64 100644
--- a/crypto/gcm.c
+++ b/crypto/gcm.c
@@ -754,7 +754,7 @@ static struct crypto_instance *crypto_rfc4106_alloc(struct rtattr **tb)
inst->alg.cra_aead.encrypt = crypto_rfc4106_encrypt;
inst->alg.cra_aead.decrypt = crypto_rfc4106_decrypt;
- inst->alg.cra_aead.geniv = "seqiv";
+ inst->alg.cra_aead.geniv = "gcm";
out:
return inst;
--
Evgeniy Polyakov
next prev parent reply other threads:[~2008-02-20 13:19 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-13 13:17 HIFN+IPsec crashes in current -git Patrick McHardy
2008-02-13 14:44 ` Evgeniy Polyakov
2008-02-14 9:30 ` Evgeniy Polyakov
2008-02-19 16:10 ` Patrick McHardy
2008-02-19 16:14 ` Patrick McHardy
2008-02-19 6:23 ` Herbert Xu
2008-02-19 16:27 ` Patrick McHardy
2008-02-20 0:53 ` Herbert Xu
2008-02-20 12:33 ` Patrick McHardy
2008-02-20 13:19 ` Evgeniy Polyakov [this message]
2008-02-20 17:29 ` Herbert Xu
2008-02-20 17:26 ` Herbert Xu
2008-02-21 9:10 ` Evgeniy Polyakov
2008-02-21 14:10 ` Herbert Xu
2008-02-21 14:18 ` Evgeniy Polyakov
2008-02-21 14:20 ` Patrick McHardy
2008-02-21 14:37 ` Evgeniy Polyakov
2008-02-21 14:41 ` Patrick McHardy
2008-02-21 15:29 ` Patrick McHardy
2008-02-21 15:31 ` Patrick McHardy
2008-02-22 12:42 ` Evgeniy Polyakov
2008-02-22 13:53 ` Patrick McHardy
2008-02-22 2:27 ` Test AES-CCM mode via IPSec (NETKEY) Loc Ho
2008-02-22 5:45 ` Herbert Xu
2008-03-13 17:34 ` Loc Ho
2008-03-14 1:12 ` Herbert Xu
2008-04-04 22:37 ` Joy Latten
2008-04-04 23:08 ` Loc Ho
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080220131903.GA1965@2ka.mipt.ru \
--to=johnpol@2ka.mipt.ru \
--cc=herbert@gondor.apana.org.au \
--cc=kaber@trash.net \
--cc=linux-crypto@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox