diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2019-09-05 04:55:33 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2019-09-05 04:55:33 +0000 |
commit | 77336dbb54ee773ff22d13648989ebe5cd05fd88 (patch) | |
tree | e154ff8aef0e0c92f4fc35a2c43ce15ccc17f26a /usr.bin/ssh/sshsig.c | |
parent | 41a8c51cff4ae8c4aa06a77b6563d3c13cc34b06 (diff) |
expose allowed_signers options parsing code in header for fuzzing
rename to make more consistent with philosophically-similar auth
options parsing API.
Diffstat (limited to 'usr.bin/ssh/sshsig.c')
-rw-r--r-- | usr.bin/ssh/sshsig.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/usr.bin/ssh/sshsig.c b/usr.bin/ssh/sshsig.c index fbbaae92f42..0c89eaec573 100644 --- a/usr.bin/ssh/sshsig.c +++ b/usr.bin/ssh/sshsig.c @@ -603,16 +603,16 @@ sshsig_verify_fd(struct sshbuf *signature, int fd, return r; } -struct sigopts { +struct sshsigopt { int ca; char *namespaces; }; -static struct sigopts * -sigopts_parse(const char *opts, const char *path, u_long linenum, +struct sshsigopt * +sshsigopt_parse(const char *opts, const char *path, u_long linenum, const char **errstrp) { - struct sigopts *ret; + struct sshsigopt *ret; int r; const char *errstr = NULL; @@ -660,8 +660,8 @@ sigopts_parse(const char *opts, const char *path, u_long linenum, return NULL; } -static void -sigopts_free(struct sigopts *opts) +void +sshsigopt_free(struct sshsigopt *opts) { if (opts == NULL) return; @@ -678,7 +678,7 @@ check_allowed_keys_line(const char *path, u_long linenum, char *line, char *cp, *opts = NULL, *identities = NULL; int r, found = 0; const char *reason = NULL; - struct sigopts *sigopts = NULL; + struct sshsigopt *sigopts = NULL; if ((found_key = sshkey_new(KEY_UNSPEC)) == NULL) { error("%s: sshkey_new failed", __func__); @@ -718,7 +718,7 @@ check_allowed_keys_line(const char *path, u_long linenum, char *line, } } debug3("%s:%lu: options %s", path, linenum, opts == NULL ? "" : opts); - if ((sigopts = sigopts_parse(opts, path, linenum, &reason)) == NULL) { + if ((sigopts = sshsigopt_parse(opts, path, linenum, &reason)) == NULL) { error("%s:%lu: bad options: %s", path, linenum, reason); goto done; } @@ -754,7 +754,7 @@ check_allowed_keys_line(const char *path, u_long linenum, char *line, } done: sshkey_free(found_key); - sigopts_free(sigopts); + sshsigopt_free(sigopts); return found ? 0 : SSH_ERR_KEY_NOT_FOUND; } |