亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? stun_msg.h

?? 一個開源的sip源代碼
?? H
?? 第 1 頁 / 共 4 頁
字號:
PJ_DECL(void) pj_stun_create_key(pj_pool_t *pool,
				 pj_str_t *key,
				 const pj_str_t *realm,
				 const pj_str_t *username,
				 const pj_str_t *passwd);



/**
 * Check that the PDU is potentially a valid STUN message. This function
 * is useful when application needs to multiplex STUN packets with other
 * application traffic. When this function returns PJ_SUCCESS, there is a
 * big chance that the packet is a STUN packet.
 *
 * Note that we cannot be sure that the PDU is a really valid STUN message 
 * until we actually parse the PDU.
 *
 * @param pdu		The packet buffer.
 * @param pdu_len	The length of the packet buffer.
 * @param options	Additional options to be applied in the checking,
 *			which can be taken from pj_stun_decode_options. One 
 *			of the useful option is PJ_STUN_IS_DATAGRAM which 
 *			means that the pdu represents a whole STUN packet.
 *
 * @return		PJ_SUCCESS if the PDU is a potentially valid STUN
 *			message.
 */
PJ_DECL(pj_status_t) pj_stun_msg_check(const pj_uint8_t *pdu, 
				       unsigned pdu_len, unsigned options);


/**
 * Decode incoming packet into STUN message.
 *
 * @param pool		Pool to allocate the message.
 * @param pdu		The incoming packet to be parsed.
 * @param pdu_len	The length of the incoming packet.
 * @param options	Parsing flags, according to pj_stun_decode_options.
 * @param p_msg		Pointer to receive the parsed message.
 * @param p_parsed_len	Optional pointer to receive how many bytes have
 *			been parsed for the STUN message. This is useful
 *			when the packet is received over stream oriented
 *			transport.
 * @param p_response	Optional pointer to receive an instance of response
 *			message, if one can be created. If the packet being
 *			decoded is a request message, and it contains error,
 *			and a response can be created, then the STUN 
 *			response message will be returned on this argument.
 *
 * @return		PJ_SUCCESS if a STUN message has been successfully
 *			decoded.
 */
PJ_DECL(pj_status_t) pj_stun_msg_decode(pj_pool_t *pool,
				        const pj_uint8_t *pdu,
				        unsigned pdu_len,
				        unsigned options,
				        pj_stun_msg **p_msg,
					unsigned *p_parsed_len,
				        pj_stun_msg **p_response);

/**
 * Dump STUN message to a printable string output.
 *
 * @param msg		The STUN message
 * @param buffer	Buffer where the printable string output will
 *			be printed on.
 * @param length	Specify the maximum length of the buffer.
 * @param printed_len	Optional pointer, which on output will be filled
 *			up with the actual length of the output string.
 *
 * @return		The message string output.
 */
#if PJ_LOG_MAX_LEVEL > 0
PJ_DECL(char*) pj_stun_msg_dump(const pj_stun_msg *msg,
			        char *buffer,
			        unsigned length,
				unsigned *printed_len);
#else
#   define pj_stun_msg_dump(msg, buf, length, printed_len)  ""
#endif


/**
 * Find STUN attribute in the STUN message, starting from the specified
 * index.
 *
 * @param msg		The STUN message.
 * @param attr_type	The attribute type to be found, from pj_stun_attr_type.
 * @param start_index	The start index of the attribute in the message.
 *			Specify zero to start searching from the first
 *			attribute.
 *
 * @return		The attribute instance, or NULL if it cannot be
 *			found.
 */
PJ_DECL(pj_stun_attr_hdr*) pj_stun_msg_find_attr(const pj_stun_msg *msg,
						 int attr_type,
						 unsigned start_index);


