t_msgbuilder.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef _MSGBUILDER_H
00035 #define _MSGBUILDER_H
00036
00037 #include "../../ip_addr.h"
00038 #include "dlg.h"
00039
00040
00041 #define CSEQ "CSeq: "
00042 #define CSEQ_LEN (sizeof(CSEQ)-1)
00043 #define TO "To: "
00044 #define TO_LEN (sizeof(TO)-1)
00045 #define CALLID "Call-ID: "
00046 #define CALLID_LEN (sizeof(CALLID)-1)
00047 #define FROM "From: "
00048 #define FROM_LEN (sizeof(FROM)-1)
00049 #define FROMTAG ";tag="
00050 #define FROMTAG_LEN (sizeof(FROMTAG)-1)
00051 #define TOTAG ";tag="
00052 #define TOTAG_LEN (sizeof(TOTAG)-1)
00053 #define LOCAL_MAXFWD_VALUE "70"
00054
00055 char *build_local(struct cell *Trans, unsigned int branch,
00056 unsigned int *len, char *method, int method_len, str *to);
00057
00058 char *build_uac_request( str msg_type, str dst, str from,
00059 str fromtag, int cseq, str callid, str headers,
00060 str body, int branch,
00061 struct cell *t, unsigned int *len);
00062
00063 char *build_uac_cancel(str *headers,str *body,struct cell *Trans,
00064 unsigned int branch, unsigned int *len);
00065
00066
00067
00068
00069
00070
00071 char *build_dlg_ack(struct sip_msg* rpl, struct cell *Trans, unsigned int branch,
00072 str* to, unsigned int *len);
00073
00074
00075
00076
00077
00078 char* build_uac_req(str* method, str* headers, str* body, dlg_t* dialog,
00079 int branch, struct cell *t, int* len);
00080
00081
00082 int t_calc_branch(struct cell *t,
00083 int b, char *branch, int *branch_len);
00084
00085
00086 char* print_callid_mini(char* target, str callid);
00087 char* print_cseq_mini(char* target, str* cseq, str* method);
00088
00089
00090 void check_hdrs_changes(struct sip_msg *msg);
00091
00092 #endif