Dialogic Dialogic Global Call IP IP Phone User Manual


 
251
Dialogic Corporation
The second parameter element for nonstandard data uses one of the following two forms:
IPSET_TUNNELEDSIGNALMSG
IPPARM_TUNNELEDSIGNALMSG_NSDATA_OBJID
value = nonstandard data object ID string conforming to appropriate ASN.1 format
IPSET_TUNNELEDSIGNALMSG
IPPARM_TUNNELEDSIGNALMSG_NSDATA_H221NS
value = H.221 nonstandard data protocol information in an IP_H221NONSTANDARD
data structure
The following code example illustrates the process of composing the parameter block for a
tunneled signaling message.
GC_PARM_BLKP gcParmBlk = NULL;
IP_TUNNELPROTOCOL_ALTID tsmTpAltId;
IP_TUNNELPROTOCOL_OBJECTID tsmTpObjId;
char *pMsgContent = "00 11 22 33 44 55 44 33 33 66 66 55 77 22 11 11";
int asize = strlen(pMsgContent);
char *pTP_Oid = "0 0 17 931";
// Note that the Object Id string must be in the correct ASN.1 format.
char TP_AltID_Type[] = "Tunneled Protocol Alternate ID protocol type";
char TP_AltID_Variant[] = "Tunneled Protocol Alternate ID protocol variant";
char TP_AltID_SubId[] = "Tunneled Protocol Alternate ID subidentifier - User";
char *ptsmNSData_Data = "Tunneled Signaling Message Non Standard Data";
char *pTP_ObjID_Oid = "0 0 17 931";
// Note that the Object Id string must be in the correct ASN.1 format.
char TP_ObjID_SubId[] = "Tunneled Protocol Object ID subidentifier - User";
int bsize = strlen(TP_ObjID_SubId);
IP_H221NONSTANDARD tsmH221NS;
tsmH221NS.country_code = 91;
tsmH221NS.extension = 202;
tsmH221NS.manufacturer_code = 11;
INIT_IP_TUNNELPROTOCOL_ALTID(&tsmTpAltId);
strcpy(tsmTpAltId.protocolType, TP_AltID_Type);
tsmTpAltId.protocolTypeLength = strlen(TP_AltID_Type) + 1;
strcpy(tsmTpAltId.protocolVariant, TP_AltID_Variant);
tsmTpAltId.protocolVariantLength = strlen(TP_AltID_Variant) + 1;
strcpy(tsmTpAltId.subIdentifier, TP_AltID_SubId);
tsmTpAltId.subIdentifierLength = strlen(TP_AltID_SubId) + 1;
INIT_IP_TUNNELPROTOCOL_OBJECTID(&tsmTpObjId);
strcpy(tsmTpObjId.TunneledProtocol_Oid, pTP_ObjID_Oid);
tsmTpObjId.TunneledProtocol_OidLength = strlen(pTP_ObjID_Oid) + 1;
strcpy(tsmTpObjId.subIdentifier, TP_ObjID_SubId);
tsmTpObjId.subIdentifierLength = strlen(TP_ObjID_SubId) + 1;
choiceOfTSMProtocol = 1;
/* App decides whether to use the tunneled signaling message Protocol Object ID/ AltID */
choiceOfNSData = 1;
/* App decides which type of object identifier to use for TSM NS Data */
if (choiceOfTSMProtocol)
/* App decides the choice of the tunneled signaling msg protocol object identifier */
/* It cannot set both objid & alternate id */
{
gc_util_insert_parm_ref(&gcParmBlk,
IPSET_TUNNELEDSIGNALMSG,
IPPARM_TUNNELEDSIGNALMSG_ALTERNATEID,
(unsigned char)sizeof(IP_TUNNELPROTOCOL_ALTID),
&tsmTpAltId);