X-Git-Url: https://git.tcpdump.org/libpcap/blobdiff_plain/2712833d7d386a2d79ad32958e50fe61cd552963..09b51d326c38ea8e10ce4da09c09d50e08c5aeb8:/pcap-rpcap-int.h diff --git a/pcap-rpcap-int.h b/pcap-rpcap-int.h index 148056f6..e707a85f 100644 --- a/pcap-rpcap-int.h +++ b/pcap-rpcap-int.h @@ -31,17 +31,17 @@ * */ -#ifndef __PCAP_REMOTE_H__ -#define __PCAP_REMOTE_H__ +#ifndef __PCAP_RPCAP_INT_H__ +#define __PCAP_RPCAP_INT_H__ #include "pcap.h" #include "sockutils.h" /* Needed for some structures (like SOCKET, sockaddr_in) which are used here */ /* - * \file pcap-rpcap.h + * \file pcap-rpcap-int.h * - * This file keeps all the new definitions and typedefs that are exported to the user and - * that are needed for the RPCAP protocol. + * This file keeps all the definitions used by the RPCAP client and server, + * other than the protocol definitions. * * \warning All the RPCAP functions that are allowed to return a buffer containing * the error description can return max PCAP_ERRBUF_SIZE characters. @@ -50,16 +50,6 @@ * and to insert manually the termination char at the end of the buffer. This will * guarantee that no buffer overflows occur even if we use the printf() to show * the error on the screen. - * - * \warning This file declares some typedefs that MUST be of a specific size. - * These definitions (i.e. typedefs) could need to be changed on other platforms than - * Intel IA32. - * - * \warning This file defines some structures that are used to transfer data on the network. - * Be careful that you compiler MUST not insert padding into these structures - * for better alignment. - * These structures have been created in order to be correctly aligned to a 32 bits - * boundary, but be careful in any case. */ /********************************************************* @@ -74,37 +64,12 @@ */ #define RPCAP_NETBUF_SIZE 64000 -/* - * \brief Keeps a list of all the opened connections in the active mode. - * - * This structure defines a linked list of items that are needed to keep the info required to - * manage the active mode. - * In other words, when a new connection in active mode starts, this structure is updated so that - * it reflects the list of active mode connections currently opened. - * This structure is required by findalldevs() and open_remote() to see if they have to open a new - * control connection toward the host, or they already have a control connection in place. - */ -struct activehosts -{ - struct sockaddr_storage host; - SOCKET sockctrl; - struct activehosts *next; -}; - /********************************************************* * * * Exported function prototypes * * * *********************************************************/ -int pcap_opensource_remote(pcap_t *p, struct pcap_rmtauth *auth); -int pcap_startcapture_remote(pcap_t *fp); - void rpcap_createhdr(struct rpcap_header *header, uint8 type, uint16 value, uint32 length); -int rpcap_deseraddr(struct rpcap_sockaddr *sockaddrin, struct sockaddr_storage **sockaddrout, char *errbuf); -int rpcap_checkmsg(char *errbuf, SOCKET sock, struct rpcap_header *header, uint8 first, ...); int rpcap_senderror(SOCKET sock, char *error, unsigned short errcode, char *errbuf); -int rpcap_sendauth(SOCKET sock, struct pcap_rmtauth *auth, char *errbuf); - -SOCKET rpcap_remoteact_getsock(const char *host, int *isactive, char *errbuf); #endif