mirror of
https://github.com/nmap/nmap.git
synced 2025-12-20 06:29:02 +00:00
Upgrade libssh2 to 1.9.0
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
#ifndef __LIBSSH2_MISC_H
|
||||
#define __LIBSSH2_MISC_H
|
||||
/* Copyright (c) 2009-2014 by Daniel Stenberg
|
||||
/* Copyright (c) 2009-2019 by Daniel Stenberg
|
||||
*
|
||||
* All rights reserved.
|
||||
*
|
||||
@@ -49,8 +49,15 @@ struct list_node {
|
||||
struct list_head *head;
|
||||
};
|
||||
|
||||
int _libssh2_error_flags(LIBSSH2_SESSION* session, int errcode, const char* errmsg, int errflags);
|
||||
int _libssh2_error(LIBSSH2_SESSION* session, int errcode, const char* errmsg);
|
||||
struct string_buf {
|
||||
unsigned char *data;
|
||||
unsigned char *dataptr;
|
||||
size_t len;
|
||||
};
|
||||
|
||||
int _libssh2_error_flags(LIBSSH2_SESSION* session, int errcode,
|
||||
const char *errmsg, int errflags);
|
||||
int _libssh2_error(LIBSSH2_SESSION* session, int errcode, const char *errmsg);
|
||||
|
||||
void _libssh2_list_init(struct list_head *head);
|
||||
|
||||
@@ -70,7 +77,7 @@ void *_libssh2_list_prev(struct list_node *node);
|
||||
/* remove this node from the list */
|
||||
void _libssh2_list_remove(struct list_node *entry);
|
||||
|
||||
size_t _libssh2_base64_encode(struct _LIBSSH2_SESSION *session,
|
||||
size_t _libssh2_base64_encode(LIBSSH2_SESSION *session,
|
||||
const char *inp, size_t insize, char **outptr);
|
||||
|
||||
unsigned int _libssh2_ntohu32(const unsigned char *buf);
|
||||
@@ -78,7 +85,22 @@ libssh2_uint64_t _libssh2_ntohu64(const unsigned char *buf);
|
||||
void _libssh2_htonu32(unsigned char *buf, uint32_t val);
|
||||
void _libssh2_store_u32(unsigned char **buf, uint32_t value);
|
||||
void _libssh2_store_str(unsigned char **buf, const char *str, size_t len);
|
||||
void *_libssh2_calloc(LIBSSH2_SESSION* session, size_t size);
|
||||
void *_libssh2_calloc(LIBSSH2_SESSION *session, size_t size);
|
||||
void _libssh2_explicit_zero(void *buf, size_t size);
|
||||
|
||||
struct string_buf* _libssh2_string_buf_new(LIBSSH2_SESSION *session);
|
||||
void _libssh2_string_buf_free(LIBSSH2_SESSION *session,
|
||||
struct string_buf *buf);
|
||||
int _libssh2_get_u32(struct string_buf *buf, uint32_t *out);
|
||||
int _libssh2_get_u64(struct string_buf *buf, libssh2_uint64_t *out);
|
||||
int _libssh2_match_string(struct string_buf *buf, const char *match);
|
||||
int _libssh2_get_string(struct string_buf *buf, unsigned char **outbuf,
|
||||
size_t *outlen);
|
||||
int _libssh2_copy_string(LIBSSH2_SESSION* session, struct string_buf *buf,
|
||||
unsigned char **outbuf, size_t *outlen);
|
||||
int _libssh2_get_bignum_bytes(struct string_buf *buf, unsigned char **outbuf,
|
||||
size_t *outlen);
|
||||
int _libssh2_check_length(struct string_buf *buf, size_t requested_len);
|
||||
|
||||
#if defined(LIBSSH2_WIN32) && !defined(__MINGW32__) && !defined(__CYGWIN__)
|
||||
/* provide a private one */
|
||||
@@ -93,4 +115,11 @@ int __cdecl _libssh2_gettimeofday(struct timeval *tp, void *tzp);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
void _libssh2_xor_data(unsigned char *output,
|
||||
const unsigned char *input1,
|
||||
const unsigned char *input2,
|
||||
size_t length);
|
||||
|
||||
void _libssh2_aes_ctr_increment(unsigned char *ctr, size_t length);
|
||||
|
||||
#endif /* _LIBSSH2_MISC_H */
|
||||
|
||||
Reference in New Issue
Block a user