summaryrefslogtreecommitdiff
path: root/cli-agentfwd.c
diff options
context:
space:
mode:
authorMatt Johnston <matt@ucc.asn.au>2013-04-06 16:00:37 +0800
committerMatt Johnston <matt@ucc.asn.au>2013-04-06 16:00:37 +0800
commitc56b3437098b757289eb77b3a02142d3d8fe6681 (patch)
tree437434afaf02b00afa5493687e19c7acc5f21b8d /cli-agentfwd.c
parent92d78720daabce7e98b73975043179a4ac539755 (diff)
downloaddropbear-c56b3437098b757289eb77b3a02142d3d8fe6681.tar.gz
Make _sign and _verify functions take a buffer* rather than void* and int
Diffstat (limited to 'cli-agentfwd.c')
-rw-r--r--cli-agentfwd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/cli-agentfwd.c b/cli-agentfwd.c
index c661455..b7b8da3 100644
--- a/cli-agentfwd.c
+++ b/cli-agentfwd.c
@@ -254,7 +254,7 @@ void cli_load_agent_keys(m_list *ret_list) {
}
void agent_buf_sign(buffer *sigblob, sign_key *key,
- const unsigned char *data, unsigned int len) {
+ buffer *data_buf) {
buffer *request_data = NULL;
buffer *response = NULL;
unsigned int siglen;
@@ -266,10 +266,10 @@ void agent_buf_sign(buffer *sigblob, sign_key *key,
string data
uint32 flags
*/
- request_data = buf_new(MAX_PUBKEY_SIZE + len + 12);
+ request_data = buf_new(MAX_PUBKEY_SIZE + data_buf>-len + 12);
buf_put_pub_key(request_data, key, key->type);
- buf_putstring(request_data, data, len);
+ buf_putbufstring(request_data, data_buf);
buf_putint(request_data, 0);
response = agent_request(SSH2_AGENTC_SIGN_REQUEST, request_data);