summaryrefslogtreecommitdiff
path: root/demos
diff options
context:
space:
mode:
authorBen Laurie <ben@openssl.org>2002-11-13 15:43:43 +0000
committerBen Laurie <ben@openssl.org>2002-11-13 15:43:43 +0000
commit54a656ef081f72a740c550ebd8099b40b8b5cde0 (patch)
tree9b3638b56848c7f0648b84cfa7ad056116b37a1b /demos
parent8f797f14b8ff7d3d5cb04443284259a0c94860b3 (diff)
downloadopenssl-new-54a656ef081f72a740c550ebd8099b40b8b5cde0.tar.gz
Security fixes brought forward from 0.9.7.
Diffstat (limited to 'demos')
-rw-r--r--demos/b64.c2
-rw-r--r--demos/spkigen.c3
2 files changed, 2 insertions, 3 deletions
diff --git a/demos/b64.c b/demos/b64.c
index 113da89baf..efdd44457d 100644
--- a/demos/b64.c
+++ b/demos/b64.c
@@ -83,7 +83,6 @@ char **argv;
unsigned char *buff=NULL,*bufsize=NULL;
int bsize=BSIZE,verbose=0;
int ret=1,inl;
- unsigned char key[24],iv[MD5_DIGEST_LENGTH];
char *str=NULL;
char *hkey=NULL,*hiv=NULL;
int enc=1,printkey=0,i,base64=0;
@@ -92,7 +91,6 @@ char **argv;
char *inf=NULL,*outf=NULL;
BIO *in=NULL,*out=NULL,*b64=NULL,*benc=NULL,*rbio=NULL,*wbio=NULL;
#define PROG_NAME_SIZE 39
- char pname[PROG_NAME_SIZE+1];
apps_startup();
diff --git a/demos/spkigen.c b/demos/spkigen.c
index d87881197c..2cd5dfea97 100644
--- a/demos/spkigen.c
+++ b/demos/spkigen.c
@@ -65,7 +65,8 @@ char *argv[];
fprintf(stderr,"please enter challenge string:");
fflush(stderr);
- fgets(buf,120,stdin);
+ buf[0]='\0';
+ fgets(buf,sizeof buf,stdin);
i=strlen(buf);
if (i > 0) buf[--i]='\0';
if (!ASN1_STRING_set((ASN1_STRING *)spki->spkac->challenge,