=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/packet.c,v retrieving revision 1.174 retrieving revision 1.175 diff -u -r1.174 -r1.175 --- src/usr.bin/ssh/packet.c 2011/12/07 05:44:38 1.174 +++ src/usr.bin/ssh/packet.c 2012/01/25 19:26:43 1.175 @@ -1,4 +1,4 @@ -/* $OpenBSD: packet.c,v 1.174 2011/12/07 05:44:38 djm Exp $ */ +/* $OpenBSD: packet.c,v 1.175 2012/01/25 19:26:43 markus Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -959,8 +959,10 @@ /* during rekeying we can only send key exchange messages */ if (active_state->rekeying) { - if (!((type >= SSH2_MSG_TRANSPORT_MIN) && - (type <= SSH2_MSG_TRANSPORT_MAX))) { + if ((type < SSH2_MSG_TRANSPORT_MIN) || + (type > SSH2_MSG_TRANSPORT_MAX) || + (type == SSH2_MSG_SERVICE_REQUEST) || + (type == SSH2_MSG_SERVICE_ACCEPT)) { debug("enqueue packet: %u", type); p = xmalloc(sizeof(*p)); p->type = type;