Annotation of embedaddon/miniupnpd/pf/obsdrdr.h, revision 1.1.1.1

1.1       misho       1: /* $Id: obsdrdr.h,v 1.17 2007/11/02 22:54:02 nanard Exp $ */
                      2: /* MiniUPnP project
                      3:  * http://miniupnp.free.fr/ or http://miniupnp.tuxfamily.org/
                      4:  * (c) 2006 Thomas Bernard 
                      5:  * This software is subject to the conditions detailed
                      6:  * in the LICENCE file provided within the distribution */
                      7: 
                      8: #ifndef __OBSDRDR_H__
                      9: #define __OBSDRDR_H__
                     10: 
                     11: #include "../commonrdr.h"
                     12: 
                     13: /* add_redirect_rule2() uses DIOCCHANGERULE ioctl
                     14:  * proto can take the values IPPROTO_UDP or IPPROTO_TCP
                     15:  */
                     16: int
                     17: add_redirect_rule2(const char * ifname, unsigned short eport,
                     18:                    const char * iaddr, unsigned short iport, int proto,
                     19:                                   const char * desc);
                     20: 
                     21: /* add_filter_rule2() uses DIOCCHANGERULE ioctl
                     22:  * proto can take the values IPPROTO_UDP or IPPROTO_TCP
                     23:  */
                     24: int
                     25: add_filter_rule2(const char * ifname, const char * iaddr,
                     26:                  unsigned short eport, unsigned short iport,
                     27:                                 int proto, const char * desc);
                     28:  
                     29: 
                     30: /* get_redirect_rule() gets internal IP and port from
                     31:  * interface, external port and protocl
                     32:  */
                     33: #if 0
                     34: int
                     35: get_redirect_rule(const char * ifname, unsigned short eport, int proto,
                     36:                   char * iaddr, int iaddrlen, unsigned short * iport,
                     37:                   char * desc, int desclen,
                     38:                   u_int64_t * packets, u_int64_t * bytes);
                     39: 
                     40: int
                     41: get_redirect_rule_by_index(int index,
                     42:                            char * ifname, unsigned short * eport,
                     43:                            char * iaddr, int iaddrlen, unsigned short * iport,
                     44:                            int * proto, char * desc, int desclen,
                     45:                            u_int64_t * packets, u_int64_t * bytes);
                     46: #endif
                     47: 
                     48: /* delete_redirect_rule()
                     49:  */
                     50: int
                     51: delete_redirect_rule(const char * ifname, unsigned short eport, int proto);
                     52: 
                     53: /* delete_filter_rule()
                     54:  */
                     55: int
                     56: delete_filter_rule(const char * ifname, unsigned short eport, int proto);
                     57: 
                     58: int
                     59: clear_redirect_rules(void);
                     60: 
                     61: #endif
                     62: 
                     63: 

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>