]>
Commit | Line | Data |
---|---|---|
9fafcd7b PM |
1 | #ifndef __NF_CONNTRACK_SIP_H__ |
2 | #define __NF_CONNTRACK_SIP_H__ | |
3 | #ifdef __KERNEL__ | |
4 | ||
5 | #define SIP_PORT 5060 | |
6 | #define SIP_TIMEOUT 3600 | |
7 | ||
8 | enum sip_header_pos { | |
9 | POS_REG_REQ_URI, | |
10 | POS_REQ_URI, | |
11 | POS_FROM, | |
12 | POS_TO, | |
13 | POS_VIA, | |
14 | POS_CONTACT, | |
15 | POS_CONTENT, | |
16 | POS_MEDIA, | |
17 | POS_OWNER_IP4, | |
18 | POS_CONNECTION_IP4, | |
19 | POS_OWNER_IP6, | |
20 | POS_CONNECTION_IP6, | |
21 | POS_SDP_HEADER, | |
22 | }; | |
23 | ||
3db05fea | 24 | extern unsigned int (*nf_nat_sip_hook)(struct sk_buff *skb, |
2a6cfb22 PM |
25 | const char **dptr, |
26 | unsigned int *datalen); | |
3db05fea | 27 | extern unsigned int (*nf_nat_sdp_hook)(struct sk_buff *skb, |
2a6cfb22 | 28 | const char **dptr, |
212440a7 PM |
29 | unsigned int *datalen, |
30 | struct nf_conntrack_expect *exp); | |
9fafcd7b | 31 | |
13f7d63c JE |
32 | extern int ct_sip_get_info(const struct nf_conn *ct, const char *dptr, |
33 | size_t dlen, unsigned int *matchoff, | |
34 | unsigned int *matchlen, enum sip_header_pos pos); | |
9fafcd7b PM |
35 | extern int ct_sip_lnlen(const char *line, const char *limit); |
36 | extern const char *ct_sip_search(const char *needle, const char *haystack, | |
37 | size_t needle_len, size_t haystack_len, | |
38 | int case_sensitive); | |
39 | #endif /* __KERNEL__ */ | |
40 | #endif /* __NF_CONNTRACK_SIP_H__ */ |