diff options
author | Damien Miller <djm@mindrot.org> | 2006-06-13 13:05:15 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2006-06-13 13:05:15 +1000 |
commit | 6b4069ad563ce578cbfa6f90e76b462d26483e67 (patch) | |
tree | 777206b388f2ef12b83275d4aeb78e96cdea1bdd /sshconnect.c | |
parent | eb13e556e58a52a3ff0c734a8690ad41686cf92c (diff) |
- markus@cvs.openbsd.org 2006/06/06 10:20:20
[readpass.c sshconnect.c sshconnect.h sshconnect2.c uidswap.c]
replace remaining setuid() calls with permanently_set_uid() and
check seteuid() return values; report Marcus Meissner; ok dtucker djm
Diffstat (limited to 'sshconnect.c')
-rw-r--r-- | sshconnect.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sshconnect.c b/sshconnect.c index e855f1926..41ad82f9f 100644 --- a/sshconnect.c +++ b/sshconnect.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: sshconnect.c,v 1.182 2006/05/17 12:43:34 markus Exp $ */ | 1 | /* $OpenBSD: sshconnect.c,v 1.183 2006/06/06 10:20:20 markus Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -97,8 +97,7 @@ ssh_proxy_connect(const char *host, u_short port, const char *proxy_command) | |||
97 | char *argv[10]; | 97 | char *argv[10]; |
98 | 98 | ||
99 | /* Child. Permanently give up superuser privileges. */ | 99 | /* Child. Permanently give up superuser privileges. */ |
100 | seteuid(original_real_uid); | 100 | permanently_set_uid(getpwuid(original_real_uid)); |
101 | setuid(original_real_uid); | ||
102 | 101 | ||
103 | /* Redirect stdin and stdout. */ | 102 | /* Redirect stdin and stdout. */ |
104 | close(pin[1]); | 103 | close(pin[1]); |