1/* $Id: pfpinhole.h,v 1.9 2012/05/01 22:37:53 nanard Exp $ */
2/* MiniUPnP project
3 * http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
4 * (c) 2012 Thomas Bernard
5 * This software is subject to the conditions detailed
6 * in the LICENCE file provided within the distribution */
7
8#ifndef PFPINHOLE_H_INCLUDED
9#define PFPINHOLE_H_INCLUDED
10
11#ifdef ENABLE_UPNPPINHOLE
12
13int add_pinhole(const char * ifname,
14                const char * rem_host, unsigned short rem_port,
15                const char * int_client, unsigned short int_port,
16                int proto, const char * desc, unsigned int timestamp);
17
18int delete_pinhole(unsigned short uid);
19
20int
21get_pinhole_info(unsigned short uid,
22                 char * rem_host, int rem_hostlen, unsigned short * rem_port,
23                 char * int_client, int int_clientlen, unsigned short * int_port,
24                 int * proto, char * desc, int desclen,
25                 unsigned int * timestamp,
26                 u_int64_t * packets, u_int64_t * bytes);
27
28int update_pinhole(unsigned short uid, unsigned int timestamp);
29
30int clean_pinhole_list(unsigned int * next_timestamp);
31
32#endif /* ENABLE_UPNPPINHOLE */
33
34#endif
35
36