Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
openssl,openssl-bootstrap: keep only 1.0.2d; fix CA bundle
Use 1.0.2d even for SLC6. In newer glibc versions __secure_getenv was renamed to secure_getenv, thus we just rename it back on SLC6. Include a fix for PR3979. Set /etc/pki/tls as openssldir, but make sure that installation step does not touch the directory. This solves the problem where das_client.py was not able to verify cmsweb certificate. (cherry picked from commit 535fb83, but openssl-bootstrap.spec was kept unmodified) Signed-off-by: David Abdurachmanov <David.Abdurachmanov@cern.ch>
- Loading branch information
David Abdurachmanov
authored and
David Abdurachmanov
committed
Feb 2, 2016
1 parent
006009d
commit 6ee6370
Showing
3 changed files
with
99 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
diff --git a/apps/Makefile b/apps/Makefile | ||
index cafe554..547fc41 100644 | ||
--- a/apps/Makefile | ||
+++ b/apps/Makefile | ||
@@ -109,16 +109,6 @@ install: | ||
chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new; \ | ||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i ); \ | ||
done; | ||
- @set -e; for i in $(SCRIPTS); \ | ||
- do \ | ||
- (echo installing $$i; \ | ||
- cp $$i $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new; \ | ||
- chmod 755 $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new; \ | ||
- mv -f $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i ); \ | ||
- done | ||
- @cp openssl.cnf $(INSTALL_PREFIX)$(OPENSSLDIR)/openssl.cnf.new; \ | ||
- chmod 644 $(INSTALL_PREFIX)$(OPENSSLDIR)/openssl.cnf.new; \ | ||
- mv -f $(INSTALL_PREFIX)$(OPENSSLDIR)/openssl.cnf.new $(INSTALL_PREFIX)$(OPENSSLDIR)/openssl.cnf | ||
|
||
tags: | ||
ctags $(SRC) | ||
diff --git a/tools/Makefile b/tools/Makefile | ||
index c1a2f6b..6e7c104 100644 | ||
--- a/tools/Makefile | ||
+++ b/tools/Makefile | ||
@@ -26,12 +26,6 @@ install: | ||
chmod 755 $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new; \ | ||
mv -f $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i.new $(INSTALL_PREFIX)$(INSTALLTOP)/bin/$$i ); \ | ||
done; | ||
- @for i in $(MISC_APPS) ; \ | ||
- do \ | ||
- (cp $$i $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new; \ | ||
- chmod 755 $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new; \ | ||
- mv -f $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i.new $(INSTALL_PREFIX)$(OPENSSLDIR)/misc/$$i ); \ | ||
- done; | ||
|
||
files: | ||
$(PERL) $(TOP)/util/files.pl Makefile >> $(TOP)/MINFO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
diff --git a/crypto/x509v3/v3_purp.c b/crypto/x509v3/v3_purp.c | ||
index 36b0d87..845be67 100644 | ||
--- a/crypto/x509v3/v3_purp.c | ||
+++ b/crypto/x509v3/v3_purp.c | ||
@@ -380,6 +380,14 @@ static void setup_crldp(X509 *x) | ||
setup_dp(x, sk_DIST_POINT_value(x->crldp, i)); | ||
} | ||
|
||
+#define V1_ROOT (EXFLAG_V1|EXFLAG_SS) | ||
+#define ku_reject(x, usage) \ | ||
+ (((x)->ex_flags & EXFLAG_KUSAGE) && !((x)->ex_kusage & (usage))) | ||
+#define xku_reject(x, usage) \ | ||
+ (((x)->ex_flags & EXFLAG_XKUSAGE) && !((x)->ex_xkusage & (usage))) | ||
+#define ns_reject(x, usage) \ | ||
+ (((x)->ex_flags & EXFLAG_NSCERT) && !((x)->ex_nscert & (usage))) | ||
+ | ||
static void x509v3_cache_extensions(X509 *x) | ||
{ | ||
BASIC_CONSTRAINTS *bs; | ||
@@ -499,7 +507,8 @@ static void x509v3_cache_extensions(X509 *x) | ||
if (!X509_NAME_cmp(X509_get_subject_name(x), X509_get_issuer_name(x))) { | ||
x->ex_flags |= EXFLAG_SI; | ||
/* If SKID matches AKID also indicate self signed */ | ||
- if (X509_check_akid(x, x->akid) == X509_V_OK) | ||
+ if (X509_check_akid(x, x->akid) == X509_V_OK && | ||
+ !ku_reject(x, KU_KEY_CERT_SIGN)) | ||
x->ex_flags |= EXFLAG_SS; | ||
} | ||
x->altname = X509_get_ext_d2i(x, NID_subject_alt_name, NULL, NULL); | ||
@@ -538,14 +547,6 @@ static void x509v3_cache_extensions(X509 *x) | ||
* 4 basicConstraints absent but keyUsage present and keyCertSign asserted. | ||
*/ | ||
|
||
-#define V1_ROOT (EXFLAG_V1|EXFLAG_SS) | ||
-#define ku_reject(x, usage) \ | ||
- (((x)->ex_flags & EXFLAG_KUSAGE) && !((x)->ex_kusage & (usage))) | ||
-#define xku_reject(x, usage) \ | ||
- (((x)->ex_flags & EXFLAG_XKUSAGE) && !((x)->ex_xkusage & (usage))) | ||
-#define ns_reject(x, usage) \ | ||
- (((x)->ex_flags & EXFLAG_NSCERT) && !((x)->ex_nscert & (usage))) | ||
- | ||
static int check_ca(const X509 *x) | ||
{ | ||
/* keyUsage if present should allow cert signing */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters