diff options
author | 1996-08-18 19:07:26 +0000 | |
---|---|---|
committer | 1996-08-18 19:07:26 +0000 | |
commit | 1c456d6ca4e74ad7184134fc096b3c2fae821aa7 (patch) | |
tree | f617a285f1abb482613ee06532cae57116968be7 /lib/libc/net/res_query.c | |
parent | termcap path; explorer@netbsd.org (diff) | |
download | wireguard-openbsd-1c456d6ca4e74ad7184134fc096b3c2fae821aa7.tar.xz wireguard-openbsd-1c456d6ca4e74ad7184134fc096b3c2fae821aa7.zip |
if setuid, no env variables
Diffstat (limited to 'lib/libc/net/res_query.c')
-rw-r--r-- | lib/libc/net/res_query.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/libc/net/res_query.c b/lib/libc/net/res_query.c index 81c4d3194d3..61b6cb35c9b 100644 --- a/lib/libc/net/res_query.c +++ b/lib/libc/net/res_query.c @@ -368,6 +368,8 @@ __hostalias(name) if (_res.options & RES_NOALIASES) return (NULL); + if (getuid() != setuid()) + return (NULL); file = getenv("HOSTALIASES"); if (file == NULL || (fp = fopen(file, "r")) == NULL) return (NULL); |