1eXosip2 configuration API(3)      libeXosip2      eXosip2 configuration API(3)
2
3
4

NAME

6       eXosip2 configuration API -
7
8   Functions
9       int eXosip_init (void)
10       void eXosip_quit (void)
11       int eXosip_execute (void)
12       int eXosip_set_option (eXosip_option opt, const void *value)
13       int eXosip_lock (void)
14       int eXosip_unlock (void)
15       int _eXosip_get_srv_record (struct osip_srv_record *record, char
16           *domain, char *protocol)
17       int eXosip_listen_addr (int transport, const char *addr, int port, int
18           family, int secure)
19       int eXosip_set_socket (int transport, int socket, int port)
20       void eXosip_set_user_agent (const char *user_agent)
21       const char * eXosip_get_version (void)
22       void eXosip_enable_ipv6 (int ipv6_enable)
23       void eXosip_masquerade_contact (const char *public_address, int port)
24       int eXosip_find_free_port (int free_port, int transport)
25

Function Documentation

27   int eXosip_init (void)
28       Initiate the eXtented oSIP library.
29
30   void eXosip_quit (void)
31       Release ressource used by the eXtented oSIP library.
32
33   int eXosip_execute (void)
34       Process (non-threaded mode ONLY) eXosip events.
35
36   int eXosip_set_option (eXosip_option opt, const void * value)
37       Set eXosip options. See eXosip_option for available options.
38
39       Parameters:
40           opt option to configure.
41           value value for options.
42
43   int eXosip_lock (void)
44       Lock the eXtented oSIP library.
45
46   int eXosip_unlock (void)
47       UnLock the eXtented oSIP library.
48
49   int _eXosip_get_srv_record (struct osip_srv_record * record, char * domain,
50       char * protocol)
51       Ask for SRV record.
52
53       Parameters:
54           record result structure.
55           domain domain name for SRV record
56           protocol protocol to use
57
58   int eXosip_listen_addr (int transport, const char * addr, int port, int
59       family, int secure)
60       Listen on a specified socket.
61
62       Parameters:
63           transport IPPROTO_UDP for udp. (soon to come: TCP/TLS?)
64           addr the address to bind (NULL for all interface)
65           port the listening port. (0 for random port)
66           family the IP family (AF_INET or AF_INET6).
67           secure 0 for UDP or TCP, 1 for TLS (with TCP).
68
69   int eXosip_set_socket (int transport, int socket, int port)
70       Listen on a specified socket.
71
72       Parameters:
73           transport IPPROTO_UDP for udp. (soon to come: TCP/TLS?)
74           socket socket to use for listening to UDP sip messages.
75           port the listening port for masquerading.
76
77   void eXosip_set_user_agent (const char * user_agent)
78       Set the SIP User-Agent: header string.
79
80       Parameters:
81           user_agent the User-Agent header to insert in messages.
82
83   const char* eXosip_get_version (void)
84       Get the eXosip version as a sring
85
86   void eXosip_enable_ipv6 (int ipv6_enable)
87       Use IPv6 instead of IPv4.
88
89       Parameters:
90           ipv6_enable This paramter should be set to 1 to enable IPv6 mode.
91
92   void eXosip_masquerade_contact (const char * public_address, int port)
93       This method is used to replace contact address with the public address
94       of your NAT. The ip address should be retreived manually (fixed IP
95       address) or with STUN. This address will only be used when the remote
96       correspondant appears to be on an DIFFERENT LAN.
97
98       Parameters:
99           public_address the ip address.
100           port the port for masquerading.
101
102       If set to NULL, then the local ip address will be guessed automatically
103       (returns to default mode).
104
105   int eXosip_find_free_port (int free_port, int transport)
106       This method is used to find out an free IPPROTO_UDP or IPPROTO_TCP
107       port.
108
109       Parameters:
110           free_port initial port for search.
111           transport IPPROTO_UDP or IPPROTO_TCP protocol.
112
113Version 3.0.1                     30 Aug 2007     eXosip2 configuration API(3)
Impressum