[Bug 2127] New: incorrectness of do_print_resource_record()
bugzilla-daemon at mindrot.org
bugzilla-daemon at mindrot.org
Wed Jul 10 08:40:00 EST 2013
https://bugzilla.mindrot.org/show_bug.cgi?id=2127
Bug ID: 2127
Summary: incorrectness of do_print_resource_record()
Product: Portable OpenSSH
Version: 6.2p1
Hardware: All
OS: FreeBSD
Status: NEW
Severity: minor
Priority: P5
Component: ssh-keygen
Assignee: unassigned-bugs at mindrot.org
Reporter: arthurmesh at gmail.com
Line 1304 seems incorrect. Call to ask_filename() doesn't modify fname,
and
hence is of no use.
1293 /*
1294 * Print the SSHFP RR.
1295 */
1296 static int
1297 do_print_resource_record(struct passwd *pw, char *fname, char
*hname)
1298 {
1299 Key *public;
1300 char *comment = NULL;
1301 struct stat st;
1302
1303 if (fname == NULL)
1304 ask_filename(pw, "Enter file in which the key
is");
1305 if (stat(fname, &st) < 0) {
1306 if (errno == ENOENT)
1307 return 0;
1308 perror(fname);
1309 exit(1);
1310 }
1311 public = key_load_public(fname, &comment);
1312 if (public != NULL) {
1313 export_dns_rr(hname, public, stdout,
print_generic);
1314 key_free(public);
1315 xfree(comment);
1316 return 1;
1317 }
1318 if (comment)
1319 xfree(comment);
1320
1321 printf("failed to read v2 public key from %s.\n", fname);
1322 exit(1);
1323 }
--
You are receiving this mail because:
You are watching the assignee of the bug.
More information about the openssh-bugs
mailing list