summaryrefslogtreecommitdiffstats
path: root/proxy/src/mechglue/gss_plugin.c
diff options
context:
space:
mode:
authorSimo Sorce <simo@redhat.com>2013-11-20 11:58:22 -0500
committerSimo Sorce <simo@redhat.com>2013-11-20 12:03:29 -0500
commit30ce3354ed3300721ddf8de069b0647b55e718e6 (patch)
treeaecdfbc9cec2f04f10fc2a96c129595bc1b8f68b /proxy/src/mechglue/gss_plugin.c
parent9824bec3a9fc14a527a4febd60a730f6deee0918 (diff)
downloadgss-proxy-getenv.tar.gz
gss-proxy-getenv.tar.xz
gss-proxy-getenv.zip
Use secure_getenv in client and mechglue modulegetenv
proxymehc.so may be used in setuid binaries so follow best security practices and use secure_getenv() if available. Fallback to poorman emulation when secure_getenv() is not available. Resolves: https://fedorahosted.org/gss-proxy/ticket/110
Diffstat (limited to 'proxy/src/mechglue/gss_plugin.c')
-rw-r--r--proxy/src/mechglue/gss_plugin.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/proxy/src/mechglue/gss_plugin.c b/proxy/src/mechglue/gss_plugin.c
index 0e62990..9a06d10 100644
--- a/proxy/src/mechglue/gss_plugin.c
+++ b/proxy/src/mechglue/gss_plugin.c
@@ -64,7 +64,7 @@ enum gpp_behavior gpp_get_behavior(void)
char *envval;
if (behavior == GPP_UNINITIALIZED) {
- envval = getenv("GSSPROXY_BEHAVIOR");
+ envval = gp_getenv("GSSPROXY_BEHAVIOR");
if (envval) {
if (strcmp(envval, "LOCAL_ONLY") == 0) {
behavior = GPP_LOCAL_ONLY;
@@ -102,7 +102,7 @@ gss_OID_set gss_mech_interposer(gss_OID mech_type)
/* avoid looping in the gssproxy daemon by avoiding to interpose
* any mechanism */
- envval = getenv("GSS_USE_PROXY");
+ envval = gp_getenv("GSS_USE_PROXY");
if (!envval) {
return NULL;
}