History

crypto: async - Use kzfree for requests

This patch changes the kfree call to kzfree for async requests. As the request may contain sensitive data it needs to be zeroed before it can be reallocated by others.

Herbert Xu committed 17 years ago

Commit aef73cf1 parent 57cfe442 files · +3 −3Browse files

Unified · Split

2 files
  1. include/crypto/hash.h +1 −1
  2. include/linux/crypto.h +2 −2
include/crypto/hash.h+1−1
@@ -186,7 +186,7 @@ static inline struct ahash_request *ahash_request_alloc( · 185 unmodified lines
186186
187187 static inline void ahash_request_free(struct ahash_request *req)
188188 {
189− kfree(req);
189+ kzfree(req);
190190 }
191191
192192 static inline struct ahash_request *ahash_request_cast(
include/linux/crypto.h+2−2
@@ -770,7 +770,7 @@ static inline struct ablkcipher_request *ablkcipher_request_alloc( · 769 unmodified lines
770770
771771 static inline void ablkcipher_request_free(struct ablkcipher_request *req)
772772 {
773− kfree(req);
773+ kzfree(req);
774774 }
775775
776776 static inline void ablkcipher_request_set_callback(
@@ -901,7 +901,7 @@ static inline struct aead_request *aead_request_alloc(struct crypto_aead *tfm, · 124 unmodified lines
901901
902902 static inline void aead_request_free(struct aead_request *req)
903903 {
904− kfree(req);
904+ kzfree(req);
905905 }
906906
907907 static inline void aead_request_set_callback(struct aead_request *req,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t