]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream commit
authordjm@openbsd.org <djm@openbsd.org>
Mon, 1 May 2017 00:03:18 +0000 (00:03 +0000)
committerDamien Miller <djm@mindrot.org>
Mon, 1 May 2017 00:06:24 +0000 (10:06 +1000)
fixup setting ciphercontext->plaintext (lost in SSHv1 purge),
though it isn't really used for much anymore.

Upstream-ID: 859b8bce84ff4865b32097db5430349d04b9b747

cipher.c

index 622e745d01c71b3cfc6831ad9813656de26d32ba..7d72084ff5c954d2a935ad2a0665e951b2691c1b 100644 (file)
--- a/cipher.c
+++ b/cipher.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cipher.c,v 1.104 2017/04/30 23:15:04 djm Exp $ */
+/* $OpenBSD: cipher.c,v 1.105 2017/05/01 00:03:18 djm Exp $ */
 /*
  * Author: Tatu Ylonen <ylo@cs.hut.fi>
  * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -259,7 +259,7 @@ cipher_init(struct sshcipher_ctx **ccp, const struct sshcipher *cipher,
        if ((cc = calloc(sizeof(*cc), 1)) == NULL)
                return SSH_ERR_ALLOC_FAIL;
 
-       cc->plaintext = 0; /* XXX */
+       cc->plaintext = (cipher->flags & CFLAG_NONE) != 0;
        cc->encrypt = do_encrypt;
 
        if (keylen < cipher->key_len ||