2005-02-09 22:31:40 +00:00
|
|
|
# inap.cnf
|
|
|
|
# inap conformation file
|
2005-02-09 23:55:14 +00:00
|
|
|
# $Id$
|
2005-02-09 22:31:40 +00:00
|
|
|
|
2010-03-01 07:27:35 +00:00
|
|
|
#.IMPORT ../dap/dap-exp.cnf
|
|
|
|
#.IMPORT ../dsp/dsp-exp.cnf
|
|
|
|
|
2005-02-09 22:31:40 +00:00
|
|
|
#.EXPORTS
|
2007-07-04 13:27:44 +00:00
|
|
|
BothwayThroughConnectionInd
|
|
|
|
CallingPartysCategory
|
|
|
|
CriticalityType
|
|
|
|
Duration
|
|
|
|
HighLayerCompatibility
|
|
|
|
Integer4
|
|
|
|
Interval
|
|
|
|
LegID
|
|
|
|
MiscCallInfo
|
|
|
|
RedirectionInformation
|
|
|
|
ServiceKey
|
2005-02-09 22:31:40 +00:00
|
|
|
|
2007-06-01 19:52:26 +00:00
|
|
|
#.NO_EMIT
|
2005-02-09 22:31:40 +00:00
|
|
|
|
2008-07-28 14:26:04 +00:00
|
|
|
#.OMIT_ASSIGNMENT
|
|
|
|
# Removed as they are giving 'defined but not used' warnings currently.
|
|
|
|
Priority
|
2010-03-01 09:30:45 +00:00
|
|
|
RejectProblem
|
2008-07-28 14:26:04 +00:00
|
|
|
#.END
|
|
|
|
|
2005-02-09 22:31:40 +00:00
|
|
|
#.TYPE_RENAME
|
2008-07-28 14:26:04 +00:00
|
|
|
ReturnResult/result/result ResultArgument
|
2005-02-09 22:31:40 +00:00
|
|
|
|
|
|
|
#.FIELD_RENAME
|
2008-07-28 14:26:04 +00:00
|
|
|
Invoke/linkedId/present linkedIdPresent
|
|
|
|
Reject/problem/invoke invokeProblem
|
|
|
|
Reject/problem/returnError returnErrorProblem
|
|
|
|
ReturnResult/result/result resultArgument
|
|
|
|
Reject/problem/returnResult problemReturnResult
|
|
|
|
|
|
|
|
#.OMIT_ASSIGNMENT Remote-Operations-Information-Objects
|
|
|
|
Bind
|
|
|
|
Unbind
|
|
|
|
#.END
|
|
|
|
|
|
|
|
#.PDU_NEW
|
|
|
|
ERROR.&ParameterType
|
|
|
|
OPERATION.&ArgumentType
|
|
|
|
OPERATION.&ResultType
|
2005-02-09 22:31:40 +00:00
|
|
|
|
2005-11-30 20:14:18 +00:00
|
|
|
#.PDU
|
|
|
|
|
2007-08-06 12:16:20 +00:00
|
|
|
# This table creates the value_sting to name Inap operation codes and errors
|
|
|
|
# in file packet-inap-table.c which is included in the template file
|
|
|
|
#
|
|
|
|
#.TABLE_HDR
|
|
|
|
/* INAP OPERATIONS */
|
|
|
|
const value_string inap_opr_code_strings[] = {
|
|
|
|
#.TABLE_BODY OPERATION.&operationCode
|
|
|
|
{ %(&operationCode)-40s, "%(_ident)s" },
|
|
|
|
#.TABLE_FTR
|
|
|
|
{ 0, NULL }
|
|
|
|
};
|
|
|
|
#.END
|
|
|
|
|
|
|
|
#.TABLE_HDR
|
|
|
|
/* INAP ERRORS */
|
|
|
|
static const value_string inap_err_code_string_vals[] = {
|
2007-10-31 23:11:15 +00:00
|
|
|
#.TABLE_BODY ERROR.&errorCode
|
2012-03-26 19:41:23 +00:00
|
|
|
{ %(&errorCode)-40s, "%(_ident)s" },
|
2007-08-06 12:16:20 +00:00
|
|
|
#.TABLE_FTR
|
|
|
|
{ 0, NULL }
|
|
|
|
};
|
|
|
|
#.END
|
|
|
|
|
2008-07-28 14:26:04 +00:00
|
|
|
# This table creates the switch() to branch on Camel operation codes and errors
|
|
|
|
# in file packet-inap-table2.c which is included in the template file
|
|
|
|
#
|
|
|
|
#.TABLE2_HDR
|
|
|
|
static int dissect_invokeData(proto_tree *tree, tvbuff_t *tvb, int offset, asn1_ctx_t *actx) {
|
|
|
|
proto_item *cause;
|
|
|
|
|
|
|
|
switch(opcode){
|
|
|
|
#.TABLE2_BODY OPERATION.&ArgumentType
|
|
|
|
case %(&operationCode)s: /* %(_ident)s */
|
|
|
|
offset= %(_argument_pdu)s(tvb, actx->pinfo , tree);
|
|
|
|
break;
|
|
|
|
#.TABLE2_FTR
|
2012-03-26 19:41:23 +00:00
|
|
|
default:
|
|
|
|
cause=proto_tree_add_text(tree, tvb, offset, -1, "Unknown invokeData blob");
|
|
|
|
proto_item_set_expert_flags(cause, PI_MALFORMED, PI_WARN);
|
|
|
|
expert_add_info_format(actx->pinfo, cause, PI_MALFORMED, PI_WARN, "Unknown invokeData %d",opcode);
|
|
|
|
/* todo call the asn.1 dissector */
|
|
|
|
break;
|
2008-07-28 14:26:04 +00:00
|
|
|
}
|
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
#.END
|
|
|
|
#.TABLE2_HDR
|
|
|
|
static int dissect_returnResultData(proto_tree *tree, tvbuff_t *tvb, int offset,asn1_ctx_t *actx) {
|
|
|
|
proto_item *cause;
|
|
|
|
|
|
|
|
switch(opcode){
|
|
|
|
#.TABLE2_BODY OPERATION.&ResultType
|
|
|
|
case %(&operationCode)s: /* %(_ident)s */
|
|
|
|
offset= %(_result_pdu)s(tvb, actx->pinfo , tree);
|
|
|
|
break;
|
|
|
|
#.TABLE2_FTR
|
|
|
|
default:
|
|
|
|
cause=proto_tree_add_text(tree, tvb, offset, -1, "Unknown returnResultData blob");
|
|
|
|
proto_item_set_expert_flags(cause, PI_MALFORMED, PI_WARN);
|
|
|
|
expert_add_info_format(actx->pinfo, cause, PI_MALFORMED, PI_WARN, "Unknown returnResultData %d",opcode);
|
|
|
|
}
|
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
#.END
|
|
|
|
#.TABLE2_HDR
|
|
|
|
static int dissect_returnErrorData(proto_tree *tree, tvbuff_t *tvb, int offset,asn1_ctx_t *actx) {
|
|
|
|
proto_item *cause;
|
|
|
|
|
|
|
|
switch(errorCode) {
|
|
|
|
#.TABLE2_BODY ERROR.&ParameterType
|
|
|
|
case %(&errorCode)s: /* %(_ident)s */
|
|
|
|
%(_parameter_pdu)s(tvb, actx->pinfo , tree);
|
|
|
|
break;
|
|
|
|
#.TABLE2_FTR
|
|
|
|
default:
|
|
|
|
cause=proto_tree_add_text(tree, tvb, offset, -1, "Unknown returnErrorData blob");
|
|
|
|
proto_item_set_expert_flags(cause, PI_MALFORMED, PI_WARN);
|
|
|
|
expert_add_info_format(actx->pinfo, cause, PI_MALFORMED, PI_WARN, "Unknown returnErrorData %d",errorCode);
|
|
|
|
}
|
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
#.END
|
|
|
|
|
2007-08-06 12:16:20 +00:00
|
|
|
# Create a table of opcode and corresponding args and res
|
|
|
|
#.TABLE11_HDR
|
|
|
|
typedef struct _inap_op_t {
|
|
|
|
gint32 opcode;
|
|
|
|
new_dissector_t arg_pdu;
|
|
|
|
new_dissector_t res_pdu;
|
|
|
|
} inap_op_t;
|
|
|
|
|
|
|
|
static const inap_op_t inap_op_tab[] = {
|
|
|
|
#.TABLE11_BODY OPERATION.&operationCode
|
|
|
|
/* %(_name)-31s */ { %(&operationCode)-40s, %(_argument_pdu)-45s, %(_result_pdu)s },
|
|
|
|
#.TABLE11_FTR
|
|
|
|
};
|
|
|
|
#.END
|
|
|
|
|
2007-10-31 23:11:15 +00:00
|
|
|
#.TABLE11_HDR
|
2008-07-28 14:26:04 +00:00
|
|
|
typedef struct _inap_err_t {
|
2007-10-31 23:11:15 +00:00
|
|
|
gint32 errcode;
|
|
|
|
new_dissector_t err_pdu;
|
2008-07-28 14:26:04 +00:00
|
|
|
} inap_err_t;
|
2007-10-31 23:11:15 +00:00
|
|
|
|
2008-07-28 14:26:04 +00:00
|
|
|
static const inap_err_t inap_err_tab[] = {
|
2007-10-31 23:11:15 +00:00
|
|
|
#.TABLE11_BODY ERROR.&errorCode
|
|
|
|
/* %(_name)-30s */ { %(&errorCode)4s, %(_parameter_pdu)s },
|
|
|
|
#.TABLE11_FTR
|
|
|
|
};
|
|
|
|
#.END
|
2007-08-06 12:16:20 +00:00
|
|
|
|
2008-07-28 14:26:04 +00:00
|
|
|
# ROS stuff here XXX change when TCAP is redone.
|
|
|
|
|
|
|
|
#.FN_BODY Code/local VAL_PTR = &opcode
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
if (inap_opcode_type == INAP_OPCODE_RETURN_ERROR){
|
2012-03-26 19:41:23 +00:00
|
|
|
errorCode = opcode;
|
|
|
|
col_append_str(actx->pinfo->cinfo, COL_INFO,
|
2008-07-28 14:26:04 +00:00
|
|
|
val_to_str(errorCode, inap_err_code_string_vals, "Unknown INAP error (%%u)"));
|
|
|
|
col_append_str(actx->pinfo->cinfo, COL_INFO, " ");
|
|
|
|
col_set_fence(actx->pinfo->cinfo, COL_INFO);
|
|
|
|
}else{
|
2012-03-26 19:41:23 +00:00
|
|
|
col_append_str(actx->pinfo->cinfo, COL_INFO,
|
2008-07-28 14:26:04 +00:00
|
|
|
val_to_str(opcode, inap_opr_code_strings, "Unknown INAP (%%u)"));
|
|
|
|
col_append_str(actx->pinfo->cinfo, COL_INFO, " ");
|
|
|
|
col_set_fence(actx->pinfo->cinfo, COL_INFO);
|
|
|
|
}
|
|
|
|
|
|
|
|
#.FN_HDR Invoke
|
|
|
|
inap_opcode_type=INAP_OPCODE_INVOKE;
|
|
|
|
|
|
|
|
#.FN_HDR ReturnResult
|
|
|
|
inap_opcode_type=INAP_OPCODE_RETURN_RESULT;
|
|
|
|
|
|
|
|
#.FN_HDR ReturnError
|
|
|
|
inap_opcode_type=INAP_OPCODE_RETURN_ERROR;
|
|
|
|
|
|
|
|
#.FN_HDR Reject
|
|
|
|
inap_opcode_type=INAP_OPCODE_REJECT;
|
|
|
|
|
|
|
|
#.FN_BODY Invoke/argument
|
|
|
|
offset = dissect_invokeData(tree, tvb, offset, actx);
|
|
|
|
|
|
|
|
#.FN_BODY ReturnResult/result/result
|
|
|
|
offset = dissect_returnResultData(tree, tvb, offset, actx);
|
|
|
|
|
|
|
|
#.FN_BODY ReturnError/parameter
|
|
|
|
offset = dissect_returnErrorData(tree, tvb, offset, actx);
|
|
|
|
|
|
|
|
# END ROS
|
|
|
|
|
|
|
|
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY TriggerData/triggerPar
|
2007-06-03 19:58:59 +00:00
|
|
|
/* FIX ME */
|
|
|
|
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY ScriptEventArg/uIScriptResult
|
2007-06-03 19:58:59 +00:00
|
|
|
/* FIX ME */
|
|
|
|
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY ScriptCloseArg/uIScriptSpecificInfo
|
2007-06-03 19:58:59 +00:00
|
|
|
/* FIX ME */
|
|
|
|
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY ScriptInformationArg/uIScriptSpecificInfo
|
2007-06-03 19:58:59 +00:00
|
|
|
/* FIX ME */
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY ScriptRunArg/uIScriptSpecificInfo
|
2007-06-03 19:58:59 +00:00
|
|
|
/* FIX ME */
|
|
|
|
|
2011-04-05 15:43:15 +00:00
|
|
|
#.FN_HDR ExtensionField
|
2011-04-05 15:49:56 +00:00
|
|
|
obj_id = NULL;
|
2011-04-05 15:43:15 +00:00
|
|
|
|
|
|
|
#.FN_PARS Code/global FN_VARIANT = _str VAL_PTR = &obj_id
|
2007-06-03 19:58:59 +00:00
|
|
|
|
2007-06-04 14:41:38 +00:00
|
|
|
#.FN_BODY ExtensionField/value
|
2011-04-02 09:18:18 +00:00
|
|
|
proto_tree_add_text(tree, tvb, offset, -1, "Extension Data");
|
|
|
|
if (obj_id){
|
|
|
|
offset=call_ber_oid_callback(obj_id, tvb, offset, actx->pinfo, tree);
|
|
|
|
}else{
|
|
|
|
call_dissector(data_handle, tvb, actx->pinfo, tree);
|
|
|
|
offset = tvb_length_remaining(tvb,offset);
|
|
|
|
}
|
2007-06-01 19:52:26 +00:00
|
|
|
|
2007-05-13 20:58:29 +00:00
|
|
|
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY CalledPartyNumber VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
|
|
|
|
dissect_isup_called_party_number_parameter(parameter_tvb, tree, NULL);
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY CallingPartyNumber VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
|
|
|
|
dissect_isup_calling_party_number_parameter(parameter_tvb, tree, NULL);
|
|
|
|
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY BearerCapability/bearerCap VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
|
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
|
|
|
|
dissect_q931_bearer_capability_ie(parameter_tvb, 0, tvb_length_remaining(parameter_tvb,0), tree);
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY RedirectionInformation VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
|
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
|
|
|
|
dissect_isup_redirection_information_parameter(parameter_tvb, tree, NULL);
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY OriginalCalledPartyID VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
|
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
dissect_isup_original_called_number_parameter(parameter_tvb, tree, NULL);
|
|
|
|
|
2007-07-04 13:27:44 +00:00
|
|
|
#.FN_BODY RedirectingPartyID VAL_PTR = ¶meter_tvb
|
2005-11-29 17:23:50 +00:00
|
|
|
|
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
dissect_isup_redirecting_number_parameter(parameter_tvb, tree, NULL);
|
|
|
|
|
2009-12-15 06:31:18 +00:00
|
|
|
#.FN_BODY HighLayerCompatibility VAL_PTR = ¶meter_tvb
|
|
|
|
/*
|
|
|
|
* -- Indicates the teleservice. For encoding, DSS1 (Q.931) is used.
|
|
|
|
*/
|
|
|
|
tvbuff_t *parameter_tvb;
|
|
|
|
proto_tree *subtree;
|
|
|
|
%(DEFAULT_BODY)s
|
|
|
|
|
|
|
|
if (!parameter_tvb)
|
|
|
|
return offset;
|
|
|
|
|
|
|
|
subtree = proto_item_add_subtree(actx->created_item, ett_inap_HighLayerCompatibility);
|
|
|
|
dissect_q931_high_layer_compat_ie(parameter_tvb, 0, tvb_length_remaining(parameter_tvb,0), subtree);
|
2005-02-09 22:31:40 +00:00
|
|
|
|
|
|
|
#.TYPE_ATTR
|
2010-11-07 20:51:16 +00:00
|
|
|
CallingPartysCategory TYPE = FT_UINT16 DISPLAY = BASE_DEC|BASE_EXT_STRING STRINGS = &isup_calling_partys_category_value_ext
|
2005-02-09 22:31:40 +00:00
|
|
|
|
|
|
|
#.END
|
|
|
|
|
|
|
|
|