diff options
Diffstat (limited to 'src/lib/libcrypto/conf/conf_api.c')
-rw-r--r-- | src/lib/libcrypto/conf/conf_api.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/src/lib/libcrypto/conf/conf_api.c b/src/lib/libcrypto/conf/conf_api.c index efa4be9f6b..f296e6a962 100644 --- a/src/lib/libcrypto/conf/conf_api.c +++ b/src/lib/libcrypto/conf/conf_api.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: conf_api.c,v 1.14 2015/02/10 11:22:21 jsing Exp $ */ | 1 | /* $OpenBSD: conf_api.c,v 1.15 2015/04/11 16:03:21 deraadt Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -130,7 +130,6 @@ char * | |||
130 | _CONF_get_string(const CONF *conf, const char *section, const char *name) | 130 | _CONF_get_string(const CONF *conf, const char *section, const char *name) |
131 | { | 131 | { |
132 | CONF_VALUE *v, vv; | 132 | CONF_VALUE *v, vv; |
133 | char *p; | ||
134 | 133 | ||
135 | if (name == NULL) | 134 | if (name == NULL) |
136 | return (NULL); | 135 | return (NULL); |
@@ -141,14 +140,6 @@ _CONF_get_string(const CONF *conf, const char *section, const char *name) | |||
141 | v = lh_CONF_VALUE_retrieve(conf->data, &vv); | 140 | v = lh_CONF_VALUE_retrieve(conf->data, &vv); |
142 | if (v != NULL) | 141 | if (v != NULL) |
143 | return (v->value); | 142 | return (v->value); |
144 | if (strcmp(section, "ENV") == 0) { | ||
145 | if (issetugid() == 0) | ||
146 | p = getenv(name); | ||
147 | else | ||
148 | p = NULL; | ||
149 | if (p != NULL) | ||
150 | return (p); | ||
151 | } | ||
152 | } | 143 | } |
153 | vv.section = "default"; | 144 | vv.section = "default"; |
154 | vv.name = (char *)name; | 145 | vv.name = (char *)name; |
@@ -157,11 +148,8 @@ _CONF_get_string(const CONF *conf, const char *section, const char *name) | |||
157 | return (v->value); | 148 | return (v->value); |
158 | else | 149 | else |
159 | return (NULL); | 150 | return (NULL); |
160 | } else { | 151 | } else |
161 | if (issetugid()) | 152 | return (NULL); |
162 | return (NULL); | ||
163 | return (getenv(name)); | ||
164 | } | ||
165 | } | 153 | } |
166 | 154 | ||
167 | static unsigned long | 155 | static unsigned long |