summaryrefslogtreecommitdiffstats
path: root/crypto/ui
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2002-11-28 08:09:03 +0000
committerRichard Levitte <levitte@openssl.org>2002-11-28 08:09:03 +0000
commit75e3026a14339f3818fe57281979b7ee85399d43 (patch)
treeec56a26b6c553d120df76142a2b6241ac322b4c9 /crypto/ui
parent0a3af9a4038045ba59bcf10a4f9e0b6bb5107cd8 (diff)
Cleanse memory using the new OPENSSL_cleanse() function.
I've covered all the memset()s I felt safe modifying, but may have missed some.
Diffstat (limited to 'crypto/ui')
-rw-r--r--crypto/ui/ui_openssl.c2
-rw-r--r--crypto/ui/ui_util.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/crypto/ui/ui_openssl.c b/crypto/ui/ui_openssl.c
index 6d5f9cd8b1..e1a872ef7c 100644
--- a/crypto/ui/ui_openssl.c
+++ b/crypto/ui/ui_openssl.c
@@ -449,7 +449,7 @@ error:
ok=1;
#endif
- memset(result,0,BUFSIZ);
+ OPENSSL_cleanse(result,BUFSIZ);
return ok;
}
diff --git a/crypto/ui/ui_util.c b/crypto/ui/ui_util.c
index 8876128e56..fc8b691a87 100644
--- a/crypto/ui/ui_util.c
+++ b/crypto/ui/ui_util.c
@@ -65,7 +65,7 @@ int UI_UTIL_read_pw_string(char *buf,int length,const char *prompt,int verify)
int ret;
ret=UI_UTIL_read_pw(buf,buff,(length>BUFSIZ)?BUFSIZ:length,prompt,verify);
- memset(buff,0,BUFSIZ);
+ OPENSSL_cleanse(buff,BUFSIZ);
return(ret);
}