Dialogic Dialogic Global Call IP IP Phone User Manual


 
Dialogic
®
Global Call IP Technology Guide — November 2007 179
Dialogic Corporation
IP-Specific Operations
4.9.2 Enabling Access to SIP Header Information
The ability to set and retrieve information from SIP message header fields is an optional feature
that can be enabled or disabled at the time the gc_Start( ) function is called.
The mandatory INIT_IP_VIRTBOARD( ) utility function populates the IP_VIRTBOARD
structure with default values. The default value of the sip_msginfo_mask field in the
IP_VIRTBOARD structure disables application access to all SIP message header fields. The value
IP_SIP_MSGINFO_ENABLE (possibly OR’ed with other defined mask values) must be set into
the sip_msginfo_mask field for each IPT board device on which the feature is to be enabled. The
following code snippet provides an example for two virtual boards:
INIT_IPCCLIB_START_DATA(&ipcclibstart, 2, ip_virtboard);
INIT_IP_VIRTBOARD(&ip_virtboard[0]);
INIT_IP_VIRTBOARD(&ip_virtboard[1]);
ip_virtboard[0].sip_msginfo_mask = IP_SIP_MSGINFO_ENABLE; /* override SIP message default */
ip_virtboard[1].sip_msginfo_mask = IP_SIP_MSGINFO_ENABLE; /* override SIP message default */
Setting the value IP_SIP_MSGINFO_ENABLE (possibly OR’ed with other bitmask values) in the
sip_msginfo_mask field enables overall set/retrieve access to SIP header fields for the virtual
board. Enabling and disabling access to individual SIP header fields is not supported.
Note: Features that are enabled or configured via the IP_VIRTBOARD structure cannot be disabled or
reconfigured once the library has been started. All items set in this data structure take effect when
the gc_Start( ) function is called and remain in effect until gc_Stop( ) is called when the
application exits.
4.9.3 Enabling Long Header Values
The ability to set and retrieve SIP message header fields that exceeds 255 bytes in length is an
optional feature that can be enabled at the time the gc_Start( ) function is called. The maximum
length for SIP header fields is configured in the IPCCLIB_START_DATA data structure and
applies to all virtual boards in the system.
The mandatory INIT_IPCCLIB_START_DATA( ) utility function populates the
IPCCLIB_START_DATA structure with default values. The default value of the
max_parm_data_size field in the IPCCLIB_START_DATA structure sets the maximum data length
for parameter data in a GC_PARM_BLK structure at 255 for backwards compatibility. If the
To display string IPSET_SIP_MSGINFO
IPPARM_TO_DISPLAY
IP_TO_DISPLAY_MAXLEN
To (complete header
field, with display string,
URI, and parameters)
IPSET_SIP_MSGINFO
IPPARM_TO
IP_TO_MAXLEN
Table 10. Field-Specific Parameters (Deprecated) for SIP Header Access (Continued)
Header Field Name Set ID and Parameter ID Maximum Data Length Define †
† The value for each listed parameter ID is a character array with the maximum size of the array (including the NULL) equal to
the corresponding maximum length define.
†† Directly setting the Call-ID header field using this parameter overrides any Call-ID value that is set using the
IPSET_CALLINFO / IPPARM_CALLID parameter.