diff options
author | Matt Johnston <matt@ucc.asn.au> | 2015-06-04 23:08:50 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2015-06-04 23:08:50 +0800 |
commit | 1a4db21fe4e06f4a5e5b74e35027091370b54abb (patch) | |
tree | 7543bf0e7a5d133c5564dd0ddcf35685bc308a98 /cli-authpubkey.c | |
parent | e7ac4c1ab3eee827d781ececf6c7342c432b91d3 (diff) |
buf_getstring and buf_putstring now use non-unsigned char*
Diffstat (limited to 'cli-authpubkey.c')
-rw-r--r-- | cli-authpubkey.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/cli-authpubkey.c b/cli-authpubkey.c index fa04f17..d53178e 100644 --- a/cli-authpubkey.c +++ b/cli-authpubkey.c @@ -63,7 +63,7 @@ void recv_msg_userauth_pk_ok() { TRACE(("enter recv_msg_userauth_pk_ok")) - algotype = (char *)buf_getstring(ses.payload, &algolen); + algotype = buf_getstring(ses.payload, &algolen); keytype = signkey_type_from_name(algotype, algolen); TRACE(("recv_msg_userauth_pk_ok: type %d", keytype)) m_free(algotype); @@ -149,20 +149,20 @@ static void send_msg_userauth_pubkey(sign_key *key, int type, int realsign) { buf_putbyte(ses.writepayload, SSH_MSG_USERAUTH_REQUEST); - buf_putstring(ses.writepayload, (const unsigned char *)cli_opts.username, + buf_putstring(ses.writepayload, cli_opts.username, strlen(cli_opts.username)); - buf_putstring(ses.writepayload, (const unsigned char *)SSH_SERVICE_CONNECTION, + buf_putstring(ses.writepayload, SSH_SERVICE_CONNECTION, SSH_SERVICE_CONNECTION_LEN); - buf_putstring(ses.writepayload, (const unsigned char *)AUTH_METHOD_PUBKEY, + buf_putstring(ses.writepayload, AUTH_METHOD_PUBKEY, AUTH_METHOD_PUBKEY_LEN); buf_putbyte(ses.writepayload, realsign); algoname = signkey_name_from_type(type, &algolen); - buf_putstring(ses.writepayload, (const unsigned char *)algoname, algolen); + buf_putstring(ses.writepayload, algoname, algolen); buf_put_pub_key(ses.writepayload, key, type); if (realsign) { |