jingle-s5b/socks5-proto.h
author Gu1 <gu1@aeroxteam.fr>
Sun, 12 Sep 2010 18:32:57 +0200
changeset 168 f699f6b47613
permissions -rw-r--r--
S5B: SOCKSv5 implementation based on the one in the glib's git repository committer: Nicolas Cornu <nicolas.cornu@ensi-bourges.fr>
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
168
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     1
#ifndef __SOCKS5_PROTO_H__
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     2
#define __SOCKS5_PROTO_H__ 1
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     3
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     4
#define S5B_SOCKS5_ERROR s5b_proxy_error_quark()
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     5
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     6
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     7
typedef enum {
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     8
  S5B_SOCKS5_ERROR_HOST_UNREACHABLE,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
     9
  S5B_SOCKS5_ERROR_NETWORK_UNREACHABLE,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    10
  S5B_SOCKS5_ERROR_CONNECTION_REFUSED,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    11
  S5B_SOCKS5_ERROR_FAILED,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    12
  S5B_SOCKS5_ERROR_AUTH_FAILED,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    13
  S5B_SOCKS5_ERROR_NEED_AUTH,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    14
  S5B_SOCKS5_ERROR_NOT_ALLOWED
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    15
} S5bSocks5Error;
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    16
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    17
void
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    18
socks5_nego_with_server (GIOStream            *io_stream,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    19
                         gchar                *hostname,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    20
                         GCancellable         *cancellable,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    21
                         GAsyncReadyCallback   callback,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    22
                         gpointer              user_data);
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    23
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    24
GIOStream *
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    25
g_socks5_proxy_connect_finish (GAsyncResult *result,
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    26
                               GError      **error);
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    27
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    28
GQuark s5b_proxy_error_quark(void);
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    29
f699f6b47613 S5B: SOCKSv5 implementation based on the one in the glib's git repository
Gu1 <gu1@aeroxteam.fr>
parents:
diff changeset
    30
#endif