=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/ssh-keysign.c,v retrieving revision 1.18.6.1 retrieving revision 1.18.6.2 diff -u -r1.18.6.1 -r1.18.6.2 --- src/usr.bin/ssh/ssh-keysign.c 2006/02/03 03:01:57 1.18.6.1 +++ src/usr.bin/ssh/ssh-keysign.c 2006/10/06 03:19:33 1.18.6.2 @@ -1,3 +1,4 @@ +/* $OpenBSD: ssh-keysign.c,v 1.18.6.2 2006/10/06 03:19:33 brad Exp $ */ /* * Copyright (c) 2002 Markus Friedl. All rights reserved. * @@ -21,21 +22,27 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -#include "includes.h" -RCSID("$OpenBSD: ssh-keysign.c,v 1.18.6.1 2006/02/03 03:01:57 brad Exp $"); +#include + #include #include #include +#include +#include +#include +#include +#include +#include + +#include "xmalloc.h" #include "log.h" #include "key.h" #include "ssh.h" #include "ssh2.h" #include "misc.h" -#include "xmalloc.h" #include "buffer.h" -#include "bufaux.h" #include "authfile.h" #include "msg.h" #include "canohost.h" @@ -62,9 +69,9 @@ buffer_init(&b); buffer_append(&b, data, datalen); - /* session id, currently limited to SHA1 (20 bytes) */ + /* session id, currently limited to SHA1 (20 bytes) or SHA256 (32) */ p = buffer_get_string(&b, &len); - if (len != 20) + if (len != 20 && len != 32) fail++; xfree(p);