head 1.2; access; symbols pkgsrc-2014Q3:1.1.0.26 pkgsrc-2014Q3-base:1.1 pkgsrc-2014Q2:1.1.0.24 pkgsrc-2014Q2-base:1.1 pkgsrc-2014Q1:1.1.0.22 pkgsrc-2014Q1-base:1.1 pkgsrc-2013Q4:1.1.0.20 pkgsrc-2013Q4-base:1.1 pkgsrc-2013Q3:1.1.0.18 pkgsrc-2013Q3-base:1.1 pkgsrc-2013Q2:1.1.0.16 pkgsrc-2013Q2-base:1.1 pkgsrc-2013Q1:1.1.0.14 pkgsrc-2013Q1-base:1.1 pkgsrc-2012Q4:1.1.0.12 pkgsrc-2012Q4-base:1.1 pkgsrc-2012Q3:1.1.0.10 pkgsrc-2012Q3-base:1.1 pkgsrc-2012Q2:1.1.0.8 pkgsrc-2012Q2-base:1.1 pkgsrc-2012Q1:1.1.0.6 pkgsrc-2012Q1-base:1.1 pkgsrc-2011Q4:1.1.0.4 pkgsrc-2011Q4-base:1.1 pkgsrc-2011Q3:1.1.0.2 pkgsrc-2011Q3-base:1.1; locks; strict; comment @# @; 1.2 date 2014.12.28.14.16.14; author bsiegert; state dead; branches; next 1.1; commitid ti3HPB4S3ecOxO3y; 1.1 date 2011.10.01.11.49.20; author shattered; state Exp; branches; next ; desc @@ 1.2 log @Update heirloom-mailx to 12.5. From maintainer in PR pkg/49492. Significant changes: - MASTER_SITES now points at ${MASTER_SITE_DEBIAN:=pool/main/h/heirloom-mailx/} - LICENSE filled out based on content of COPYING file in source - addresses CVE-2004-2771 and CVE-2014-7844; address expansion disabled by default - remove SSL2 related code to match state of OpenSSL @ text @$NetBSD: patch-ab,v 1.1 2011/10/01 11:49:20 shattered Exp $ --- openssl.c.orig 2007-08-04 11:38:03.000000000 +0000 +++ openssl.c @@@@ -38,7 +38,7 @@@@ #ifndef lint #ifdef DOSCCS -static char sccsid[] = "@@(#)openssl.c 1.25 (gritter) 8/4/07"; +static char sccsid[] = "@@(#)openssl.c 1.26 (gritter) 5/26/09"; #endif #endif /* not lint */ @@@@ -101,12 +101,17 @@@@ static void sslcatch(int s); static int ssl_rand_init(void); static void ssl_init(void); static int ssl_verify_cb(int success, X509_STORE_CTX *store); -static SSL_METHOD *ssl_select_method(const char *uhp); +static const SSL_METHOD *ssl_select_method(const char *uhp); static void ssl_load_verifications(struct sock *sp); static void ssl_certificate(struct sock *sp, const char *uhp); static enum okay ssl_check_host(const char *server, struct sock *sp); +#ifdef HAVE_STACK_OF +static int smime_verify(struct message *m, int n, STACK_OF(X509) *chain, + X509_STORE *store); +#else static int smime_verify(struct message *m, int n, STACK *chain, X509_STORE *store); +#endif static EVP_CIPHER *smime_cipher(const char *name); static int ssl_password_cb(char *buf, int size, int rwflag, void *userdata); static FILE *smime_sign_cert(const char *xname, const char *xname2, int warn); @@@@ -203,10 +208,10 @@@@ ssl_verify_cb(int success, X509_STORE_CT return 1; } -static SSL_METHOD * +static const SSL_METHOD * ssl_select_method(const char *uhp) { - SSL_METHOD *method; + const SSL_METHOD *method; char *cp; cp = ssl_method_string(uhp); @@@@ -308,7 +313,11 @@@@ ssl_check_host(const char *server, struc X509 *cert; X509_NAME *subj; char data[256]; +#ifdef HAVE_STACK_OF + STACK_OF(GENERAL_NAME) *gens; +#else /*GENERAL_NAMES*/STACK *gens; +#endif GENERAL_NAME *gen; int i; @@@@ -357,7 +366,8 @@@@ ssl_open(const char *server, struct sock ssl_init(); ssl_set_vrfy_level(uhp); - if ((sp->s_ctx = SSL_CTX_new(ssl_select_method(uhp))) == NULL) { + if ((sp->s_ctx = + SSL_CTX_new((SSL_METHOD *)ssl_select_method(uhp))) == NULL) { ssl_gen_err(catgets(catd, CATSET, 261, "SSL_CTX_new() failed")); return STOP; } @@@@ -496,7 +506,11 @@@@ smime_sign(FILE *ip, struct header *head } static int +#ifdef HAVE_STACK_OF +smime_verify(struct message *m, int n, STACK_OF(X509) *chain, X509_STORE *store) +#else smime_verify(struct message *m, int n, STACK *chain, X509_STORE *store) +#endif { struct message *x; char *cp, *sender, *to, *cc, *cnttype; @@@@ -505,7 +519,12 @@@@ smime_verify(struct message *m, int n, S off_t size; BIO *fb, *pb; PKCS7 *pkcs7; +#ifdef HAVE_STACK_OF + STACK_OF(X509) *certs; + STACK_OF(GENERAL_NAME) *gens; +#else STACK *certs, *gens; +#endif X509 *cert; X509_NAME *subj; char data[LINESIZE]; @@@@ -614,7 +633,11 @@@@ cverify(void *vp) { int *msgvec = vp, *ip; int ec = 0; +#ifdef HAVE_STACK_OF + STACK_OF(X509) *chain = NULL; +#else STACK *chain = NULL; +#endif X509_STORE *store; char *ca_dir, *ca_file; @@@@ -687,7 +710,11 @@@@ smime_encrypt(FILE *ip, const char *cert X509 *cert; PKCS7 *pkcs7; BIO *bb, *yb; +#ifdef HAVE_STACK_OF + STACK_OF(X509) *certs; +#else STACK *certs; +#endif EVP_CIPHER *cipher; certfile = expand((char *)certfile); @@@@ -950,9 +977,14 @@@@ smime_certsave(struct message *m, int n, off_t size; BIO *fb, *pb; PKCS7 *pkcs7; +#ifdef HAVE_STACK_OF + STACK_OF(X509) *certs; + STACK_OF(X509) *chain = NULL; +#else STACK *certs; - X509 *cert; STACK *chain = NULL; +#endif + X509 *cert; enum okay ok = OKAY; message_number = n; @ 1.1 log @PR/44024 -- fix failure to build with recent openssl @ text @d1 1 a1 1 $NetBSD$ @