* [PATCH] crypto: tcrypt: Zero iv before freeing it
@ 2017-04-23 16:12 Codarren Velvindron
2017-04-23 19:11 ` Stephan Müller
0 siblings, 1 reply; 3+ messages in thread
From: Codarren Velvindron @ 2017-04-23 16:12 UTC (permalink / raw)
To: linux-crypto
Signed-off-by: Codarren Velvindron <codarren@hackers.mu>
---
crypto/tcrypt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
index 9a11f3c..48a721c 100644
--- a/crypto/tcrypt.c
+++ b/crypto/tcrypt.c
@@ -384,7 +384,7 @@ static void test_aead_speed(const char *algo, int enc, unsigned int secs,
out_noaxbuf:
testmgr_free_buf(xbuf);
out_noxbuf:
- kfree(iv);
+ kzfree(iv);
return;
}
--
2.7.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] crypto: tcrypt: Zero iv before freeing it
2017-04-23 16:12 [PATCH] crypto: tcrypt: Zero iv before freeing it Codarren Velvindron
@ 2017-04-23 19:11 ` Stephan Müller
2017-04-24 5:34 ` Codarren Velvindron
0 siblings, 1 reply; 3+ messages in thread
From: Stephan Müller @ 2017-04-23 19:11 UTC (permalink / raw)
To: Codarren Velvindron; +Cc: linux-crypto
Am Sonntag, 23. April 2017, 18:12:04 CEST schrieb Codarren Velvindron:
Hi Codarren,
> Signed-off-by: Codarren Velvindron <codarren@hackers.mu>
> ---
> crypto/tcrypt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
> index 9a11f3c..48a721c 100644
> --- a/crypto/tcrypt.c
> +++ b/crypto/tcrypt.c
> @@ -384,7 +384,7 @@ static void test_aead_speed(const char *algo, int enc,
> unsigned int secs, out_noaxbuf:
> testmgr_free_buf(xbuf);
> out_noxbuf:
> - kfree(iv);
> + kzfree(iv);
Why would you think this is needed?
if (iv_len)
memset(iv, 0xff, iv_len);
Ciao
Stephan
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] crypto: tcrypt: Zero iv before freeing it
2017-04-23 19:11 ` Stephan Müller
@ 2017-04-24 5:34 ` Codarren Velvindron
0 siblings, 0 replies; 3+ messages in thread
From: Codarren Velvindron @ 2017-04-24 5:34 UTC (permalink / raw)
To: Stephan Müller; +Cc: linux-crypto
On Sun, Apr 23, 2017 at 09:11:04PM +0200, Stephan Müller wrote:
> Am Sonntag, 23. April 2017, 18:12:04 CEST schrieb Codarren Velvindron:
>
> Hi Codarren,
>
> > Signed-off-by: Codarren Velvindron <codarren@hackers.mu>
> > ---
> > crypto/tcrypt.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/crypto/tcrypt.c b/crypto/tcrypt.c
> > index 9a11f3c..48a721c 100644
> > --- a/crypto/tcrypt.c
> > +++ b/crypto/tcrypt.c
> > @@ -384,7 +384,7 @@ static void test_aead_speed(const char *algo, int enc,
> > unsigned int secs, out_noaxbuf:
> > testmgr_free_buf(xbuf);
> > out_noxbuf:
> > - kfree(iv);
> > + kzfree(iv);
>
> Why would you think this is needed?
>
> if (iv_len)
> memset(iv, 0xff, iv_len);
>
>
> Ciao
> Stephan
Hello,
Thanks for bringing this up to my attention.
Kindly disregard the patch.
Best Regards,
Codarren
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-04-24 6:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-23 16:12 [PATCH] crypto: tcrypt: Zero iv before freeing it Codarren Velvindron
2017-04-23 19:11 ` Stephan Müller
2017-04-24 5:34 ` Codarren Velvindron
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).