mirror of
git://anongit.mindrot.org/openssh.git
synced 2025-02-22 16:56:53 +00:00
- markus@cvs.openbsd.org 2002/02/24 19:14:59
[auth2.c authfd.c authfd.h authfile.c kexdh.c kexgex.c key.c key.h ssh-dss.c ssh-dss.h ssh-keygen.c ssh-rsa.c ssh-rsa.h sshconnect2.c] signed vs. unsigned: make size arguments u_int, ok stevesk@
This commit is contained in:
parent
e45a2cb2b7
commit
90fd814f90
@ -38,6 +38,10 @@
|
|||||||
- markus@cvs.openbsd.org 2002/02/24 18:31:09
|
- markus@cvs.openbsd.org 2002/02/24 18:31:09
|
||||||
[uuencode.c]
|
[uuencode.c]
|
||||||
typo in comment
|
typo in comment
|
||||||
|
- markus@cvs.openbsd.org 2002/02/24 19:14:59
|
||||||
|
[auth2.c authfd.c authfd.h authfile.c kexdh.c kexgex.c key.c key.h
|
||||||
|
ssh-dss.c ssh-dss.h ssh-keygen.c ssh-rsa.c ssh-rsa.h sshconnect2.c]
|
||||||
|
signed vs. unsigned: make size arguments u_int, ok stevesk@
|
||||||
|
|
||||||
20020225
|
20020225
|
||||||
- (bal) Last AIX patch. Moved aix_usrinfo() outside of do_setuserconext()
|
- (bal) Last AIX patch. Moved aix_usrinfo() outside of do_setuserconext()
|
||||||
@ -7711,4 +7715,4 @@
|
|||||||
- Wrote replacements for strlcpy and mkdtemp
|
- Wrote replacements for strlcpy and mkdtemp
|
||||||
- Released 1.0pre1
|
- Released 1.0pre1
|
||||||
|
|
||||||
$Id: ChangeLog,v 1.1884 2002/02/26 18:07:26 mouring Exp $
|
$Id: ChangeLog,v 1.1885 2002/02/26 18:09:42 mouring Exp $
|
||||||
|
9
auth2.c
9
auth2.c
@ -23,7 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: auth2.c,v 1.84 2002/02/04 11:58:10 markus Exp $");
|
RCSID("$OpenBSD: auth2.c,v 1.85 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
@ -398,7 +398,8 @@ userauth_pubkey(Authctxt *authctxt)
|
|||||||
{
|
{
|
||||||
Buffer b;
|
Buffer b;
|
||||||
Key *key = NULL;
|
Key *key = NULL;
|
||||||
char *pkalg, *pkblob, *sig;
|
char *pkalg;
|
||||||
|
u_char *pkblob, *sig;
|
||||||
u_int alen, blen, slen;
|
u_int alen, blen, slen;
|
||||||
int have_sig, pktype;
|
int have_sig, pktype;
|
||||||
int authenticated = 0;
|
int authenticated = 0;
|
||||||
@ -512,7 +513,8 @@ userauth_hostbased(Authctxt *authctxt)
|
|||||||
{
|
{
|
||||||
Buffer b;
|
Buffer b;
|
||||||
Key *key = NULL;
|
Key *key = NULL;
|
||||||
char *pkalg, *pkblob, *sig, *cuser, *chost, *service;
|
char *pkalg, *cuser, *chost, *service;
|
||||||
|
u_char *pkblob, *sig;
|
||||||
u_int alen, blen, slen;
|
u_int alen, blen, slen;
|
||||||
int pktype;
|
int pktype;
|
||||||
int authenticated = 0;
|
int authenticated = 0;
|
||||||
@ -794,4 +796,3 @@ hostbased_key_allowed(struct passwd *pw, const char *cuser, char *chost,
|
|||||||
|
|
||||||
return (host_status == HOST_OK);
|
return (host_status == HOST_OK);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
6
authfd.c
6
authfd.c
@ -35,7 +35,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: authfd.c,v 1.47 2002/01/18 18:14:17 stevesk Exp $");
|
RCSID("$OpenBSD: authfd.c,v 1.48 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
@ -374,8 +374,8 @@ ssh_decrypt_challenge(AuthenticationConnection *auth,
|
|||||||
int
|
int
|
||||||
ssh_agent_sign(AuthenticationConnection *auth,
|
ssh_agent_sign(AuthenticationConnection *auth,
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char **sigp, int *lenp,
|
u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
extern int datafellows;
|
extern int datafellows;
|
||||||
Buffer msg;
|
Buffer msg;
|
||||||
|
6
authfd.h
6
authfd.h
@ -11,7 +11,7 @@
|
|||||||
* called by a name other than "ssh" or "Secure Shell".
|
* called by a name other than "ssh" or "Secure Shell".
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* RCSID("$OpenBSD: authfd.h,v 1.21 2001/08/07 10:37:46 markus Exp $"); */
|
/* RCSID("$OpenBSD: authfd.h,v 1.22 2002/02/24 19:14:59 markus Exp $"); */
|
||||||
|
|
||||||
#ifndef AUTHFD_H
|
#ifndef AUTHFD_H
|
||||||
#define AUTHFD_H
|
#define AUTHFD_H
|
||||||
@ -74,7 +74,7 @@ ssh_decrypt_challenge(AuthenticationConnection *, Key *, BIGNUM *, u_char[16],
|
|||||||
u_int, u_char[16]);
|
u_int, u_char[16]);
|
||||||
|
|
||||||
int
|
int
|
||||||
ssh_agent_sign(AuthenticationConnection *, Key *, u_char **, int *, u_char *,
|
ssh_agent_sign(AuthenticationConnection *, Key *, u_char **, u_int *, u_char *,
|
||||||
int);
|
u_int);
|
||||||
|
|
||||||
#endif /* AUTHFD_H */
|
#endif /* AUTHFD_H */
|
||||||
|
@ -36,7 +36,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: authfile.c,v 1.46 2002/02/14 23:41:01 markus Exp $");
|
RCSID("$OpenBSD: authfile.c,v 1.47 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
@ -168,7 +168,7 @@ key_save_private_pem(Key *key, const char *filename, const char *_passphrase,
|
|||||||
int fd;
|
int fd;
|
||||||
int success = 0;
|
int success = 0;
|
||||||
int len = strlen(_passphrase);
|
int len = strlen(_passphrase);
|
||||||
char *passphrase = (len > 0) ? (char *)_passphrase : NULL;
|
u_char *passphrase = (len > 0) ? (u_char *)_passphrase : NULL;
|
||||||
EVP_CIPHER *cipher = (len > 0) ? EVP_des_ede3_cbc() : NULL;
|
EVP_CIPHER *cipher = (len > 0) ? EVP_des_ede3_cbc() : NULL;
|
||||||
|
|
||||||
if (len > 0 && len <= 4) {
|
if (len > 0 && len <= 4) {
|
||||||
|
4
kexdh.c
4
kexdh.c
@ -23,7 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: kexdh.c,v 1.15 2002/02/23 17:59:02 markus Exp $");
|
RCSID("$OpenBSD: kexdh.c,v 1.16 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/crypto.h>
|
#include <openssl/crypto.h>
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
@ -201,7 +201,7 @@ kexdh_server(Kex *kex)
|
|||||||
Key *server_host_key;
|
Key *server_host_key;
|
||||||
u_char *kbuf, *hash, *signature = NULL, *server_host_key_blob = NULL;
|
u_char *kbuf, *hash, *signature = NULL, *server_host_key_blob = NULL;
|
||||||
u_int sbloblen, klen, kout;
|
u_int sbloblen, klen, kout;
|
||||||
int slen;
|
u_int slen;
|
||||||
|
|
||||||
/* generate server DH public key */
|
/* generate server DH public key */
|
||||||
dh = dh_new_group1();
|
dh = dh_new_group1();
|
||||||
|
6
kexgex.c
6
kexgex.c
@ -24,7 +24,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: kexgex.c,v 1.18 2002/02/23 17:59:02 markus Exp $");
|
RCSID("$OpenBSD: kexgex.c,v 1.19 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
|
|
||||||
@ -261,8 +261,8 @@ kexgex_server(Kex *kex)
|
|||||||
Key *server_host_key;
|
Key *server_host_key;
|
||||||
DH *dh = dh;
|
DH *dh = dh;
|
||||||
u_char *kbuf, *hash, *signature = NULL, *server_host_key_blob = NULL;
|
u_char *kbuf, *hash, *signature = NULL, *server_host_key_blob = NULL;
|
||||||
u_int sbloblen, klen, kout;
|
u_int sbloblen, klen, kout, slen;
|
||||||
int min = -1, max = -1, nbits = -1, type, slen;
|
int min = -1, max = -1, nbits = -1, type;
|
||||||
|
|
||||||
if (kex->load_host_key == NULL)
|
if (kex->load_host_key == NULL)
|
||||||
fatal("Cannot load hostkey");
|
fatal("Cannot load hostkey");
|
||||||
|
19
key.c
19
key.c
@ -32,7 +32,7 @@
|
|||||||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: key.c,v 1.39 2002/01/25 22:07:40 markus Exp $");
|
RCSID("$OpenBSD: key.c,v 1.40 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
|
|
||||||
@ -176,7 +176,7 @@ key_fingerprint_raw(Key *k, enum fp_type dgst_type, u_int *dgst_raw_length)
|
|||||||
EVP_MD_CTX ctx;
|
EVP_MD_CTX ctx;
|
||||||
u_char *blob = NULL;
|
u_char *blob = NULL;
|
||||||
u_char *retval = NULL;
|
u_char *retval = NULL;
|
||||||
int len = 0;
|
u_int len = 0;
|
||||||
int nlen, elen;
|
int nlen, elen;
|
||||||
|
|
||||||
*dgst_raw_length = 0;
|
*dgst_raw_length = 0;
|
||||||
@ -488,8 +488,9 @@ key_read(Key *ret, char **cpp)
|
|||||||
int
|
int
|
||||||
key_write(Key *key, FILE *f)
|
key_write(Key *key, FILE *f)
|
||||||
{
|
{
|
||||||
int success = 0;
|
int n, success = 0;
|
||||||
u_int bits = 0;
|
u_int len, bits = 0;
|
||||||
|
u_char *blob, *uu;
|
||||||
|
|
||||||
if (key->type == KEY_RSA1 && key->rsa != NULL) {
|
if (key->type == KEY_RSA1 && key->rsa != NULL) {
|
||||||
/* size of modulus 'n' */
|
/* size of modulus 'n' */
|
||||||
@ -503,8 +504,6 @@ key_write(Key *key, FILE *f)
|
|||||||
}
|
}
|
||||||
} else if ((key->type == KEY_DSA && key->dsa != NULL) ||
|
} else if ((key->type == KEY_DSA && key->dsa != NULL) ||
|
||||||
(key->type == KEY_RSA && key->rsa != NULL)) {
|
(key->type == KEY_RSA && key->rsa != NULL)) {
|
||||||
int len, n;
|
|
||||||
u_char *blob, *uu;
|
|
||||||
key_to_blob(key, &blob, &len);
|
key_to_blob(key, &blob, &len);
|
||||||
uu = xmalloc(2*len);
|
uu = xmalloc(2*len);
|
||||||
n = uuencode(blob, len, uu, 2*len);
|
n = uuencode(blob, len, uu, 2*len);
|
||||||
@ -763,8 +762,8 @@ key_to_blob(Key *key, u_char **blobp, u_int *lenp)
|
|||||||
int
|
int
|
||||||
key_sign(
|
key_sign(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char **sigp, int *lenp,
|
u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
switch (key->type) {
|
switch (key->type) {
|
||||||
case KEY_DSA:
|
case KEY_DSA:
|
||||||
@ -783,8 +782,8 @@ key_sign(
|
|||||||
int
|
int
|
||||||
key_verify(
|
key_verify(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char *signature, int signaturelen,
|
u_char *signature, u_int signaturelen,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
if (signaturelen == 0)
|
if (signaturelen == 0)
|
||||||
return -1;
|
return -1;
|
||||||
|
6
key.h
6
key.h
@ -1,4 +1,4 @@
|
|||||||
/* $OpenBSD: key.h,v 1.17 2001/09/17 19:27:15 stevesk Exp $ */
|
/* $OpenBSD: key.h,v 1.18 2002/02/24 19:14:59 markus Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2000, 2001 Markus Friedl. All rights reserved.
|
* Copyright (c) 2000, 2001 Markus Friedl. All rights reserved.
|
||||||
@ -74,7 +74,7 @@ int key_to_blob(Key *, u_char **, u_int *);
|
|||||||
char *key_ssh_name(Key *);
|
char *key_ssh_name(Key *);
|
||||||
int key_names_valid2(const char *);
|
int key_names_valid2(const char *);
|
||||||
|
|
||||||
int key_sign(Key *, u_char **, int *, u_char *, int);
|
int key_sign(Key *, u_char **, u_int *, u_char *, u_int);
|
||||||
int key_verify(Key *, u_char *, int, u_char *, int);
|
int key_verify(Key *, u_char *, u_int, u_char *, u_int);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
10
ssh-dss.c
10
ssh-dss.c
@ -23,7 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: ssh-dss.c,v 1.12 2002/01/25 21:42:11 markus Exp $");
|
RCSID("$OpenBSD: ssh-dss.c,v 1.13 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/bn.h>
|
#include <openssl/bn.h>
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
@ -42,8 +42,8 @@ RCSID("$OpenBSD: ssh-dss.c,v 1.12 2002/01/25 21:42:11 markus Exp $");
|
|||||||
int
|
int
|
||||||
ssh_dss_sign(
|
ssh_dss_sign(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char **sigp, int *lenp,
|
u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
DSA_SIG *sig;
|
DSA_SIG *sig;
|
||||||
EVP_MD *evp_md = EVP_sha1();
|
EVP_MD *evp_md = EVP_sha1();
|
||||||
@ -106,8 +106,8 @@ ssh_dss_sign(
|
|||||||
int
|
int
|
||||||
ssh_dss_verify(
|
ssh_dss_verify(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char *signature, int signaturelen,
|
u_char *signature, u_int signaturelen,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
DSA_SIG *sig;
|
DSA_SIG *sig;
|
||||||
EVP_MD *evp_md = EVP_sha1();
|
EVP_MD *evp_md = EVP_sha1();
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $OpenBSD: ssh-dss.h,v 1.5 2001/06/26 17:27:25 markus Exp $ */
|
/* $OpenBSD: ssh-dss.h,v 1.6 2002/02/24 19:14:59 markus Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2000 Markus Friedl. All rights reserved.
|
* Copyright (c) 2000 Markus Friedl. All rights reserved.
|
||||||
@ -26,7 +26,7 @@
|
|||||||
#ifndef DSA_H
|
#ifndef DSA_H
|
||||||
#define DSA_H
|
#define DSA_H
|
||||||
|
|
||||||
int ssh_dss_sign(Key *, u_char **, int *, u_char *, int);
|
int ssh_dss_sign(Key *, u_char **, u_int *, u_char *, u_int);
|
||||||
int ssh_dss_verify(Key *, u_char *, int, u_char *, int);
|
int ssh_dss_verify(Key *, u_char *, u_int, u_char *, u_int);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: ssh-keygen.c,v 1.92 2002/02/16 20:40:08 stevesk Exp $");
|
RCSID("$OpenBSD: ssh-keygen.c,v 1.93 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
#include <openssl/pem.h>
|
#include <openssl/pem.h>
|
||||||
@ -196,7 +196,7 @@ buffer_get_bignum_bits(Buffer *b, BIGNUM *value)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static Key *
|
static Key *
|
||||||
do_convert_private_ssh2_from_blob(u_char *blob, int blen)
|
do_convert_private_ssh2_from_blob(u_char *blob, u_int blen)
|
||||||
{
|
{
|
||||||
Buffer b;
|
Buffer b;
|
||||||
Key *key = NULL;
|
Key *key = NULL;
|
||||||
|
10
ssh-rsa.c
10
ssh-rsa.c
@ -23,7 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: ssh-rsa.c,v 1.15 2002/01/25 21:42:11 markus Exp $");
|
RCSID("$OpenBSD: ssh-rsa.c,v 1.16 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include <openssl/evp.h>
|
#include <openssl/evp.h>
|
||||||
#include <openssl/err.h>
|
#include <openssl/err.h>
|
||||||
@ -40,8 +40,8 @@ RCSID("$OpenBSD: ssh-rsa.c,v 1.15 2002/01/25 21:42:11 markus Exp $");
|
|||||||
int
|
int
|
||||||
ssh_rsa_sign(
|
ssh_rsa_sign(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char **sigp, int *lenp,
|
u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
const EVP_MD *evp_md;
|
const EVP_MD *evp_md;
|
||||||
EVP_MD_CTX md;
|
EVP_MD_CTX md;
|
||||||
@ -110,8 +110,8 @@ ssh_rsa_sign(
|
|||||||
int
|
int
|
||||||
ssh_rsa_verify(
|
ssh_rsa_verify(
|
||||||
Key *key,
|
Key *key,
|
||||||
u_char *signature, int signaturelen,
|
u_char *signature, u_int signaturelen,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
Buffer b;
|
Buffer b;
|
||||||
const EVP_MD *evp_md;
|
const EVP_MD *evp_md;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $OpenBSD: ssh-rsa.h,v 1.5 2001/06/26 17:27:25 markus Exp $ */
|
/* $OpenBSD: ssh-rsa.h,v 1.6 2002/02/24 19:14:59 markus Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2000 Markus Friedl. All rights reserved.
|
* Copyright (c) 2000 Markus Friedl. All rights reserved.
|
||||||
@ -26,7 +26,7 @@
|
|||||||
#ifndef SSH_RSA_H
|
#ifndef SSH_RSA_H
|
||||||
#define SSH_RSA_H
|
#define SSH_RSA_H
|
||||||
|
|
||||||
int ssh_rsa_sign(Key *, u_char **, int *, u_char *, int);
|
int ssh_rsa_sign(Key *, u_char **, u_int *, u_char *, u_int);
|
||||||
int ssh_rsa_verify(Key *, u_char *, int, u_char *, int);
|
int ssh_rsa_verify(Key *, u_char *, u_int, u_char *, u_int);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -23,7 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: sshconnect2.c,v 1.95 2002/02/03 17:59:23 markus Exp $");
|
RCSID("$OpenBSD: sshconnect2.c,v 1.96 2002/02/24 19:14:59 markus Exp $");
|
||||||
|
|
||||||
#include "ssh.h"
|
#include "ssh.h"
|
||||||
#include "ssh2.h"
|
#include "ssh2.h"
|
||||||
@ -138,7 +138,7 @@ typedef struct Authmethod Authmethod;
|
|||||||
|
|
||||||
typedef int sign_cb_fn(
|
typedef int sign_cb_fn(
|
||||||
Authctxt *authctxt, Key *key,
|
Authctxt *authctxt, Key *key,
|
||||||
u_char **sigp, int *lenp, u_char *data, int datalen);
|
u_char **sigp, u_int *lenp, u_char *data, u_int datalen);
|
||||||
|
|
||||||
struct Authctxt {
|
struct Authctxt {
|
||||||
const char *server_user;
|
const char *server_user;
|
||||||
@ -353,8 +353,10 @@ input_userauth_pk_ok(int type, u_int32_t seq, void *ctxt)
|
|||||||
Authctxt *authctxt = ctxt;
|
Authctxt *authctxt = ctxt;
|
||||||
Key *key = NULL;
|
Key *key = NULL;
|
||||||
Buffer b;
|
Buffer b;
|
||||||
int pktype, alen, blen, sent = 0;
|
int pktype, sent = 0;
|
||||||
char *pkalg, *pkblob, *fp;
|
u_int alen, blen;
|
||||||
|
char *pkalg, *fp;
|
||||||
|
u_char *pkblob;
|
||||||
|
|
||||||
if (authctxt == NULL)
|
if (authctxt == NULL)
|
||||||
fatal("input_userauth_pk_ok: no authentication context");
|
fatal("input_userauth_pk_ok: no authentication context");
|
||||||
@ -480,7 +482,7 @@ sign_and_send_pubkey(Authctxt *authctxt, Key *k, sign_cb_fn *sign_callback)
|
|||||||
{
|
{
|
||||||
Buffer b;
|
Buffer b;
|
||||||
u_char *blob, *signature;
|
u_char *blob, *signature;
|
||||||
int bloblen, slen;
|
u_int bloblen, slen;
|
||||||
int skip = 0;
|
int skip = 0;
|
||||||
int ret = -1;
|
int ret = -1;
|
||||||
int have_sig = 1;
|
int have_sig = 1;
|
||||||
@ -632,8 +634,8 @@ load_identity_file(char *filename)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
identity_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, int *lenp,
|
identity_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
Key *private;
|
Key *private;
|
||||||
int idx, ret;
|
int idx, ret;
|
||||||
@ -655,15 +657,15 @@ identity_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, int *lenp,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
agent_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, int *lenp,
|
agent_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
return ssh_agent_sign(authctxt->agent, key, sigp, lenp, data, datalen);
|
return ssh_agent_sign(authctxt->agent, key, sigp, lenp, data, datalen);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
key_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, int *lenp,
|
key_sign_cb(Authctxt *authctxt, Key *key, u_char **sigp, u_int *lenp,
|
||||||
u_char *data, int datalen)
|
u_char *data, u_int datalen)
|
||||||
{
|
{
|
||||||
return key_sign(key, sigp, lenp, data, datalen);
|
return key_sign(key, sigp, lenp, data, datalen);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user