Mercurial > dropbear
comparison dbutil.h @ 568:005530560594
Rearrange getaddrstring() etc
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Tue, 01 Sep 2009 16:38:26 +0000 |
parents | d588e3ea557a |
children | 00eca37e47e8 |
comparison
equal
deleted
inserted
replaced
567:893a9dd0b9dd | 568:005530560594 |
---|---|
44 void dropbear_trace(const char* format, ...); | 44 void dropbear_trace(const char* format, ...); |
45 void printhex(const char * label, const unsigned char * buf, int len); | 45 void printhex(const char * label, const unsigned char * buf, int len); |
46 extern int debug_trace; | 46 extern int debug_trace; |
47 #endif | 47 #endif |
48 char * stripcontrol(const char * text); | 48 char * stripcontrol(const char * text); |
49 unsigned char * getaddrstring(struct sockaddr_storage* addr, int withport); | 49 void get_socket_address(int fd, char **local_host, char **local_port, |
50 char **remote_host, char **remote_port, int host_lookup); | |
51 void getaddrstring(struct sockaddr_storage* addr, | |
52 char **ret_host, char **ret_port, int host_lookup); | |
50 int dropbear_listen(const char* address, const char* port, | 53 int dropbear_listen(const char* address, const char* port, |
51 int *socks, unsigned int sockcount, char **errstring, int *maxfd); | 54 int *socks, unsigned int sockcount, char **errstring, int *maxfd); |
52 int spawn_command(void(*exec_fn)(void *user_data), void *exec_data, | 55 int spawn_command(void(*exec_fn)(void *user_data), void *exec_data, |
53 int *writefd, int *readfd, int *errfd, pid_t *pid); | 56 int *writefd, int *readfd, int *errfd, pid_t *pid); |
54 void run_shell_command(const char* cmd, unsigned int maxfd, char* usershell); | 57 void run_shell_command(const char* cmd, unsigned int maxfd, char* usershell); |
55 #ifdef ENABLE_CONNECT_UNIX | 58 #ifdef ENABLE_CONNECT_UNIX |
56 int connect_unix(const char* addr); | 59 int connect_unix(const char* addr); |
57 #endif | 60 #endif |
58 int connect_remote(const char* remotehost, const char* remoteport, | 61 int connect_remote(const char* remotehost, const char* remoteport, |
59 int nonblocking, char ** errstring); | 62 int nonblocking, char ** errstring); |
60 char* getaddrhostname(struct sockaddr_storage * addr); | |
61 int buf_readfile(buffer* buf, const char* filename); | 63 int buf_readfile(buffer* buf, const char* filename); |
62 int buf_getline(buffer * line, FILE * authfile); | 64 int buf_getline(buffer * line, FILE * authfile); |
63 | 65 |
64 void m_close(int fd); | 66 void m_close(int fd); |
65 void * m_malloc(size_t size); | 67 void * m_malloc(size_t size); |