diff options
author | Colin Watson <cjwatson@debian.org> | 2005-05-25 11:01:01 +0000 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2005-05-25 11:01:01 +0000 |
commit | e88de75a1a236779a10e8ccbcc51d25308be8840 (patch) | |
tree | 7495477a2a7d0cac17a9fcded020b6ea816182ef /ssh-keysign.c | |
parent | 30a0f9443782cd9d7308acd09430bf586186aa55 (diff) | |
parent | 5d05471f6657646d1d6500c7c43134462c407ee6 (diff) |
Merge 4.0p1 to the trunk.
Diffstat (limited to 'ssh-keysign.c')
-rw-r--r-- | ssh-keysign.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ssh-keysign.c b/ssh-keysign.c index 517655790..04597a91d 100644 --- a/ssh-keysign.c +++ b/ssh-keysign.c | |||
@@ -22,7 +22,7 @@ | |||
22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
23 | */ | 23 | */ |
24 | #include "includes.h" | 24 | #include "includes.h" |
25 | RCSID("$OpenBSD: ssh-keysign.c,v 1.16 2004/04/18 23:10:26 djm Exp $"); | 25 | RCSID("$OpenBSD: ssh-keysign.c,v 1.18 2004/08/23 14:29:23 dtucker Exp $"); |
26 | 26 | ||
27 | #include <openssl/evp.h> | 27 | #include <openssl/evp.h> |
28 | #include <openssl/rand.h> | 28 | #include <openssl/rand.h> |
@@ -151,7 +151,8 @@ main(int argc, char **argv) | |||
151 | key_fd[0] = open(_PATH_HOST_RSA_KEY_FILE, O_RDONLY); | 151 | key_fd[0] = open(_PATH_HOST_RSA_KEY_FILE, O_RDONLY); |
152 | key_fd[1] = open(_PATH_HOST_DSA_KEY_FILE, O_RDONLY); | 152 | key_fd[1] = open(_PATH_HOST_DSA_KEY_FILE, O_RDONLY); |
153 | 153 | ||
154 | if ((pw = getpwuid(getuid())) == NULL) | 154 | original_real_uid = getuid(); /* XXX readconf.c needs this */ |
155 | if ((pw = getpwuid(original_real_uid)) == NULL) | ||
155 | fatal("getpwuid failed"); | 156 | fatal("getpwuid failed"); |
156 | pw = pwcopy(pw); | 157 | pw = pwcopy(pw); |
157 | 158 | ||
@@ -166,7 +167,6 @@ main(int argc, char **argv) | |||
166 | #endif | 167 | #endif |
167 | 168 | ||
168 | /* verify that ssh-keysign is enabled by the admin */ | 169 | /* verify that ssh-keysign is enabled by the admin */ |
169 | original_real_uid = getuid(); /* XXX readconf.c needs this */ | ||
170 | initialize_options(&options); | 170 | initialize_options(&options); |
171 | (void)read_config_file(_PATH_HOST_CONFIG_FILE, "", &options, 0); | 171 | (void)read_config_file(_PATH_HOST_CONFIG_FILE, "", &options, 0); |
172 | fill_default_options(&options); | 172 | fill_default_options(&options); |