summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2008-11-03 19:16:20 +1100
committerDamien Miller <djm@mindrot.org>2008-11-03 19:16:20 +1100
commitc6aadd994d0ed79f5606b7061d576d514fd71cd7 (patch)
tree1f93e35a62b89fd8edd984327d1008d0abfa1ba2
parent9f6fb56ab83da2e795e4a8eb863992701fd83516 (diff)
- grunk@cvs.openbsd.org 2008/07/25 07:05:16
[key.c] In random art visualization, make sure to use the end marker only at the end. Initial diff by Dirk Loss, tweaks and ok djm@
-rw-r--r--ChangeLog6
-rw-r--r--key.c5
2 files changed, 8 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index c95a93c6..52149d21 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,6 +7,10 @@
- grunk@cvs.openbsd.org 2008/07/25 06:56:35
[ssh_config]
Add VisualHostKey to example file, ok djm@
+ - grunk@cvs.openbsd.org 2008/07/25 07:05:16
+ [key.c]
+ In random art visualization, make sure to use the end marker only at the
+ end. Initial diff by Dirk Loss, tweaks and ok djm@
20080906
- (dtucker) [config.guess config.sub] Update to latest versions from
@@ -4741,4 +4745,4 @@
OpenServer 6 and add osr5bigcrypt support so when someone migrates
passwords between UnixWare and OpenServer they will still work. OK dtucker@
-$Id: ChangeLog,v 1.5100 2008/11/03 08:15:44 djm Exp $
+$Id: ChangeLog,v 1.5101 2008/11/03 08:16:20 djm Exp $
diff --git a/key.c b/key.c
index 2ea13d27..76d6af92 100644
--- a/key.c
+++ b/key.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: key.c,v 1.78 2008/07/07 23:32:51 stevesk Exp $ */
+/* $OpenBSD: key.c,v 1.79 2008/07/25 07:05:16 grunk Exp $ */
/*
* read_bignum():
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -369,7 +369,8 @@ key_fingerprint_randomart(u_char *dgst_raw, u_int dgst_raw_len, const Key *k)
y = MIN(y, FLDSIZE_Y - 1);
/* augment the field */
- field[x][y]++;
+ if (field[x][y] < len - 2)
+ field[x][y]++;
input = input >> 2;
}
}