/**
 * Create a generic STUN IP address attribute. The \a addr_len and
 * \a addr parameters specify whether the address is IPv4 or IPv4
 * address.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param xor_ed	If non-zero, the port and address will be XOR-ed
 *			with magic, to make the XOR-MAPPED-ADDRESS attribute.
 * @param addr		A pj_sockaddr_in or pj_sockaddr_in6 structure.
 * @param addr_len	Length of \a addr parameter.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_sockaddr_attr_create(pj_pool_t *pool,
						int attr_type, 
						pj_bool_t xor_ed,
						const pj_sockaddr_t *addr,
						unsigned addr_len,
						pj_stun_sockaddr_attr **p_attr);


/**
 * Create and add generic STUN IP address attribute to a STUN message.
 * The \a addr_len and \a addr parameters specify whether the address is 
 * IPv4 or IPv4 address.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param xor_ed	If non-zero, the port and address will be XOR-ed
 *			with magic, to make the XOR-MAPPED-ADDRESS attribute.
 * @param addr		A pj_sockaddr_in or pj_sockaddr_in6 structure.
 * @param addr_len	Length of \a addr parameter.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_sockaddr_attr(pj_pool_t *pool,
						  pj_stun_msg *msg,
						  int attr_type, 
						  pj_bool_t xor_ed,
						  const pj_sockaddr_t *addr,
						  unsigned addr_len);

/**
 * Create a STUN generic string attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		The string value to be assigned to the attribute.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_string_attr_create(pj_pool_t *pool,
					        int attr_type,
					        const pj_str_t *value,
					        pj_stun_string_attr **p_attr);

/**
 * Create and add STUN generic string attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		The string value to be assigned to the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_string_attr(pj_pool_t *pool,
						 pj_stun_msg *msg,
						 int attr_type,
						 const pj_str_t *value);

/**
 * Create a STUN generic 32bit value attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		The 32bit value to be assigned to the attribute.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_uint_attr_create(pj_pool_t *pool,
					      int attr_type,
					      pj_uint32_t value,
					      pj_stun_uint_attr **p_attr);

/**
 * Create and add STUN generic 32bit value attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		The 32bit value to be assigned to the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_uint_attr(pj_pool_t *pool,
					       pj_stun_msg *msg,
					       int attr_type,
					       pj_uint32_t value);


/**
 * Create a STUN generic 64bit value attribute.
 *
 * @param pool		Pool to allocate memory from.
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		Optional value to be assigned.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DEF(pj_status_t)  pj_stun_uint64_attr_create(pj_pool_t *pool,
					        int attr_type,
					        const pj_timestamp *value,
					        pj_stun_uint64_attr **p_attr);


/**
 *  Create and add STUN generic 64bit value attribute to the message. 
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message
 * @param attr_type	Attribute type, from #pj_stun_attr_type.
 * @param value		The 64bit value to be assigned to the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t)  pj_stun_msg_add_uint64_attr(pj_pool_t *pool,
					          pj_stun_msg *msg,
					          int attr_type,
					          const pj_timestamp *value);

/**
 * Create a STUN MESSAGE-INTEGRITY attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msgint_attr_create(pj_pool_t *pool,
						pj_stun_msgint_attr **p_attr);

/** 
 * Create and add STUN MESSAGE-INTEGRITY attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_msgint_attr(pj_pool_t *pool,
						 pj_stun_msg *msg);

/**
 * Create a STUN ERROR-CODE attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param err_code	STUN error code.
 * @param err_reason	Optional STUN error reason. If NULL is given, the
 *			standard error reason will be given.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_errcode_attr_create(pj_pool_t *pool,
						int err_code,
						const pj_str_t *err_reason,
						pj_stun_errcode_attr **p_attr);


/**
 * Create and add STUN ERROR-CODE attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN mesage.
 * @param err_code	STUN error code.
 * @param err_reason	Optional STUN error reason. If NULL is given, the
 *			standard error reason will be given.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_errcode_attr(pj_pool_t *pool,
						  pj_stun_msg *msg,
						  int err_code,
						  const pj_str_t *err_reason);

/**
 * Create instance of STUN UNKNOWN-ATTRIBUTES attribute and copy the
 * unknown attribute array to the attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_cnt	Number of attributes in the array (can be zero).
 * @param attr		Optional array of attributes.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_unknown_attr_create(pj_pool_t *pool,
						unsigned attr_cnt,
						const pj_uint16_t attr[],
						pj_stun_unknown_attr **p_attr);

/**
 * Create and add STUN UNKNOWN-ATTRIBUTES attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message.
 * @param attr_cnt	Number of attributes in the array (can be zero).
 * @param attr		Optional array of attributes.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_unknown_attr(pj_pool_t *pool,
						  pj_stun_msg *msg,
						  unsigned attr_cnt,
						  const pj_uint16_t attr[]);

/**
 * Create STUN binary attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_type	The attribute type, from #pj_stun_attr_type.
 * @param data		Data to be coped to the attribute, or NULL
 *			if no data to be copied now.
 * @param length	Length of data, or zero if no data is to be
 *			copied now.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_binary_attr_create(pj_pool_t *pool,
					        int attr_type,
					        const pj_uint8_t *data,
					        unsigned length,
					        pj_stun_binary_attr **p_attr);

/**
 * Create STUN binary attribute and add the attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message.
 * @param attr_type	The attribute type, from #pj_stun_attr_type.
 * @param data		Data to be coped to the attribute, or NULL
 *			if no data to be copied now.
 * @param length	Length of data, or zero if no data is to be
 *			copied now.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_binary_attr(pj_pool_t *pool,
						 pj_stun_msg *msg,
						 int attr_type,
						 const pj_uint8_t *data,
						 unsigned length);

/**
 * Create STUN empty attribute.
 *
 * @param pool		The pool to allocate memory from.
 * @param attr_type	The attribute type, from #pj_stun_attr_type.
 * @param p_attr	Pointer to receive the attribute.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_empty_attr_create(pj_pool_t *pool,
					       int attr_type,
					       pj_stun_empty_attr **p_attr);

/**
 * Create STUN empty attribute and add the attribute to the message.
 *
 * @param pool		The pool to allocate memory from.
 * @param msg		The STUN message.
 * @param attr_type	The attribute type, from #pj_stun_attr_type.
 *
 * @return		PJ_SUCCESS on success or the appropriate error code.
 */
