| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
#ifndef MOD_SFTP_MSG_H |
| 26 |
#define MOD_SFTP_MSG_H |
| 27 |
|
| 28 |
#include "mod_sftp.h" |
| 29 |
|
| 30 |
unsigned char sftp_msg_read_byte(pool *, unsigned char **, uint32_t *); |
| 31 |
int sftp_msg_read_bool(pool *, unsigned char **, uint32_t *); |
| 32 |
unsigned char *sftp_msg_read_data(pool *, unsigned char **, uint32_t *, size_t); |
| 33 |
unsigned char *sftp_msg_read_data_direct(pool *, unsigned char **, uint32_t *, |
| 34 |
size_t); |
| 35 |
#if defined(PR_USE_OPENSSL_ECC) |
| 36 |
EC_POINT *sftp_msg_read_ecpoint(pool *, unsigned char **, uint32_t *, |
| 37 |
const EC_GROUP *, EC_POINT *); |
| 38 |
#endif |
| 39 |
uint32_t sftp_msg_read_int(pool *, unsigned char **, uint32_t *); |
| 40 |
uint64_t sftp_msg_read_long(pool *, unsigned char **, uint32_t *); |
| 41 |
const BIGNUM *sftp_msg_read_mpint(pool *, unsigned char **, uint32_t *); |
| 42 |
char *sftp_msg_read_string(pool *, unsigned char **, uint32_t *); |
| 43 |
|
| 44 |
|
| 45 |
|
| 46 |
|
| 47 |
|
| 48 |
uint32_t sftp_msg_read_byte2(pool *, unsigned char **, uint32_t *, unsigned char *); |
| 49 |
uint32_t sftp_msg_read_bool2(pool *, unsigned char **, uint32_t *, int *); |
| 50 |
uint32_t sftp_msg_read_data2(pool *, unsigned char **, uint32_t *, size_t, unsigned char **); |
| 51 |
uint32_t sftp_msg_read_data2_direct(pool *, unsigned char **, uint32_t *, |
| 52 |
size_t, unsigned char **); |
| 53 |
#if defined(PR_USE_OPENSSL_ECC) |
| 54 |
uint32_t sftp_msg_read_ecpoint2(pool *, unsigned char **, uint32_t *, |
| 55 |
const EC_GROUP *, EC_POINT **); |
| 56 |
#endif |
| 57 |
uint32_t sftp_msg_read_int2(pool *, unsigned char **, uint32_t *, uint32_t *); |
| 58 |
uint32_t sftp_msg_read_long2(pool *, unsigned char **, uint32_t *, uint64_t *); |
| 59 |
uint32_t sftp_msg_read_mpint2(pool *, unsigned char **, uint32_t *, |
| 60 |
const BIGNUM **); |
| 61 |
uint32_t sftp_msg_read_string2(pool *, unsigned char **, uint32_t *, char **); |
| 62 |
|
| 63 |
uint32_t sftp_msg_write_byte(unsigned char **, uint32_t *, unsigned char); |
| 64 |
uint32_t sftp_msg_write_bool(unsigned char **, uint32_t *, unsigned char); |
| 65 |
uint32_t sftp_msg_write_data(unsigned char **, uint32_t *, |
| 66 |
const unsigned char *, size_t, int); |
| 67 |
#if defined(PR_USE_OPENSSL_ECC) |
| 68 |
uint32_t sftp_msg_write_ecpoint(unsigned char **, uint32_t *, const EC_GROUP *, |
| 69 |
const EC_POINT *); |
| 70 |
#endif |
| 71 |
uint32_t sftp_msg_write_int(unsigned char **, uint32_t *, uint32_t); |
| 72 |
uint32_t sftp_msg_write_long(unsigned char **, uint32_t *, uint64_t); |
| 73 |
uint32_t sftp_msg_write_mpint(unsigned char **, uint32_t *, const BIGNUM *); |
| 74 |
uint32_t sftp_msg_write_string(unsigned char **, uint32_t *, const char *); |
| 75 |
|
| 76 |
|
| 77 |
|
| 78 |
|
| 79 |
unsigned char *sftp_msg_getbuf(pool *, size_t); |
| 80 |
|
| 81 |
#endif |