Loading apps/apps.c +6 −5 Original line number Diff line number Diff line Loading @@ -133,7 +133,7 @@ #undef NON_MAIN typedef struct { char *name; const char *name; unsigned long flag; unsigned long mask; } NAME_EX_TBL; Loading Loading @@ -1269,7 +1269,7 @@ static int set_table_opts(unsigned long *flags, const char *arg, const NAME_EX_T return 0; } void print_name(BIO *out, char *title, X509_NAME *nm, unsigned long lflags) void print_name(BIO *out, const char *title, X509_NAME *nm, unsigned long lflags) { char *buf; char mline = 0; Loading Loading @@ -1774,7 +1774,7 @@ int index_index(CA_DB *db) return 1; } int save_index(char *dbfile, char *suffix, CA_DB *db) int save_index(const char *dbfile, const char *suffix, CA_DB *db) { char buf[3][BSIZE]; BIO *out = BIO_new(BIO_s_file()); Loading Loading @@ -1841,7 +1841,7 @@ int save_index(char *dbfile, char *suffix, CA_DB *db) return 0; } int rotate_index(char *dbfile, char *new_suffix, char *old_suffix) int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix) { char buf[5][BSIZE]; int i,j; Loading Loading @@ -2281,7 +2281,8 @@ int args_verify(char ***pargs, int *pargc, } static void nodes_print(BIO *out, char *name, STACK_OF(X509_POLICY_NODE) *nodes) static void nodes_print(BIO *out, const char *name, STACK_OF(X509_POLICY_NODE) *nodes) { X509_POLICY_NODE *node; int i; Loading apps/apps.h +4 −4 Original line number Diff line number Diff line Loading @@ -254,7 +254,7 @@ void program_name(char *in,char *out,int size); int chopup_args(ARGS *arg,char *buf, int *argc, char **argv[]); #ifdef HEADER_X509_H int dump_cert_text(BIO *out, X509 *x); void print_name(BIO *out, char *title, X509_NAME *nm, unsigned long lflags); void print_name(BIO *out, const char *title, X509_NAME *nm, unsigned long lflags); #endif int set_cert_ex(unsigned long *flags, const char *arg); int set_name_ex(unsigned long *flags, const char *arg); Loading @@ -280,7 +280,7 @@ char *make_config_name(void); /* Functions defined in ca.c and also used in ocsp.c */ int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, char *str); ASN1_GENERALIZEDTIME **pinvtm, const char *str); #define DB_type 0 #define DB_exp_date 1 Loading Loading @@ -310,8 +310,8 @@ int rotate_serial(char *serialfile, char *new_suffix, char *old_suffix); int rand_serial(BIGNUM *b, ASN1_INTEGER *ai); CA_DB *load_index(char *dbfile, DB_ATTR *dbattr); int index_index(CA_DB *db); int save_index(char *dbfile, char *suffix, CA_DB *db); int rotate_index(char *dbfile, char *new_suffix, char *old_suffix); int save_index(const char *dbfile, const char *suffix, CA_DB *db); int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix); void free_index(CA_DB *db); int index_name_cmp(const char **a, const char **b); int parse_yesno(char *str, int def); Loading apps/ca.c +13 −11 Original line number Diff line number Diff line Loading @@ -143,7 +143,7 @@ #define REV_KEY_COMPROMISE 3 /* Value is cert key compromise time */ #define REV_CA_COMPROMISE 4 /* Value is CA key compromise time */ static char *ca_usage[]={ static const char *ca_usage[]={ "usage: ca args\n", "\n", " -verbose - Talk alot while doing things\n", Loading Loading @@ -192,7 +192,7 @@ extern int EF_PROTECT_BELOW; extern int EF_ALIGNMENT; #endif static void lookup_fail(char *name,char *tag); static void lookup_fail(const char *name, const char *tag); static int certify(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509, const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,CA_DB *db, BIGNUM *serial, char *subj, int multirdn, int email_dn, char *startdate, Loading Loading @@ -225,7 +225,7 @@ static int get_certificate_status(const char *ser_status, CA_DB *db); static int do_updatedb(CA_DB *db); static int check_time_format(char *str); char *make_revocation_str(int rev_type, char *rev_arg); int make_revoked(X509_REVOKED *rev, char *str); int make_revoked(X509_REVOKED *rev, const char *str); int old_entry_print(BIO *bp, ASN1_OBJECT *obj, ASN1_STRING *str); static CONF *conf=NULL; static CONF *extconf=NULL; Loading Loading @@ -300,7 +300,8 @@ int MAIN(int argc, char **argv) X509_REVOKED *r=NULL; ASN1_TIME *tmptm; ASN1_INTEGER *tmpser; char **pp,*p,*f; char *p,*f; const char **pp; int i,j; const EVP_MD *dgst=NULL; STACK_OF(CONF_VALUE) *attribs=NULL; Loading Loading @@ -857,7 +858,7 @@ bad: /* Lets check some fields */ for (i=0; i<sk_num(db->db->data); i++) { pp=(char **)sk_value(db->db->data,i); pp=(const char **)sk_value(db->db->data,i); if ((pp[DB_type][0] != DB_TYPE_REV) && (pp[DB_rev_date][0] != '\0')) { Loading Loading @@ -1501,7 +1502,7 @@ err: OPENSSL_EXIT(ret); } static void lookup_fail(char *name, char *tag) static void lookup_fail(const char *name, const char *tag) { BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag); } Loading Loading @@ -1646,7 +1647,7 @@ static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst, X509_NAME_ENTRY *tne,*push; EVP_PKEY *pktmp; int ok= -1,i,j,last,nid; char *p; const char *p; CONF_VALUE *cv; char *row[DB_NUMBER],**rrow=NULL,**irow=NULL; char buf[25]; Loading Loading @@ -2654,7 +2655,7 @@ err: return (cnt); } static char *crl_reasons[] = { static const char *crl_reasons[] = { /* CRL reason strings */ "unspecified", "keyCompromise", Loading Loading @@ -2682,7 +2683,8 @@ static char *crl_reasons[] = { char *make_revocation_str(int rev_type, char *rev_arg) { char *reason = NULL, *other = NULL, *str; char *other = NULL, *str; const char *reason = NULL; ASN1_OBJECT *otmp; ASN1_UTCTIME *revtm = NULL; int i; Loading Loading @@ -2776,7 +2778,7 @@ char *make_revocation_str(int rev_type, char *rev_arg) */ int make_revoked(X509_REVOKED *rev, char *str) int make_revoked(X509_REVOKED *rev, const char *str) { char *tmp = NULL; int reason_code = -1; Loading Loading @@ -2869,7 +2871,7 @@ int old_entry_print(BIO *bp, ASN1_OBJECT *obj, ASN1_STRING *str) return 1; } int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, char *str) int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, const char *str) { char *tmp = NULL; char *rtime_str, *reason_str = NULL, *arg_str = NULL, *p; Loading apps/ciphers.c +2 −2 Original line number Diff line number Diff line Loading @@ -69,7 +69,7 @@ #undef PROG #define PROG ciphers_main static char *ciphers_usage[]={ static const char *ciphers_usage[]={ "usage: ciphers args\n", " -v - verbose mode, a textual listing of the ciphers in SSLeay\n", " -ssl2 - SSL2 mode\n", Loading @@ -84,7 +84,7 @@ int MAIN(int argc, char **argv) { int ret=1,i; int verbose=0; char **pp; const char **pp; const char *p; int badops=0; SSL_CTX *ctx=NULL; Loading apps/crl.c +2 −2 Original line number Diff line number Diff line Loading @@ -72,7 +72,7 @@ #undef POSTFIX #define POSTFIX ".rvk" static char *crl_usage[]={ static const char *crl_usage[]={ "usage: crl args\n", "\n", " -inform arg - input format - default PEM (DER or PEM)\n", Loading Loading @@ -108,7 +108,7 @@ int MAIN(int argc, char **argv) char *infile=NULL,*outfile=NULL; int hash=0,issuer=0,lastupdate=0,nextupdate=0,noout=0,text=0; int fingerprint = 0; char **pp; const char **pp; X509_STORE *store = NULL; X509_STORE_CTX ctx; X509_LOOKUP *lookup = NULL; Loading Loading
apps/apps.c +6 −5 Original line number Diff line number Diff line Loading @@ -133,7 +133,7 @@ #undef NON_MAIN typedef struct { char *name; const char *name; unsigned long flag; unsigned long mask; } NAME_EX_TBL; Loading Loading @@ -1269,7 +1269,7 @@ static int set_table_opts(unsigned long *flags, const char *arg, const NAME_EX_T return 0; } void print_name(BIO *out, char *title, X509_NAME *nm, unsigned long lflags) void print_name(BIO *out, const char *title, X509_NAME *nm, unsigned long lflags) { char *buf; char mline = 0; Loading Loading @@ -1774,7 +1774,7 @@ int index_index(CA_DB *db) return 1; } int save_index(char *dbfile, char *suffix, CA_DB *db) int save_index(const char *dbfile, const char *suffix, CA_DB *db) { char buf[3][BSIZE]; BIO *out = BIO_new(BIO_s_file()); Loading Loading @@ -1841,7 +1841,7 @@ int save_index(char *dbfile, char *suffix, CA_DB *db) return 0; } int rotate_index(char *dbfile, char *new_suffix, char *old_suffix) int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix) { char buf[5][BSIZE]; int i,j; Loading Loading @@ -2281,7 +2281,8 @@ int args_verify(char ***pargs, int *pargc, } static void nodes_print(BIO *out, char *name, STACK_OF(X509_POLICY_NODE) *nodes) static void nodes_print(BIO *out, const char *name, STACK_OF(X509_POLICY_NODE) *nodes) { X509_POLICY_NODE *node; int i; Loading
apps/apps.h +4 −4 Original line number Diff line number Diff line Loading @@ -254,7 +254,7 @@ void program_name(char *in,char *out,int size); int chopup_args(ARGS *arg,char *buf, int *argc, char **argv[]); #ifdef HEADER_X509_H int dump_cert_text(BIO *out, X509 *x); void print_name(BIO *out, char *title, X509_NAME *nm, unsigned long lflags); void print_name(BIO *out, const char *title, X509_NAME *nm, unsigned long lflags); #endif int set_cert_ex(unsigned long *flags, const char *arg); int set_name_ex(unsigned long *flags, const char *arg); Loading @@ -280,7 +280,7 @@ char *make_config_name(void); /* Functions defined in ca.c and also used in ocsp.c */ int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, char *str); ASN1_GENERALIZEDTIME **pinvtm, const char *str); #define DB_type 0 #define DB_exp_date 1 Loading Loading @@ -310,8 +310,8 @@ int rotate_serial(char *serialfile, char *new_suffix, char *old_suffix); int rand_serial(BIGNUM *b, ASN1_INTEGER *ai); CA_DB *load_index(char *dbfile, DB_ATTR *dbattr); int index_index(CA_DB *db); int save_index(char *dbfile, char *suffix, CA_DB *db); int rotate_index(char *dbfile, char *new_suffix, char *old_suffix); int save_index(const char *dbfile, const char *suffix, CA_DB *db); int rotate_index(const char *dbfile, const char *new_suffix, const char *old_suffix); void free_index(CA_DB *db); int index_name_cmp(const char **a, const char **b); int parse_yesno(char *str, int def); Loading
apps/ca.c +13 −11 Original line number Diff line number Diff line Loading @@ -143,7 +143,7 @@ #define REV_KEY_COMPROMISE 3 /* Value is cert key compromise time */ #define REV_CA_COMPROMISE 4 /* Value is CA key compromise time */ static char *ca_usage[]={ static const char *ca_usage[]={ "usage: ca args\n", "\n", " -verbose - Talk alot while doing things\n", Loading Loading @@ -192,7 +192,7 @@ extern int EF_PROTECT_BELOW; extern int EF_ALIGNMENT; #endif static void lookup_fail(char *name,char *tag); static void lookup_fail(const char *name, const char *tag); static int certify(X509 **xret, char *infile,EVP_PKEY *pkey,X509 *x509, const EVP_MD *dgst,STACK_OF(CONF_VALUE) *policy,CA_DB *db, BIGNUM *serial, char *subj, int multirdn, int email_dn, char *startdate, Loading Loading @@ -225,7 +225,7 @@ static int get_certificate_status(const char *ser_status, CA_DB *db); static int do_updatedb(CA_DB *db); static int check_time_format(char *str); char *make_revocation_str(int rev_type, char *rev_arg); int make_revoked(X509_REVOKED *rev, char *str); int make_revoked(X509_REVOKED *rev, const char *str); int old_entry_print(BIO *bp, ASN1_OBJECT *obj, ASN1_STRING *str); static CONF *conf=NULL; static CONF *extconf=NULL; Loading Loading @@ -300,7 +300,8 @@ int MAIN(int argc, char **argv) X509_REVOKED *r=NULL; ASN1_TIME *tmptm; ASN1_INTEGER *tmpser; char **pp,*p,*f; char *p,*f; const char **pp; int i,j; const EVP_MD *dgst=NULL; STACK_OF(CONF_VALUE) *attribs=NULL; Loading Loading @@ -857,7 +858,7 @@ bad: /* Lets check some fields */ for (i=0; i<sk_num(db->db->data); i++) { pp=(char **)sk_value(db->db->data,i); pp=(const char **)sk_value(db->db->data,i); if ((pp[DB_type][0] != DB_TYPE_REV) && (pp[DB_rev_date][0] != '\0')) { Loading Loading @@ -1501,7 +1502,7 @@ err: OPENSSL_EXIT(ret); } static void lookup_fail(char *name, char *tag) static void lookup_fail(const char *name, const char *tag) { BIO_printf(bio_err,"variable lookup failed for %s::%s\n",name,tag); } Loading Loading @@ -1646,7 +1647,7 @@ static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, const EVP_MD *dgst, X509_NAME_ENTRY *tne,*push; EVP_PKEY *pktmp; int ok= -1,i,j,last,nid; char *p; const char *p; CONF_VALUE *cv; char *row[DB_NUMBER],**rrow=NULL,**irow=NULL; char buf[25]; Loading Loading @@ -2654,7 +2655,7 @@ err: return (cnt); } static char *crl_reasons[] = { static const char *crl_reasons[] = { /* CRL reason strings */ "unspecified", "keyCompromise", Loading Loading @@ -2682,7 +2683,8 @@ static char *crl_reasons[] = { char *make_revocation_str(int rev_type, char *rev_arg) { char *reason = NULL, *other = NULL, *str; char *other = NULL, *str; const char *reason = NULL; ASN1_OBJECT *otmp; ASN1_UTCTIME *revtm = NULL; int i; Loading Loading @@ -2776,7 +2778,7 @@ char *make_revocation_str(int rev_type, char *rev_arg) */ int make_revoked(X509_REVOKED *rev, char *str) int make_revoked(X509_REVOKED *rev, const char *str) { char *tmp = NULL; int reason_code = -1; Loading Loading @@ -2869,7 +2871,7 @@ int old_entry_print(BIO *bp, ASN1_OBJECT *obj, ASN1_STRING *str) return 1; } int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, char *str) int unpack_revinfo(ASN1_TIME **prevtm, int *preason, ASN1_OBJECT **phold, ASN1_GENERALIZEDTIME **pinvtm, const char *str) { char *tmp = NULL; char *rtime_str, *reason_str = NULL, *arg_str = NULL, *p; Loading
apps/ciphers.c +2 −2 Original line number Diff line number Diff line Loading @@ -69,7 +69,7 @@ #undef PROG #define PROG ciphers_main static char *ciphers_usage[]={ static const char *ciphers_usage[]={ "usage: ciphers args\n", " -v - verbose mode, a textual listing of the ciphers in SSLeay\n", " -ssl2 - SSL2 mode\n", Loading @@ -84,7 +84,7 @@ int MAIN(int argc, char **argv) { int ret=1,i; int verbose=0; char **pp; const char **pp; const char *p; int badops=0; SSL_CTX *ctx=NULL; Loading
apps/crl.c +2 −2 Original line number Diff line number Diff line Loading @@ -72,7 +72,7 @@ #undef POSTFIX #define POSTFIX ".rvk" static char *crl_usage[]={ static const char *crl_usage[]={ "usage: crl args\n", "\n", " -inform arg - input format - default PEM (DER or PEM)\n", Loading Loading @@ -108,7 +108,7 @@ int MAIN(int argc, char **argv) char *infile=NULL,*outfile=NULL; int hash=0,issuer=0,lastupdate=0,nextupdate=0,noout=0,text=0; int fingerprint = 0; char **pp; const char **pp; X509_STORE *store = NULL; X509_STORE_CTX ctx; X509_LOOKUP *lookup = NULL; Loading