PJ_DECL(pj_status_t) pj_stun_msg_add_empty_attr(pj_pool_t *pool,
						pj_stun_msg *msg,
						int attr_type);

/**
 * @}
 */


PJ_END_DECL


#endif	/* __PJNATH_STUN_MSG_H__ */

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
粉嫩久久99精品久久久久久夜| 亚洲视频图片小说| 日日嗨av一区二区三区四区| 色94色欧美sute亚洲线路二| 亚洲黄色录像片| 欧美日韩一区二区在线观看视频 | 亚洲综合视频在线观看| 在线观看av不卡| 日日夜夜免费精品| 日韩免费高清av| 高清在线观看日韩| 中文字幕中文字幕在线一区 | 99国产精品国产精品毛片| 亚洲图片欧美激情| 欧美羞羞免费网站| 精品一区二区免费在线观看| 久久青草国产手机看片福利盒子| 大桥未久av一区二区三区中文| 18成人在线观看| 91精品欧美一区二区三区综合在 | 水蜜桃久久夜色精品一区的特点| 正在播放亚洲一区| 成人激情视频网站| 午夜欧美大尺度福利影院在线看 | 欧美国产成人精品| 欧美午夜一区二区三区 | 日日夜夜精品视频免费| 久久蜜臀精品av| 色香蕉成人二区免费| 日韩中文欧美在线| 国产精品你懂的| 欧美绝品在线观看成人午夜影视| 麻豆一区二区三区| 亚洲精品少妇30p| 26uuu国产电影一区二区| 99精品久久免费看蜜臀剧情介绍| 天天影视涩香欲综合网| 国产精品美女久久久久久久久| 欧美色爱综合网| 国产v综合v亚洲欧| 日本va欧美va瓶| 国产精品久久久久四虎| 欧美一区二区高清| 色综合久久中文综合久久97 | 国产精品视频一区二区三区不卡| 欧美日韩一区三区| 99久久精品免费| 国产一区美女在线| 日韩在线一区二区| 亚洲欧美激情视频在线观看一区二区三区| 欧美电影免费观看高清完整版在线观看 | 91福利区一区二区三区| 国产精品小仙女| 天天色综合天天| 一区二区三区不卡在线观看 | 一个色综合av| 中文一区在线播放| 久久这里只有精品视频网| 欧美男生操女生| 色噜噜夜夜夜综合网| 福利电影一区二区三区| 经典一区二区三区| 天堂成人国产精品一区| 亚洲电影一区二区三区| 亚洲日本一区二区| 日本一区二区三区在线观看| 精品国产sm最大网站免费看| 欧美日韩aaa| 欧美日韩精品一区二区三区| 91久久精品一区二区三| 91丨porny丨首页| www.久久精品| 97久久精品人人做人人爽| 成人av午夜影院| 国产99久久久国产精品潘金网站| 精品一区二区三区日韩| 国产一区二区三区| 国产精品996| 国产福利精品导航| 国产精品亚洲第一区在线暖暖韩国| 玖玖九九国产精品| 精品一二三四区| 国产中文字幕一区| 国产一区二区在线免费观看| 国产精品自在在线| 国产91露脸合集magnet| 成人一区在线观看| 色综合激情五月| 欧美亚洲丝袜传媒另类| 欧美三级韩国三级日本三斤| 欧美乱熟臀69xxxxxx| 日韩一区二区视频在线观看| 日韩欧美中文一区二区| 久久在线免费观看| 国产精品久久久久久久久快鸭 | 亚洲精品一卡二卡| 夜夜嗨av一区二区三区中文字幕 | 国产欧美精品国产国产专区| 中文字幕在线播放不卡一区| 亚洲日本乱码在线观看| 一区二区三区免费在线观看| 婷婷开心久久网| 国产美女精品一区二区三区| 不卡一区中文字幕| 欧美日韩一级二级三级| 精品少妇一区二区三区在线播放| 久久久久成人黄色影片| 中文字幕在线一区| 亚洲一区二区精品久久av| 麻豆一区二区在线| 99精品欧美一区二区三区综合在线| 欧美性生交片4| 久久综合色天天久久综合图片| 17c精品麻豆一区二区免费| 日日摸夜夜添夜夜添国产精品| 国产精品一区二区无线| 欧美色综合网站| 久久久久久久久久久久电影| 亚洲制服丝袜一区| 国产毛片精品国产一区二区三区| 在线一区二区三区做爰视频网站| 精品剧情在线观看| 亚洲一区精品在线| 国产91丝袜在线播放九色| 欧美日本精品一区二区三区| 国产精品毛片久久久久久久| 日韩成人一区二区| 91在线一区二区| 日韩精品在线一区二区| 一区二区三区成人| 成人综合激情网| 日韩精品一区二区在线| 亚洲在线观看免费视频| 国产精品一区二区无线| 欧美一级午夜免费电影| 亚洲激情第一区| 成人福利视频在线| 日韩精品资源二区在线| 亚洲一区二区三区三| 成人黄色在线网站| 美日韩一级片在线观看| 美日韩一区二区三区| 日韩在线卡一卡二| 国产精品中文欧美| 色视频一区二区| 久久久99免费| 性久久久久久久久久久久| av在线免费不卡| 国模大尺度一区二区三区| 亚洲欧美视频一区| 亚洲精选视频在线| 国产毛片精品国产一区二区三区| 欧美在线播放高清精品| 国产精品久久久久久亚洲毛片| 日本成人在线一区| 色嗨嗨av一区二区三区| 国产天堂亚洲国产碰碰| 国产综合色视频| 日韩欧美国产精品一区| 日本欧洲一区二区| 欧美一区二区三区婷婷月色| 夜夜精品视频一区二区| 色综合久久久久| 一区二区高清免费观看影视大全| youjizz久久| 亚洲丝袜美腿综合| 99re成人精品视频| 亚洲欧美国产三级| 91成人免费网站| 一区二区三区日本| 欧美日韩日日骚| 视频一区视频二区中文| 欧美日韩国产色站一区二区三区| 亚洲午夜视频在线观看| 欧美性三三影院| 偷拍一区二区三区| 宅男噜噜噜66一区二区66| 日日夜夜一区二区| 日韩精品中文字幕在线不卡尤物| 精品一区二区国语对白| 国产日韩欧美精品一区| av电影天堂一区二区在线| 一区二区三区在线视频观看| 色婷婷综合久久久| 亚洲一区二区三区四区在线观看| 欧美高清一级片在线| 久久99精品久久只有精品| 国产日韩欧美精品电影三级在线| 成人a级免费电影| 亚洲精品美腿丝袜| 欧美高清视频在线高清观看mv色露露十八| 天堂va蜜桃一区二区三区 | 91.麻豆视频| 精品无码三级在线观看视频| 久久久www成人免费毛片麻豆| 99久久精品99国产精品| 视频一区免费在线观看| 久久久久亚洲综合| 色呦呦网站一区| 麻豆精品在线看|