agent: unknown flags on ssh signing requests cause an error. T3880 T3880-fix
authorDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Mon, 9 Apr 2018 22:06:38 +0000 (18:06 -0400)
committerDaniel Kahn Gillmor <dkg@fifthhorseman.net>
Mon, 9 Apr 2018 22:06:38 +0000 (18:06 -0400)
commit381c46818ffa4605d0ca39818fe317de445eb6de
tree4dd921f06c7c2a712eaeda36d86863c0a1c73946
parent55435cdd4fe4fbfbcba1098bb715ecd6171ba2d8
agent: unknown flags on ssh signing requests cause an error.

* agent/command-ssh.c (ssh_handler_sign_request): if a flag is passed
during an signature request that we do not know how to apply, return
GPG_ERR_UNKNOWN_OPTION.

--

https://tools.ietf.org/html/draft-miller-ssh-agent-02#section-4.5 says:

    If the agent does not support the requested flags, or is otherwise
    unable or unwilling to generate the signature (e.g. because it
    doesn't have the specified key, or the user refused confirmation of a
    constrained key), it must reply with a SSH_AGENT_FAILURE message.

Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
GnuPG-bug-id: 3880
agent/command-ssh.c