diff options
author | Damien Miller <djm@mindrot.org> | 2014-04-20 13:00:28 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2014-04-20 13:00:28 +1000 |
commit | 3819519288b2b3928c6882f5883b0f55148f4fc0 (patch) | |
tree | b160c5e1c97cbcb0ef86ad853aedcdf5276186ad | |
parent | 8f9cd709c7cf0655d414306a0ed28306b33802be (diff) |
- djm@cvs.openbsd.org 2014/03/12 04:51:12
[authfile.c]
correct test that kdf name is not "none" or "bcrypt"
-rw-r--r-- | ChangeLog | 3 | ||||
-rw-r--r-- | authfile.c | 4 |
2 files changed, 5 insertions, 2 deletions
@@ -12,6 +12,9 @@ | |||
12 | [auth-bsdauth.c ssh-keygen.c] | 12 | [auth-bsdauth.c ssh-keygen.c] |
13 | don't count on things that accept arguments by reference to clear | 13 | don't count on things that accept arguments by reference to clear |
14 | things for us on error; most things do, but it's unsafe form. | 14 | things for us on error; most things do, but it's unsafe form. |
15 | - djm@cvs.openbsd.org 2014/03/12 04:51:12 | ||
16 | [authfile.c] | ||
17 | correct test that kdf name is not "none" or "bcrypt" | ||
15 | 18 | ||
16 | 20140401 | 19 | 20140401 |
17 | - (djm) On platforms that support it, use prctl() to prevent sftp-server | 20 | - (djm) On platforms that support it, use prctl() to prevent sftp-server |
diff --git a/authfile.c b/authfile.c index d7eaa9dec..0e97ba4ea 100644 --- a/authfile.c +++ b/authfile.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: authfile.c,v 1.103 2014/02/02 03:44:31 djm Exp $ */ | 1 | /* $OpenBSD: authfile.c,v 1.104 2014/03/12 04:51:12 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -281,7 +281,7 @@ key_parse_private2(Buffer *blob, int type, const char *passphrase, | |||
281 | } | 281 | } |
282 | kdfname = buffer_get_cstring_ret(©, NULL); | 282 | kdfname = buffer_get_cstring_ret(©, NULL); |
283 | if (kdfname == NULL || | 283 | if (kdfname == NULL || |
284 | (!strcmp(kdfname, "none") && !strcmp(kdfname, "bcrypt"))) { | 284 | (strcmp(kdfname, "none") != 0 && strcmp(kdfname, "bcrypt") != 0)) { |
285 | error("%s: unknown kdf name", __func__); | 285 | error("%s: unknown kdf name", __func__); |
286 | goto out; | 286 | goto out; |
287 | } | 287 | } |