From 74e2c009c83ad374bd6acdcfc376a384e25ab007 Mon Sep 17 00:00:00 2001 From: jsing <> Date: Fri, 11 Jul 2014 08:44:49 +0000 Subject: Only import cryptlib.h in the four source files that actually need it. Remove the openssl public includes from cryptlib.h and add a small number of includes into the source files that actually need them. While here, also sort/group/tidy the includes. ok beck@ miod@ --- src/lib/libcrypto/x509/by_dir.c | 9 ++++----- src/lib/libcrypto/x509/by_file.c | 9 ++++----- src/lib/libcrypto/x509/x509_att.c | 9 +++++---- src/lib/libcrypto/x509/x509_cmp.c | 4 ++-- src/lib/libcrypto/x509/x509_d2.c | 5 +++-- src/lib/libcrypto/x509/x509_ext.c | 9 ++++----- src/lib/libcrypto/x509/x509_lu.c | 5 +++-- src/lib/libcrypto/x509/x509_obj.c | 6 +++--- src/lib/libcrypto/x509/x509_r2x.c | 11 ++++++----- src/lib/libcrypto/x509/x509_req.c | 12 ++++++------ src/lib/libcrypto/x509/x509_set.c | 6 +++--- src/lib/libcrypto/x509/x509_trs.c | 6 +++--- src/lib/libcrypto/x509/x509_txt.c | 11 +++++------ src/lib/libcrypto/x509/x509_v3.c | 9 +++++---- src/lib/libcrypto/x509/x509_vfy.c | 12 ++++++------ src/lib/libcrypto/x509/x509_vpm.c | 5 ++--- src/lib/libcrypto/x509/x509cset.c | 6 +++--- src/lib/libcrypto/x509/x509name.c | 8 ++++---- src/lib/libcrypto/x509/x509rset.c | 6 +++--- src/lib/libcrypto/x509/x509spki.c | 4 ++-- src/lib/libcrypto/x509/x509type.c | 4 ++-- src/lib/libcrypto/x509/x_all.c | 14 +++++++------- 22 files changed, 85 insertions(+), 85 deletions(-) (limited to 'src/lib/libcrypto/x509') diff --git a/src/lib/libcrypto/x509/by_dir.c b/src/lib/libcrypto/x509/by_dir.c index 110c22d6f5..a7dc2292bc 100644 --- a/src/lib/libcrypto/x509/by_dir.c +++ b/src/lib/libcrypto/x509/by_dir.c @@ -1,4 +1,4 @@ -/* $OpenBSD: by_dir.c,v 1.31 2014/07/10 22:45:58 jsing Exp $ */ +/* $OpenBSD: by_dir.c,v 1.32 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -66,15 +66,14 @@ #include -#include "cryptlib.h" +#include +#include +#include #ifndef OPENSSL_NO_POSIX_IO # include #endif -#include -#include - typedef struct lookup_dir_hashes_st { unsigned long hash; int suffix; diff --git a/src/lib/libcrypto/x509/by_file.c b/src/lib/libcrypto/x509/by_file.c index cf3553181d..10adcfbd77 100644 --- a/src/lib/libcrypto/x509/by_file.c +++ b/src/lib/libcrypto/x509/by_file.c @@ -1,4 +1,4 @@ -/* $OpenBSD: by_file.c,v 1.14 2014/07/10 13:58:23 jsing Exp $ */ +/* $OpenBSD: by_file.c,v 1.15 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -61,12 +61,11 @@ #include #include -#include "cryptlib.h" -#include #include -#include +#include #include - +#include +#include static int by_file_ctrl(X509_LOOKUP *ctx, int cmd, const char *argc, long argl, char **ret); diff --git a/src/lib/libcrypto/x509/x509_att.c b/src/lib/libcrypto/x509/x509_att.c index 241464d999..4ae7504cae 100644 --- a/src/lib/libcrypto/x509/x509_att.c +++ b/src/lib/libcrypto/x509/x509_att.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_att.c,v 1.10 2014/07/03 21:21:11 miod Exp $ */ +/* $OpenBSD: x509_att.c,v 1.11 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,11 +57,12 @@ */ #include -#include -#include "cryptlib.h" + #include -#include +#include #include +#include +#include #include #include diff --git a/src/lib/libcrypto/x509/x509_cmp.c b/src/lib/libcrypto/x509/x509_cmp.c index 20b4ceba27..e26866dc80 100644 --- a/src/lib/libcrypto/x509/x509_cmp.c +++ b/src/lib/libcrypto/x509/x509_cmp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_cmp.c,v 1.21 2014/07/10 22:45:58 jsing Exp $ */ +/* $OpenBSD: x509_cmp.c,v 1.22 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -62,8 +62,8 @@ #include -#include "cryptlib.h" #include +#include #include #include #include diff --git a/src/lib/libcrypto/x509/x509_d2.c b/src/lib/libcrypto/x509/x509_d2.c index 9d42a63f30..cc22f4f470 100644 --- a/src/lib/libcrypto/x509/x509_d2.c +++ b/src/lib/libcrypto/x509/x509_d2.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_d2.c,v 1.8 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_d2.c,v 1.9 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,8 +57,9 @@ */ #include -#include "cryptlib.h" + #include +#include #include int diff --git a/src/lib/libcrypto/x509/x509_ext.c b/src/lib/libcrypto/x509/x509_ext.c index 9d4f1d1122..a5b5430ad4 100644 --- a/src/lib/libcrypto/x509/x509_ext.c +++ b/src/lib/libcrypto/x509/x509_ext.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_ext.c,v 1.7 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_ext.c,v 1.8 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,15 +57,14 @@ */ #include -#include -#include "cryptlib.h" + #include -#include #include +#include +#include #include #include - int X509_CRL_get_ext_count(X509_CRL *x) { diff --git a/src/lib/libcrypto/x509/x509_lu.c b/src/lib/libcrypto/x509/x509_lu.c index 1634ae951d..8d3e4f4dce 100644 --- a/src/lib/libcrypto/x509/x509_lu.c +++ b/src/lib/libcrypto/x509/x509_lu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_lu.c,v 1.15 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_lu.c,v 1.16 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,7 +57,8 @@ */ #include -#include "cryptlib.h" + +#include #include #include #include diff --git a/src/lib/libcrypto/x509/x509_obj.c b/src/lib/libcrypto/x509/x509_obj.c index 88f058d882..f7f2a380a1 100644 --- a/src/lib/libcrypto/x509/x509_obj.c +++ b/src/lib/libcrypto/x509/x509_obj.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_obj.c,v 1.15 2014/07/10 13:58:23 jsing Exp $ */ +/* $OpenBSD: x509_obj.c,v 1.16 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -59,11 +59,11 @@ #include #include -#include "cryptlib.h" +#include +#include #include #include #include -#include char * X509_NAME_oneline(X509_NAME *a, char *buf, int len) diff --git a/src/lib/libcrypto/x509/x509_r2x.c b/src/lib/libcrypto/x509/x509_r2x.c index e87dd11fba..9a9a59d9bb 100644 --- a/src/lib/libcrypto/x509/x509_r2x.c +++ b/src/lib/libcrypto/x509/x509_r2x.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_r2x.c,v 1.8 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_r2x.c,v 1.9 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,13 +57,14 @@ */ #include -#include "cryptlib.h" + +#include #include +#include +#include #include -#include -#include #include -#include +#include X509 * X509_REQ_to_X509(X509_REQ *r, int days, EVP_PKEY *pkey) diff --git a/src/lib/libcrypto/x509/x509_req.c b/src/lib/libcrypto/x509/x509_req.c index d22fc12a70..22d2124614 100644 --- a/src/lib/libcrypto/x509/x509_req.c +++ b/src/lib/libcrypto/x509/x509_req.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_req.c,v 1.14 2014/07/10 22:45:58 jsing Exp $ */ +/* $OpenBSD: x509_req.c,v 1.15 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -60,15 +60,15 @@ #include -#include "cryptlib.h" -#include -#include #include #include -#include -#include +#include #include +#include +#include +#include #include +#include X509_REQ * X509_to_X509_REQ(X509 *x, EVP_PKEY *pkey, const EVP_MD *md) diff --git a/src/lib/libcrypto/x509/x509_set.c b/src/lib/libcrypto/x509/x509_set.c index 523c6621b1..3be557cbc0 100644 --- a/src/lib/libcrypto/x509/x509_set.c +++ b/src/lib/libcrypto/x509/x509_set.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_set.c,v 1.8 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_set.c,v 1.9 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,10 +57,10 @@ */ #include -#include "cryptlib.h" + #include -#include #include +#include #include int diff --git a/src/lib/libcrypto/x509/x509_trs.c b/src/lib/libcrypto/x509/x509_trs.c index b8e01603c5..f104c1fd16 100644 --- a/src/lib/libcrypto/x509/x509_trs.c +++ b/src/lib/libcrypto/x509/x509_trs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_trs.c,v 1.14 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_trs.c,v 1.15 2014/07/11 08:44:49 jsing Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 1999. */ @@ -57,9 +57,9 @@ */ #include -#include "cryptlib.h" -#include +#include +#include static int tr_cmp(const X509_TRUST * const *a, const X509_TRUST * const *b); static void trtable_free(X509_TRUST *p); diff --git a/src/lib/libcrypto/x509/x509_txt.c b/src/lib/libcrypto/x509/x509_txt.c index b1b3f3e58d..14fa2378c4 100644 --- a/src/lib/libcrypto/x509/x509_txt.c +++ b/src/lib/libcrypto/x509/x509_txt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_txt.c,v 1.18 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_txt.c,v 1.19 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -56,17 +56,16 @@ * [including the GNU Public Licence.] */ +#include #include #include -#include -#include "cryptlib.h" -#include +#include #include #include -#include -#include +#include #include +#include const char * X509_verify_cert_error_string(long n) diff --git a/src/lib/libcrypto/x509/x509_v3.c b/src/lib/libcrypto/x509/x509_v3.c index 7425782ebf..a745e6f71b 100644 --- a/src/lib/libcrypto/x509/x509_v3.c +++ b/src/lib/libcrypto/x509/x509_v3.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_v3.c,v 1.9 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509_v3.c,v 1.10 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,11 +57,12 @@ */ #include -#include -#include "cryptlib.h" + #include -#include +#include #include +#include +#include #include #include diff --git a/src/lib/libcrypto/x509/x509_vfy.c b/src/lib/libcrypto/x509/x509_vfy.c index 60067d220f..f7feb85f36 100644 --- a/src/lib/libcrypto/x509/x509_vfy.c +++ b/src/lib/libcrypto/x509/x509_vfy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_vfy.c,v 1.32 2014/07/10 22:45:58 jsing Exp $ */ +/* $OpenBSD: x509_vfy.c,v 1.33 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -64,15 +64,15 @@ #include -#include "cryptlib.h" -#include -#include +#include #include +#include +#include #include -#include +#include +#include #include #include -#include /* CRL score values */ diff --git a/src/lib/libcrypto/x509/x509_vpm.c b/src/lib/libcrypto/x509/x509_vpm.c index 3730d593cd..ec35267298 100644 --- a/src/lib/libcrypto/x509/x509_vpm.c +++ b/src/lib/libcrypto/x509/x509_vpm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509_vpm.c,v 1.8 2014/07/10 13:58:23 jsing Exp $ */ +/* $OpenBSD: x509_vpm.c,v 1.9 2014/07/11 08:44:49 jsing Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2004. */ @@ -59,10 +59,9 @@ #include #include -#include "cryptlib.h" +#include #include #include -#include #include #include diff --git a/src/lib/libcrypto/x509/x509cset.c b/src/lib/libcrypto/x509/x509cset.c index 8ef19c2a40..a4442632f6 100644 --- a/src/lib/libcrypto/x509/x509cset.c +++ b/src/lib/libcrypto/x509/x509cset.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509cset.c,v 1.7 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509cset.c,v 1.8 2014/07/11 08:44:49 jsing Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2001. */ @@ -57,10 +57,10 @@ */ #include -#include "cryptlib.h" + #include -#include #include +#include #include int diff --git a/src/lib/libcrypto/x509/x509name.c b/src/lib/libcrypto/x509/x509name.c index 4151ea0bc5..465a1cadb5 100644 --- a/src/lib/libcrypto/x509/x509name.c +++ b/src/lib/libcrypto/x509/x509name.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509name.c,v 1.11 2014/07/10 13:58:23 jsing Exp $ */ +/* $OpenBSD: x509name.c,v 1.12 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -59,11 +59,11 @@ #include #include -#include -#include "cryptlib.h" #include -#include +#include #include +#include +#include #include int diff --git a/src/lib/libcrypto/x509/x509rset.c b/src/lib/libcrypto/x509/x509rset.c index 509f38b111..cfac977636 100644 --- a/src/lib/libcrypto/x509/x509rset.c +++ b/src/lib/libcrypto/x509/x509rset.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509rset.c,v 1.5 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509rset.c,v 1.6 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,10 +57,10 @@ */ #include -#include "cryptlib.h" + #include -#include #include +#include #include int diff --git a/src/lib/libcrypto/x509/x509spki.c b/src/lib/libcrypto/x509/x509spki.c index 28e499b9b2..cd29a8138a 100644 --- a/src/lib/libcrypto/x509/x509spki.c +++ b/src/lib/libcrypto/x509/x509spki.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509spki.c,v 1.11 2014/07/10 13:58:23 jsing Exp $ */ +/* $OpenBSD: x509spki.c,v 1.12 2014/07/11 08:44:49 jsing Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 1999. */ @@ -59,7 +59,7 @@ #include #include -#include "cryptlib.h" +#include #include int diff --git a/src/lib/libcrypto/x509/x509type.c b/src/lib/libcrypto/x509/x509type.c index 29f38e2a9a..58335b4e64 100644 --- a/src/lib/libcrypto/x509/x509type.c +++ b/src/lib/libcrypto/x509/x509type.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x509type.c,v 1.10 2014/06/12 15:49:31 deraadt Exp $ */ +/* $OpenBSD: x509type.c,v 1.11 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -57,7 +57,7 @@ */ #include -#include "cryptlib.h" + #include #include #include diff --git a/src/lib/libcrypto/x509/x_all.c b/src/lib/libcrypto/x509/x_all.c index f01e47416d..edb5f520fa 100644 --- a/src/lib/libcrypto/x509/x_all.c +++ b/src/lib/libcrypto/x509/x_all.c @@ -1,4 +1,4 @@ -/* $OpenBSD: x_all.c,v 1.17 2014/07/10 22:45:58 jsing Exp $ */ +/* $OpenBSD: x_all.c,v 1.18 2014/07/11 08:44:49 jsing Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -60,18 +60,18 @@ #include -#include -#include "cryptlib.h" -#include #include +#include #include +#include #include -#ifndef OPENSSL_NO_RSA -#include -#endif + #ifndef OPENSSL_NO_DSA #include #endif +#ifndef OPENSSL_NO_RSA +#include +#endif int X509_verify(X509 *a, EVP_PKEY *r) -- cgit v1.2.3-55-g6feb