WARNING: The online documentation has moved to https://docs.pjsip.org.

Visit the new documentation at https://docs.pjsip.org:

BLOG | DOCUMENTATION | GITHUB

Home --> Documentations --> PJSIP Reference

pjsip_rx_data Struct Reference

#include <sip_transport.h>

Data Fields

struct {
   pj_pool_t *   pool
 
   pjsip_transport *   transport
 
   void *   tp_data
 
   pjsip_rx_data_op_key   op_key
 
tp_info
 
struct {
   pj_time_val   timestamp
 
   char   packet [PJSIP_MAX_PKT_LEN]
 
   pj_uint32_t   zero
 
   pj_ssize_t   len
 
   pj_sockaddr   src_addr
 
   int   src_addr_len
 
   char   src_name [PJ_INET6_ADDRSTRLEN]
 
   int   src_port
 
pkt_info
 
struct {
   char *   msg_buf
 
   int   len
 
   pjsip_msg *   msg
 
   char *   info
 
   pjsip_cid_hdr *   cid
 
   pjsip_from_hdr *   from
 
   pjsip_to_hdr *   to
 
   pjsip_via_hdr *   via
 
   pjsip_cseq_hdr *   cseq
 
   pjsip_max_fwd_hdr *   max_fwd
 
   pjsip_route_hdr *   route
 
   pjsip_rr_hdr *   record_route
 
   pjsip_ctype_hdr *   ctype
 
   pjsip_clen_hdr *   clen
 
   pjsip_require_hdr *   require
 
   pjsip_supported_hdr *   supported
 
   pjsip_parser_err_report   parse_err
 
msg_info
 
struct {
   void *   mod_data [PJSIP_MAX_MODULE]
 
endpt_info
 

Detailed Description

Incoming message buffer. This structure keep all the information regarding the received message. This buffer lifetime is only very short, normally after the transaction has been called, this buffer will be deleted/recycled. So care must be taken when allocating storage from the pool of this buffer.

Forward declaration for receive data/buffer (sip_transport.h).

Field Documentation

◆ pool

pj_pool_t* pjsip_rx_data::pool

Memory pool for this buffer.

◆ transport

pjsip_transport* pjsip_rx_data::transport

The transport object which received this packet.

◆ tp_data

void* pjsip_rx_data::tp_data

Other transport specific data to be attached to this buffer.

◆ op_key

pjsip_rx_data_op_key pjsip_rx_data::op_key

Ioqueue key.

◆ 

struct { ... } pjsip_rx_data::tp_info

tp_info is part of rdata that remains static for the duration of the buffer. It is initialized when the buffer was created by transport.

◆ timestamp

pj_time_val pjsip_rx_data::timestamp

Time when the message was received.

◆ packet

char pjsip_rx_data::packet[PJSIP_MAX_PKT_LEN]

Pointer to the original packet.

◆ zero

pj_uint32_t pjsip_rx_data::zero

Zero termination for the packet.

◆ len [1/2]

pj_ssize_t pjsip_rx_data::len

The length of the packet received.

◆ src_addr

pj_sockaddr pjsip_rx_data::src_addr

The source address from which the packet was received.

◆ src_addr_len

int pjsip_rx_data::src_addr_len

The length of the source address.

◆ src_name

char pjsip_rx_data::src_name[PJ_INET6_ADDRSTRLEN]

The IP source address string (NULL terminated).

◆ src_port

int pjsip_rx_data::src_port

The IP source port number.

◆ 

struct { ... } pjsip_rx_data::pkt_info

pkt_info is initialized by transport when it receives an incoming packet.

◆ msg_buf

char* pjsip_rx_data::msg_buf

Start of msg buffer.

◆ len [2/2]

int pjsip_rx_data::len

Length fo message.

◆ msg

pjsip_msg* pjsip_rx_data::msg

The parsed message, if any.

◆ info

char* pjsip_rx_data::info

Short description about the message. Application should use pjsip_rx_data_get_info() instead.

◆ cid

pjsip_cid_hdr* pjsip_rx_data::cid

The Call-ID header as found in the message.

◆ from

pjsip_from_hdr* pjsip_rx_data::from

The From header as found in the message.

◆ to

pjsip_to_hdr* pjsip_rx_data::to

The To header as found in the message.

◆ via

pjsip_via_hdr* pjsip_rx_data::via

The topmost Via header as found in the message.

◆ cseq

pjsip_cseq_hdr* pjsip_rx_data::cseq

The CSeq header as found in the message.

◆ max_fwd

pjsip_max_fwd_hdr* pjsip_rx_data::max_fwd

Max forwards header.

◆ route

pjsip_route_hdr* pjsip_rx_data::route

The first route header.

◆ record_route

pjsip_rr_hdr* pjsip_rx_data::record_route

The first record-route header.

◆ ctype

pjsip_ctype_hdr* pjsip_rx_data::ctype

Content-type header.

◆ clen

pjsip_clen_hdr* pjsip_rx_data::clen

Content-length header.

◆ require

pjsip_require_hdr* pjsip_rx_data::require

"Require" header containing aggregates of all Require headers found in the message, or NULL.

◆ supported

pjsip_supported_hdr* pjsip_rx_data::supported

"Supported" header containing aggregates of all Supported headers found in the message, or NULL.

◆ parse_err

pjsip_parser_err_report pjsip_rx_data::parse_err

The list of error generated by the parser when parsing this message.

◆ 

struct { ... } pjsip_rx_data::msg_info

msg_info is initialized by transport mgr (tpmgr) before this buffer is passed to endpoint.

◆ mod_data

void* pjsip_rx_data::mod_data[PJSIP_MAX_MODULE]

Data attached by modules to this message.

◆ 

struct { ... } pjsip_rx_data::endpt_info

endpt_info is initialized by endpoint after this buffer reaches endpoint.


The documentation for this struct was generated from the following file:

 


PJSIP Open Source, high performance, small footprint, and very very portable SIP stack
Copyright (C) 2006-2008 Teluu Inc.