Add simple tests for libirc.
[jelmer/ctrlproxy.git] / lib / socks.h
1 /*
2         ctrlproxy: A modular IRC proxy
3         (c) 2005-2007 Jelmer Vernooij <jelmer@nl.linux.org>
4
5         This program is free software; you can redistribute it and/or modify
6         it under the terms of the GNU General Public License as published by
7         the Free Software Foundation; either version 3 of the License, or
8         (at your option) any later version.
9
10         This program is distributed in the hope that it will be useful,
11         but WITHOUT ANY WARRANTY; without even the implied warranty of
12         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13         GNU General Public License for more details.
14
15         You should have received a copy of the GNU General Public License
16         along with this program; if not, write to the Free Software
17         Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18 */
19
20 #ifndef __SOCKS_H__
21 #define __SOCKS_H__
22
23 #define SOCKS_VERSION 0x05
24
25 #define SOCKS_METHOD_NOAUTH                     0x00
26 #define SOCKS_METHOD_GSSAPI             0x01
27 #define SOCKS_METHOD_USERNAME_PW        0x02
28 #define SOCKS_METHOD_NOACCEPTABLE       0xFF
29
30 #define ATYP_IPV4                                       0x01
31 #define ATYP_FQDN                                       0x03
32 #define ATYP_IPV6                                       0x04
33
34 #define CMD_CONNECT                                     0x01
35 #define CMD_BIND                                        0x02
36 #define CMD_UDP_ASSOCIATE                       0x03
37
38 #define REP_OK                                          0x00
39 #define REP_GENERAL_FAILURE                     0x01
40 #define REP_NOT_ALLOWED                         0x02
41 #define REP_NET_UNREACHABLE                     0x03
42 #define REP_HOST_UNREACHABLE            0x04
43 #define REP_CONN_REFUSED                        0x05
44 #define REP_TTL_EXPIRED                         0x06
45 #define REP_CMD_NOT_SUPPORTED           0x07
46 #define REP_ATYP_NOT_SUPPORTED          0x08
47
48 #endif /* __SOCKS_H__ */