summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2019-06-08 23:10:54 -0400
committerAndrew Cady <d@jerkface.net>2020-10-27 17:45:23 -0400
commitd889b1f1174ef9df441457544d3bf611541ce406 (patch)
treea6422ddfaf2045b8b878a19a7f6a87f3adfe5d66
parent6a53bc2f7b339aec4dbb0b7b79c15fe179c2215f (diff)
conditional is more clear now
-rw-r--r--auth2-pubkey.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/auth2-pubkey.c b/auth2-pubkey.c
index 1ea40f2da..2db435c1d 100644
--- a/auth2-pubkey.c
+++ b/auth2-pubkey.c
@@ -589,9 +589,9 @@ check_authkey_line_for_wildcard(struct sshkey *key, char *cp, const char *loc, s
589 if (advance_past_options(&cp) != 0) return -1; 589 if (advance_past_options(&cp) != 0) return -1;
590 skip_space(&cp); 590 skip_space(&cp);
591 591
592 if (!(*cp == '*' && (cp[1] == ' ' || cp[1] == '\n' || cp[1] == '\t' || cp[1] == '\0'))) { 592 // A wildcard auth line must start "* " or "*\t"
593 return -1; // This is not a wildcard auth line. 593 if (cp[0] != '*') return -1;
594 } 594 if (cp[1] != ' ' && cp[1] != '\t') return -1;
595 595
596 if ((keyopts = sshauthopt_parse(key_options, &reason)) == NULL) { 596 if ((keyopts = sshauthopt_parse(key_options, &reason)) == NULL) {
597 debug("%s: bad key options: %s", loc, reason); 597 debug("%s: bad key options: %s", loc, reason);