=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/hostfile.c,v retrieving revision 1.83 retrieving revision 1.84 diff -u -r1.83 -r1.84 --- src/usr.bin/ssh/hostfile.c 2020/10/04 09:45:01 1.83 +++ src/usr.bin/ssh/hostfile.c 2020/10/07 02:25:43 1.84 @@ -1,4 +1,4 @@ -/* $OpenBSD: hostfile.c,v 1.83 2020/10/04 09:45:01 djm Exp $ */ +/* $OpenBSD: hostfile.c,v 1.84 2020/10/07 02:25:43 djm Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -449,6 +449,9 @@ else error("%s: sshkey_write failed: %s", __func__, ssh_err(r)); fputc('\n', f); + /* If hashing is enabled, the IP address needs to go on its own line */ + if (success && store_hash && ip != NULL) + success = write_host_entry(f, ip, NULL, key, 1); return success; }