diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/apps.c | 31 | ||||
-rw-r--r-- | apps/asn1pars.c | 4 | ||||
-rw-r--r-- | apps/ca.c | 136 | ||||
-rw-r--r-- | apps/ciphers.c | 4 | ||||
-rw-r--r-- | apps/crl.c | 8 | ||||
-rw-r--r-- | apps/crl2p7.c | 8 | ||||
-rw-r--r-- | apps/dgst.c | 9 | ||||
-rw-r--r-- | apps/dh.c | 4 | ||||
-rw-r--r-- | apps/dsa.c | 4 | ||||
-rw-r--r-- | apps/dsaparam.c | 9 | ||||
-rw-r--r-- | apps/enc.c | 9 | ||||
-rw-r--r-- | apps/errstr.c | 4 | ||||
-rw-r--r-- | apps/gendh.c | 12 | ||||
-rw-r--r-- | apps/gendsa.c | 7 | ||||
-rw-r--r-- | apps/genrsa.c | 12 | ||||
-rw-r--r-- | apps/nseq.c | 8 | ||||
-rw-r--r-- | apps/openssl.c | 20 | ||||
-rw-r--r-- | apps/pem_mail.c | 4 | ||||
-rw-r--r-- | apps/pkcs12.c | 54 | ||||
-rw-r--r-- | apps/pkcs7.c | 4 | ||||
-rw-r--r-- | apps/req.c | 46 | ||||
-rw-r--r-- | apps/rsa.c | 4 | ||||
-rw-r--r-- | apps/s_cb.c | 23 | ||||
-rw-r--r-- | apps/s_client.c | 11 | ||||
-rw-r--r-- | apps/s_server.c | 40 | ||||
-rw-r--r-- | apps/s_socket.c | 73 | ||||
-rw-r--r-- | apps/s_time.c | 20 | ||||
-rw-r--r-- | apps/sc.c | 6 | ||||
-rw-r--r-- | apps/sess_id.c | 8 | ||||
-rw-r--r-- | apps/speed.c | 23 | ||||
-rw-r--r-- | apps/verify.c | 12 | ||||
-rw-r--r-- | apps/version.c | 4 | ||||
-rw-r--r-- | apps/x509.c | 35 |
33 files changed, 162 insertions, 494 deletions
diff --git a/apps/apps.c b/apps/apps.c index 5f0c8fa539..ba07016e83 100644 --- a/apps/apps.c +++ b/apps/apps.c @@ -76,10 +76,7 @@ int app_init(); #endif #ifdef undef /* never finished - probably never will be :-) */ -int args_from_file(file,argc,argv) -char *file; -int *argc; -char **argv[]; +int args_from_file(char *file, int *argc, char **argv[]) { FILE *fp; int num,i; @@ -157,8 +154,7 @@ char **argv[]; } #endif -int str2fmt(s) -char *s; +int str2fmt(char *s) { if ((*s == 'D') || (*s == 'd')) return(FORMAT_ASN1); @@ -173,10 +169,7 @@ char *s; } #if defined(MSDOS) || defined(WIN32) || defined(WIN16) -void program_name(in,out,size) -char *in; -char *out; -int size; +void program_name(char *in, char *out, int size) { int i,n; char *p=NULL; @@ -213,10 +206,7 @@ int size; out[n]='\0'; } #else -void program_name(in,out,size) -char *in; -char *out; -int size; +void program_name(char *in, char *out, int size) { char *p; @@ -231,9 +221,7 @@ int size; #endif #ifdef WIN32 -int WIN32_rename(from,to) -char *from; -char *to; +int WIN32_rename(char *from, char *to) { int ret; @@ -242,11 +230,7 @@ char *to; } #endif -int chopup_args(arg,buf,argc,argv) -ARGS *arg; -char *buf; -int *argc; -char **argv[]; +int chopup_args(ARGS *arg, char *buf, int *argc, char **argv[]) { int num,len,i; char *p; @@ -312,8 +296,7 @@ char **argv[]; } #ifndef APP_INIT -int app_init(mesgwin) -long mesgwin; +int app_init(long mesgwin) { return(1); } diff --git a/apps/asn1pars.c b/apps/asn1pars.c index cf9a3bf2bc..39e97887af 100644 --- a/apps/asn1pars.c +++ b/apps/asn1pars.c @@ -80,9 +80,7 @@ #undef PROG #define PROG asn1parse_main -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int i,badops=0,offset=0,ret=1,j; unsigned int length=0; @@ -215,9 +215,7 @@ static char *section=NULL; static int preserve=0; static int msie_hack=0; -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int total=0; int total_done=0; @@ -1179,16 +1177,12 @@ err: EXIT(ret); } -static void lookup_fail(name,tag) -char *name; -char *tag; +static void lookup_fail(char *name, char *tag) { BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag); } -static int MS_CALLBACK key_callback(buf,len,verify) -char *buf; -int len,verify; +static int MS_CALLBACK key_callback(char *buf, int len, int verify) { int i; @@ -1199,8 +1193,7 @@ int len,verify; return(i); } -static unsigned long index_serial_hash(a) -char **a; +static unsigned long index_serial_hash(char **a) { char *n; @@ -1209,9 +1202,7 @@ char **a; return(lh_strhash(n)); } -static int index_serial_cmp(a,b) -char **a; -char **b; +static int index_serial_cmp(char **a, char **b) { char *aa,*bb; @@ -1220,21 +1211,17 @@ char **b; return(strcmp(aa,bb)); } -static unsigned long index_name_hash(a) -char **a; +static unsigned long index_name_hash(char **a) { return(lh_strhash(a[DB_name])); } -static int index_name_qual(a) -char **a; +static int index_name_qual(char **a) { return(a[0][0] == 'V'); } -static int index_name_cmp(a,b) -char **a; -char **b; - { return(strcmp(a[DB_name],b[DB_name])); } +static int index_name_cmp(char **a, char **b) + { return(strcmp(a[DB_name], + b[DB_name])); } -static BIGNUM *load_serial(serialfile) -char *serialfile; +static BIGNUM *load_serial(char *serialfile) { BIO *in=NULL; BIGNUM *ret=NULL; @@ -1272,9 +1259,7 @@ err: return(ret); } -static int save_serial(serialfile,serial) -char *serialfile; -BIGNUM *serial; +static int save_serial(char *serialfile, BIGNUM *serial) { BIO *out; int ret=0; @@ -1306,22 +1291,10 @@ err: return(ret); } -static int certify(xret,infile,pkey,x509,dgst,policy,db,serial,startdate,days, - batch,ext_sect,lconf,verbose) -X509 **xret; -char *infile; -EVP_PKEY *pkey; -X509 *x509; -const EVP_MD *dgst; -STACK *policy; -TXT_DB *db; -BIGNUM *serial; -char *startdate; -int days; -int batch; -char *ext_sect; -LHASH *lconf; -int verbose; +static int certify(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509, + const EVP_MD *dgst, STACK *policy, TXT_DB *db, BIGNUM *serial, + char *startdate, int days, int batch, char *ext_sect, LHASH *lconf, + int verbose) { X509_REQ *req=NULL; BIO *in=NULL; @@ -1377,22 +1350,11 @@ err: return(ok); } -static int certify_cert(xret,infile,pkey,x509,dgst,policy,db,serial,startdate, - days,batch,ext_sect,lconf,verbose) -X509 **xret; -char *infile; -EVP_PKEY *pkey; -X509 *x509; -const EVP_MD *dgst; -STACK *policy; -TXT_DB *db; -BIGNUM *serial; -char *startdate; -int days; -int batch; -char *ext_sect; -LHASH *lconf; -int verbose; +static int certify_cert(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509, + const EVP_MD *dgst, STACK *policy, TXT_DB *db, BIGNUM *serial, + char *startdate, int days, int batch, char *ext_sect, LHASH *lconf, + int verbose) + { X509 *req=NULL; X509_REQ *rreq=NULL; @@ -1452,22 +1414,9 @@ err: return(ok); } -static int do_body(xret,pkey,x509,dgst,policy,db,serial,startdate,days, - batch,verbose,req,ext_sect,lconf) -X509 **xret; -EVP_PKEY *pkey; -X509 *x509; -const EVP_MD *dgst; -STACK *policy; -TXT_DB *db; -BIGNUM *serial; -char *startdate; -int days; -int batch; -int verbose; -X509_REQ *req; -char *ext_sect; -LHASH *lconf; +static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst, + STACK *policy, TXT_DB *db, BIGNUM *serial, char *startdate, int days, + int batch, int verbose, X509_REQ *req, char *ext_sect, LHASH *lconf) { X509_NAME *name=NULL,*CAname=NULL,*subject=NULL; ASN1_UTCTIME *tm,*tmptm; @@ -1895,10 +1844,7 @@ err: return(ok); } -static void write_new_certificate(bp,x, output_der) -BIO *bp; -X509 *x; -int output_der; +static void write_new_certificate(BIO *bp, X509 *x, int output_der) { char *f; char buf[256]; @@ -1924,21 +1870,9 @@ int output_der; BIO_puts(bp,"\n"); } -static int certify_spkac(xret,infile,pkey,x509,dgst,policy,db,serial, - startdate,days,ext_sect,lconf,verbose) -X509 **xret; -char *infile; -EVP_PKEY *pkey; -X509 *x509; -const EVP_MD *dgst; -STACK *policy; -TXT_DB *db; -BIGNUM *serial; -char *startdate; -int days; -char *ext_sect; -LHASH *lconf; -int verbose; +static int certify_spkac(X509 **xret, char *infile, EVP_PKEY *pkey, X509 *x509, + const EVP_MD *dgst, STACK *policy, TXT_DB *db, BIGNUM *serial, + char *startdate, int days, char *ext_sect, LHASH *lconf, int verbose) { STACK *sk=NULL; LHASH *parms=NULL; @@ -2094,9 +2028,7 @@ err: return(ok); } -static int fix_data(nid,type) -int nid; -int *type; +static int fix_data(int nid, int *type) { if (nid == NID_pkcs9_emailAddress) *type=V_ASN1_IA5STRING; @@ -2111,8 +2043,7 @@ int *type; return(1); } -static int check_time_format(str) -char *str; +static int check_time_format(char *str) { ASN1_UTCTIME tm; @@ -2122,8 +2053,7 @@ char *str; return(ASN1_UTCTIME_check(&tm)); } -static int add_oid_section(hconf) -LHASH *hconf; +static int add_oid_section(LHASH *hconf) { char *p; STACK *sktmp; @@ -2145,9 +2075,7 @@ LHASH *hconf; return 1; } -static int do_revoke(x509,db) -X509 *x509; -TXT_DB *db; +static int do_revoke(X509 *x509, TXT_DB *db) { ASN1_UTCTIME *tm=NULL; char *row[DB_NUMBER],**rrow,**irow; diff --git a/apps/ciphers.c b/apps/ciphers.c index 146527790e..b02b64b5df 100644 --- a/apps/ciphers.c +++ b/apps/ciphers.c @@ -77,9 +77,7 @@ static char *ciphers_usage[]={ NULL }; -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int ret=1,i; int verbose=0; diff --git a/apps/crl.c b/apps/crl.c index 3bb7aae11e..0c03f5fb6c 100644 --- a/apps/crl.c +++ b/apps/crl.c @@ -96,9 +96,7 @@ static X509_CRL *load_crl(); static BIO *bio_out=NULL; -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { X509_CRL *x=NULL; int ret=1,i,num,badops=0; @@ -262,9 +260,7 @@ end: EXIT(ret); } -static X509_CRL *load_crl(infile, format) -char *infile; -int format; +static X509_CRL *load_crl(char *infile, int format) { X509_CRL *x=NULL; BIO *in=NULL; diff --git a/apps/crl2p7.c b/apps/crl2p7.c index beadc96caf..aa407b7098 100644 --- a/apps/crl2p7.c +++ b/apps/crl2p7.c @@ -87,9 +87,7 @@ static int add_certs_from_file(); * -out arg - output file - default stdout */ -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int i,badops=0; BIO *in=NULL,*out=NULL; @@ -288,9 +286,7 @@ end: * number of certs added if successful, -1 if not. *---------------------------------------------------------------------- */ -static int add_certs_from_file(stack,certfile) -STACK_OF(X509) *stack; -char *certfile; +static int add_certs_from_file(STACK_OF(X509) *stack, char *certfile) { struct stat st; BIO *in=NULL; diff --git a/apps/dgst.c b/apps/dgst.c index eb7462d0b1..2926e5514f 100644 --- a/apps/dgst.c +++ b/apps/dgst.c @@ -79,9 +79,7 @@ void do_fp(unsigned char *buf,BIO *f,int sep); void do_fp(); #endif -int MAIN(argc,argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { unsigned char *buf=NULL; int i,err=0; @@ -203,10 +201,7 @@ end: EXIT(err); } -void do_fp(buf,bp,sep) -unsigned char *buf; -BIO *bp; -int sep; +void do_fp(unsigned char *buf, BIO *bp, int sep) { int len; int i; @@ -81,9 +81,7 @@ * -C */ -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { DH *dh=NULL; int i,badops=0,text=0; diff --git a/apps/dsa.c b/apps/dsa.c index 1f57c46005..312ed31798 100644 --- a/apps/dsa.c +++ b/apps/dsa.c @@ -82,9 +82,7 @@ * -modulus - print the DSA public key */ -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int ret=1; DSA *dsa=NULL; diff --git a/apps/dsaparam.c b/apps/dsaparam.c index e01f939748..085e4845c1 100644 --- a/apps/dsaparam.c +++ b/apps/dsaparam.c @@ -89,9 +89,7 @@ static void MS_CALLBACK dsa_cb(int p, int n, char *arg); static void MS_CALLBACK dsa_cb(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { DSA *dsa=NULL; int i,badops=0,text=0; @@ -342,10 +340,7 @@ end: EXIT(ret); } -static void MS_CALLBACK dsa_cb(p, n, arg) -int p; -int n; -char *arg; +static void MS_CALLBACK dsa_cb(int p, int n, char *arg) { char c='*'; diff --git a/apps/enc.c b/apps/enc.c index 00cc336177..b561326733 100644 --- a/apps/enc.c +++ b/apps/enc.c @@ -84,9 +84,7 @@ int set_hex(); #define BSIZE (8*1024) #define PROG enc_main -int MAIN(argc,argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { char *strbuf=NULL; unsigned char *buff=NULL,*bufsize=NULL; @@ -521,10 +519,7 @@ end: EXIT(ret); } -int set_hex(in,out,size) -char *in; -unsigned char *out; -int size; +int set_hex(char *in, unsigned char *out, int size) { int i,n; unsigned char j; diff --git a/apps/errstr.c b/apps/errstr.c index d2b2b3fcea..ee51abaf34 100644 --- a/apps/errstr.c +++ b/apps/errstr.c @@ -68,9 +68,7 @@ #undef PROG #define PROG errstr_main -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int i,ret=0; char buf[256]; diff --git a/apps/gendh.c b/apps/gendh.c index 2790f179fd..8900b4f1af 100644 --- a/apps/gendh.c +++ b/apps/gendh.c @@ -81,9 +81,7 @@ static void MS_CALLBACK dh_cb(); static long dh_load_rand(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { char buffer[200]; DH *dh=NULL; @@ -191,10 +189,7 @@ end: EXIT(ret); } -static void MS_CALLBACK dh_cb(p,n,arg) -int p; -int n; -char *arg; +static void MS_CALLBACK dh_cb(int p, int n, char *arg) { char c='*'; @@ -209,8 +204,7 @@ char *arg; #endif } -static long dh_load_rand(name) -char *name; +static long dh_load_rand(char *name) { char *p,*n; int last; diff --git a/apps/gendsa.c b/apps/gendsa.c index 311d95020b..3e198a24f9 100644 --- a/apps/gendsa.c +++ b/apps/gendsa.c @@ -79,9 +79,7 @@ static long dsa_load_rand(char *names); static long dsa_load_rand(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { char buffer[200]; DSA *dsa=NULL; @@ -214,8 +212,7 @@ end: EXIT(ret); } -static long dsa_load_rand(name) -char *name; +static long dsa_load_rand(char *name) { char *p,*n; int last; diff --git a/apps/genrsa.c b/apps/genrsa.c index cdba6189ad..f83bafc7f1 100644 --- a/apps/genrsa.c +++ b/apps/genrsa.c @@ -82,9 +82,7 @@ static void MS_CALLBACK genrsa_cb(); static long gr_load_rand(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { int ret=1; char buffer[200]; @@ -234,10 +232,7 @@ err: EXIT(ret); } -static void MS_CALLBACK genrsa_cb(p, n, arg) -int p; -int n; -char *arg; +static void MS_CALLBACK genrsa_cb(int p, int n, char *arg) { char c='*'; @@ -252,8 +247,7 @@ char *arg; #endif } -static long gr_load_rand(name) -char *name; +static long gr_load_rand(char *name) { char *p,*n; int last; diff --git a/apps/nseq.c b/apps/nseq.c index e87c6c77a7..3c70e4d2be 100644 --- a/apps/nseq.c +++ b/apps/nseq.c @@ -70,9 +70,7 @@ static int dump_cert_text(BIO *out, X509 *x); static int dump_cert_text(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { char **args, *infile = NULL, *outfile = NULL; BIO *in = NULL, *out = NULL; @@ -163,9 +161,7 @@ end: EXIT(ret); } -static int dump_cert_text(out, x) -BIO *out; -X509 *x; +static int dump_cert_text(BIO *out, X509 *x) { char buf[256]; X509_NAME_oneline(X509_get_subject_name(x),buf,256); diff --git a/apps/openssl.c b/apps/openssl.c index dd22aa78af..21724201d6 100644 --- a/apps/openssl.c +++ b/apps/openssl.c @@ -99,8 +99,7 @@ LHASH *config=NULL; char *default_config_file=NULL; #ifdef DEBUG -static void sig_stop(i) -int i; +static void sig_stop(int i) { char *a=NULL; @@ -113,9 +112,7 @@ int i; BIO *bio_err=NULL; #endif -int main(Argc,Argv) -int Argc; -char *Argv[]; +int main(int Argc, char *Argv[]) { ARGS arg; #define PROG_NAME_SIZE 16 @@ -258,10 +255,7 @@ end: #define LIST_MESSAGE_DIGEST_COMMANDS "list-message-digest-commands" #define LIST_CIPHER_COMMANDS "list-cipher-commands" -static int do_cmd(prog,argc,argv) -LHASH *prog; -int argc; -char *argv[]; +static int do_cmd(LHASH *prog, int argc, char *argv[]) { FUNCTION f,*fp; int i,ret=1,tp,nl; @@ -354,7 +348,7 @@ static int SortFnByName(const void *_f1,const void *_f2) return strcmp(f1->name,f2->name); } -static LHASH *prog_init() +static LHASH *prog_init(void) { LHASH *ret; FUNCTION *f; @@ -372,14 +366,12 @@ static LHASH *prog_init() return(ret); } -static int MS_CALLBACK cmp(a,b) -FUNCTION *a,*b; +static int MS_CALLBACK cmp(FUNCTION *a, FUNCTION *b) { return(strncmp(a->name,b->name,8)); } -static unsigned long MS_CALLBACK hash(a) -FUNCTION *a; +static unsigned long MS_CALLBACK hash(FUNCTION *a) { return(lh_strhash(a->name)); } diff --git a/apps/pem_mail.c b/apps/pem_mail.c index 64e04acb52..acbf7bd9a0 100644 --- a/apps/pem_mail.c +++ b/apps/pem_mail.c @@ -87,9 +87,7 @@ typedef struct lines_St struct lines_st *next; } LINES; -int main(argc, argv) -int argc; -char **argv; +int main(int argc, char **argv) { FILE *in; RSA *rsa=NULL; diff --git a/apps/pkcs12.c b/apps/pkcs12.c index 96e0379fad..266bfa89ab 100644 --- a/apps/pkcs12.c +++ b/apps/pkcs12.c @@ -96,9 +96,7 @@ int alg_print(); int cert_load(); #endif -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { char *infile=NULL, *outfile=NULL, *keyname = NULL; char *certfile=NULL; @@ -440,9 +438,7 @@ if (export_cert) { EXIT(ret); } -int dump_cert_text (out, x) -BIO *out; -X509 *x; +int dump_cert_text (BIO *out, X509 *x) { char buf[256]; X509_NAME_oneline(X509_get_subject_name(x),buf,256); @@ -456,12 +452,8 @@ X509 *x; return 0; } -int dump_certs_keys_p12 (out, p12, pass, passlen, options) -BIO *out; -PKCS12 *p12; -unsigned char *pass; -int passlen; -int options; +int dump_certs_keys_p12 (BIO *out, PKCS12 *p12, unsigned char *pass, + int passlen, int options) { STACK *asafes, *bags; int i, bagnid; @@ -493,12 +485,8 @@ int options; return 1; } -int dump_certs_pkeys_bags (out, bags, pass, passlen, options) -BIO *out; -STACK *bags; -unsigned char *pass; -int passlen; -int options; +int dump_certs_pkeys_bags (BIO *out, STACK *bags, unsigned char *pass, + int passlen, int options) { int i; for (i = 0; i < sk_num (bags); i++) { @@ -509,12 +497,8 @@ int options; return 1; } -int dump_certs_pkeys_bag (out, bag, pass, passlen, options) -BIO *out; -PKCS12_SAFEBAG *bag; -unsigned char *pass; -int passlen; -int options; +int dump_certs_pkeys_bag (BIO *out, PKCS12_SAFEBAG *bag, unsigned char *pass, + int passlen, int options) { EVP_PKEY *pkey; PKCS8_PRIV_KEY_INFO *p8; @@ -584,9 +568,7 @@ int options; /* Hope this is OK .... */ -int get_cert_chain (cert, chain) -X509 *cert; -STACK **chain; +int get_cert_chain (X509 *cert, STACK **chain) { X509_STORE *store; X509_STORE_CTX store_ctx; @@ -614,9 +596,7 @@ err: return i; } -int alg_print (x, alg) -BIO *x; -X509_ALGOR *alg; +int alg_print (BIO *x, X509_ALGOR *alg) { PBEPARAM *pbe; unsigned char *p; @@ -630,9 +610,7 @@ X509_ALGOR *alg; /* Load all certificates from a given file */ -int cert_load(in, sk) -BIO *in; -STACK *sk; +int cert_load(BIO *in, STACK *sk) { int ret; X509 *cert; @@ -647,10 +625,7 @@ STACK *sk; /* Generalised attribute print: handle PKCS#8 and bag attributes */ -int print_attribs (out, attrlst, name) -BIO *out; -STACK *attrlst; -char *name; +int print_attribs (BIO *out, STACK *attrlst, char *name) { X509_ATTRIBUTE *attr; ASN1_TYPE *av; @@ -705,10 +680,7 @@ char *name; return 1; } -void hex_prin(out, buf, len) -BIO *out; -unsigned char *buf; -int len; +void hex_prin(BIO *out, unsigned char *buf, int len) { int i; for (i = 0; i < len; i++) BIO_printf (out, "%02X ", buf[i]); diff --git a/apps/pkcs7.c b/apps/pkcs7.c index cac75f48b2..ece2cd7d68 100644 --- a/apps/pkcs7.c +++ b/apps/pkcs7.c @@ -81,9 +81,7 @@ * -print_certs */ -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { PKCS7 *p7=NULL; int i,badops=0; diff --git a/apps/req.c b/apps/req.c index bb3a65a5bc..ce7e318777 100644 --- a/apps/req.c +++ b/apps/req.c @@ -137,9 +137,7 @@ static LHASH *req_conf=NULL; #define TYPE_DSA 2 #define TYPE_DH 3 -int MAIN(argc, argv) -int argc; -char **argv; +int MAIN(int argc, char **argv) { #ifndef NO_DSA DSA *dsa_params=NULL; @@ -825,10 +823,7 @@ end: EXIT(ex); } -static int make_REQ(req,pkey,attribs) -X509_REQ *req; -EVP_PKEY *pkey; -int attribs; +static int make_REQ(X509_REQ *req, EVP_PKEY *pkey, int attribs) { int ret=0,i; unsigned char *p,*q; @@ -984,14 +979,8 @@ err: return(ret); } -static int add_DN_object(n,text,def,value,nid,min,max) -X509_NAME *n; -char *text; -char *def; -char *value; -int nid; -int min; -int max; +static int add_DN_object(X509_NAME *n, char *text, char *def, char *value, + int nid, int min, int max) { int i,j,ret=0; X509_NAME_ENTRY *ne=NULL; @@ -1044,14 +1033,8 @@ err: return(ret); } -static int add_attribute_object(n,text,de |