diff -r 763c26abd99d -r c42c167a2a5c jingle-s5b/s5b.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/jingle-s5b/s5b.h Wed Sep 01 20:34:23 2010 +0200 @@ -0,0 +1,62 @@ +#ifndef __JINGLESOCKS5_H__ +#define __JINGLESOCKS5_H__ 1 + +#include +#include + +#define NS_JINGLE_TRANSPORT_SOCKS5 "urn:xmpp:jingle:transports:s5b:1" + + +typedef enum { + JINGLE_S5B_DIRECT, + JINGLE_S5B_ASSISTED, + JINGLE_S5B_TUNNEL, + JINGLE_S5B_PROXY +} JingleS5BType; + +typedef enum { + JINGLE_S5B_TCP, + JINGLE_S5B_UDP +} JingleS5BModes; + +typedef struct { + JingleS5BModes mode; + + const gchar *sid; + + GSocketConnection *connection; + + GCancellable *cancelconnect; + + GSocketListener *listener; + + GSocketClient *client; + + /** + * @brief This is the list of the other client's candidates + * + * It should always be priority ordered. + */ + GSList *candidates; + + /** + * @brief This is our list of candidates + */ + GSList *ourcandidates; +} JingleS5B; + +typedef struct { + const gchar *cid; + + GInetAddress *host; + + const gchar *jid; + + guint16 port; + + guint64 priority; + + JingleS5BType type; +} S5BCandidate; + +#endif