diff options
author | Damien Miller <djm@mindrot.org> | 2001-12-21 14:45:46 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2001-12-21 14:45:46 +1100 |
commit | 9f0f5c64bc4b6144e3fed6a7f538f7c21819a492 (patch) | |
tree | f79317ab211f59181a61b526f566e9c8cfe70c73 /ssh-add.c | |
parent | 89681214ca2f50a1b1ed6164c3afe1ce14995ffc (diff) |
- deraadt@cvs.openbsd.org 2001/12/19 07:18:56
[auth1.c auth2.c auth2-chall.c auth-bsdauth.c auth.c authfile.c auth.h]
[auth-krb4.c auth-rhosts.c auth-skey.c bufaux.c canohost.c channels.c]
[cipher.c clientloop.c compat.c compress.c deattack.c key.c log.c mac.c]
[match.c misc.c nchan.c packet.c readconf.c rijndael.c rijndael.h scard.c]
[servconf.c servconf.h serverloop.c session.c sftp.c sftp-client.c]
[sftp-glob.c sftp-int.c sftp-server.c ssh-add.c ssh-agent.c ssh.c]
[sshconnect1.c sshconnect2.c sshconnect.c sshd.8 sshd.c sshd_config]
[ssh-keygen.c sshlogin.c sshpty.c sshtty.c ttymodes.c uidswap.c]
basic KNF done while i was looking for something else
Diffstat (limited to 'ssh-add.c')
-rw-r--r-- | ssh-add.c | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -35,7 +35,7 @@ | |||
35 | */ | 35 | */ |
36 | 36 | ||
37 | #include "includes.h" | 37 | #include "includes.h" |
38 | RCSID("$OpenBSD: ssh-add.c,v 1.46 2001/10/02 08:38:50 djm Exp $"); | 38 | RCSID("$OpenBSD: ssh-add.c,v 1.47 2001/12/19 07:18:56 deraadt Exp $"); |
39 | 39 | ||
40 | #include <openssl/evp.h> | 40 | #include <openssl/evp.h> |
41 | 41 | ||
@@ -90,7 +90,7 @@ delete_file(AuthenticationConnection *ac, const char *filename) | |||
90 | 90 | ||
91 | key_free(public); | 91 | key_free(public); |
92 | xfree(comment); | 92 | xfree(comment); |
93 | 93 | ||
94 | return ret; | 94 | return ret; |
95 | } | 95 | } |
96 | 96 | ||
@@ -160,7 +160,7 @@ add_file(AuthenticationConnection *ac, const char *filename) | |||
160 | 160 | ||
161 | xfree(comment); | 161 | xfree(comment); |
162 | key_free(private); | 162 | key_free(private); |
163 | 163 | ||
164 | return ret; | 164 | return ret; |
165 | } | 165 | } |
166 | 166 | ||
@@ -169,11 +169,11 @@ update_card(AuthenticationConnection *ac, int add, const char *id) | |||
169 | { | 169 | { |
170 | if (ssh_update_card(ac, add, id)) { | 170 | if (ssh_update_card(ac, add, id)) { |
171 | fprintf(stderr, "Card %s: %s\n", | 171 | fprintf(stderr, "Card %s: %s\n", |
172 | add ? "added" : "removed", id); | 172 | add ? "added" : "removed", id); |
173 | return 0; | 173 | return 0; |
174 | } else { | 174 | } else { |
175 | fprintf(stderr, "Could not %s card: %s\n", | 175 | fprintf(stderr, "Could not %s card: %s\n", |
176 | add ? "add" : "remove", id); | 176 | add ? "add" : "remove", id); |
177 | return -1; | 177 | return -1; |
178 | } | 178 | } |
179 | } | 179 | } |
@@ -188,8 +188,8 @@ list_identities(AuthenticationConnection *ac, int do_fp) | |||
188 | 188 | ||
189 | for (version = 1; version <= 2; version++) { | 189 | for (version = 1; version <= 2; version++) { |
190 | for (key = ssh_get_first_identity(ac, &comment, version); | 190 | for (key = ssh_get_first_identity(ac, &comment, version); |
191 | key != NULL; | 191 | key != NULL; |
192 | key = ssh_get_next_identity(ac, &comment, version)) { | 192 | key = ssh_get_next_identity(ac, &comment, version)) { |
193 | had_identities = 1; | 193 | had_identities = 1; |
194 | if (do_fp) { | 194 | if (do_fp) { |
195 | fp = key_fingerprint(key, SSH_FP_MD5, | 195 | fp = key_fingerprint(key, SSH_FP_MD5, |
@@ -248,7 +248,7 @@ main(int argc, char **argv) | |||
248 | fprintf(stderr, "Could not open a connection to your authentication agent.\n"); | 248 | fprintf(stderr, "Could not open a connection to your authentication agent.\n"); |
249 | exit(1); | 249 | exit(1); |
250 | } | 250 | } |
251 | while ((ch = getopt(argc, argv, "lLdDe:s:")) != -1) { | 251 | while ((ch = getopt(argc, argv, "lLdDe:s:")) != -1) { |
252 | switch (ch) { | 252 | switch (ch) { |
253 | case 'l': | 253 | case 'l': |
254 | case 'L': | 254 | case 'L': |
@@ -267,7 +267,7 @@ main(int argc, char **argv) | |||
267 | sc_reader_id = optarg; | 267 | sc_reader_id = optarg; |
268 | break; | 268 | break; |
269 | case 'e': | 269 | case 'e': |
270 | deleting = 1; | 270 | deleting = 1; |
271 | sc_reader_id = optarg; | 271 | sc_reader_id = optarg; |
272 | break; | 272 | break; |
273 | default: | 273 | default: |