Add dissection of Error parameters hopfully geting rid of some GCC warnings.

svn path=/trunk/; revision=16860
This commit is contained in:
Anders Broman 2005-12-19 19:34:52 +00:00
parent b56c1ffc6f
commit a010425f35
3 changed files with 625 additions and 242 deletions

View File

@ -8,6 +8,247 @@ DEFINITIONS::=
BEGIN
-- ROS def's
-- Module Remote-Operations-Apdus (H.450.1:02/1998)
--Remote-Operations-Apdus {itu-t recommendation h 450 1 version1(0)
-- remote-operations-apdus(11)} DEFINITIONS AUTOMATIC TAGS ::=
--BEGIN
Component ::= CHOICE {
invoke [1] IMPLICIT Invoke,
returnResultLast [2] IMPLICIT ReturnResult,
returnError [3] IMPLICIT ReturnError,
reject [4] IMPLICIT Reject
}
Invoke ::= SEQUENCE {
invokeID InvokeIdType,
linkedID [0] IMPLICIT InvokeIdType OPTIONAL,
opCode OPERATION,
invokeparameter InvokeParameter OPTIONAL
}
InvokeParameter ::= ANY
-- ANY is filled by the single ASN.1 data type following the keyword PARAMETER or the keyword ARGUMENT
-- in the type definition of a particular operation.
ReturnResult ::= SEQUENCE {
invokeID InvokeIdType,
resultretres SEQUENCE {
opCode OPERATION,
returnparameter ReturnResultParameter OPTIONAL
} OPTIONAL
}
ReturnResultParameter ::= ANY
-- ANY is filled by the single ASN.1 data type following the keyword RESULT in the type definition
-- of a particular operation.
ReturnError ::= SEQUENCE {
invokeID InvokeIdType,
errorCode ERROR,
parameter ReturnErrorParameter OPTIONAL }
ReturnErrorParameter ::= ANY
-- ANY is filled by the single ASN.1 data type following the keyword PARAMETER in the type definition
-- of a particular error.
Reject ::= SEQUENCE {
invokeIDRej CHOICE {
derivable InvokeIdType,
not-derivable NULL },
problem CHOICE {
generalProblem [0] IMPLICIT GeneralProblem,
invokeProblem [1] IMPLICIT InvokeProblem,
returnResultProblem [2] IMPLICIT ReturnResultProblem,
returnErrorProblem [3] IMPLICIT ReturnErrorProblem } }
InvokeIdType ::= INTEGER (-128..127)
OPERATION ::= CHOICE {
localValue OperationLocalvalue,
globalValue OBJECT IDENTIFIER }
OperationLocalvalue ::= INTEGER{
updateLocation (2),
cancelLocation (3),
provideRoamingNumber (4),
noteSubscriberDataModified (5),
resumeCallHandling (6),
insertSubscriberData (7),
deleteSubscriberData (8),
sendParameters (9),
registerSS (10),
eraseSS (11),
activateSS (12),
deactivateSS (13),
interrogateSS (14),
authenticationFailureReport (15),
registerPassword (17),
getPassword (18),
processUnstructuredSS-Data (19),
releaseResources (20),
sendRoutingInfo (22),
updateGprsLocation (23),
sendRoutingInfoForGprs (24),
failureReport (25),
noteMsPresentForGprs (26),
performHandover (28),
sendEndSignal (29),
performSubsequentHandover (30),
provideSIWFSNumber (31),
sIWFSSignallingModify (32),
processAccessSignalling (33),
forwardAccessSignalling (34),
noteInternalHandover (35),
reset (37),
forwardCheckSS (38),
prepareGroupCall (39),
sendGroupCallEndSignal (40),
processGroupCallSignalling (41),
forwardGroupCallSignalling (42),
checkIMEI (43),
mt-forwardSM (44),
sendRoutingInfoForSM (45),
mo-forwardSM (46),
reportSM-DeliveryStatus (47),
noteSubscriberPresent (48),
alertServiceCentreWithoutResult (49),
activateTraceMode (50),
deactivateTraceMode (51),
traceSubscriberActivity (52),
beginSubscriberActivity (54),
sendIdentification (55),
sendAuthenticationInfo (56),
restoreData (57),
sendIMSI (58),
processUnstructuredSS-Request (59),
unstructuredSS-Request (60),
unstructuredSS-Notify (61),
anyTimeSubscriptionInterrogation (62),
informServiceCentre (63),
alertServiceCentre (64),
anyTimeModification (65),
readyForSM (66),
purgeMS (67),
prepareHandover (68),
prepareSubsequentHandover (69),
provideSubscriberInfo (70),
anyTimeInterrogation (71),
ss-InvocationNotification (72),
setReportingState (73),
statusReport (74),
remoteUserFree (75),
registerCC-Entry (76),
eraseCC-Entry (77),
secureTransportClass1 (78),
secureTransportClass2 (79),
secureTransportClass3 (80),
secureTransportClass4 (81),
provideSubscriberLocation (83),
sendRoutingInfoForLCS (85),
subscriberLocationReport (86),
ist-Alert (87),
ist-Command (88),
noteMM-Event (89)
}
ERROR ::= CHOICE {
localValue LocalErrorcode,
globalValue OBJECT IDENTIFIER }
LocalErrorcode ::= INTEGER{
systemFailure (34),
dataMissing (35),
unexpectedDataValue (36),
facilityNotSupported (21),
incompatibleTerminal (28),
resourceLimitation (51),
unknownSubscriber (1),
numberChanged (44),
unknownMSC (3),
unidentifiedSubscriber (5),
unknownEquipment (7),
roamingNotAllowed (8),
illegalSubscriber (9),
illegalEquipment (12),
bearerServiceNotProvisioned (10),
teleserviceNotProvisioned (11),
noHandoverNumberAvailable (25),
subsequentHandoverFailure (26),
targetCellOutsideGroupCallArea (42),
tracingBufferFull (40),
noRoamingNumberAvailable (39),
absentSubscriber (27),
busySubscriber (45),
noSubscriberReply (46),
callBarred (13),
forwardingViolation (14),
forwardingFailed (47),
cug-Reject (15),
or-NotAllowed (48),
ati-NotAllowed (49),
atsi-NotAllowed (60),
atm-NotAllowed (61),
informationNotAvailabl (62),
illegalSS-Operation (16),
ss-ErrorStatus (17),
ss-NotAvailable (18),
ss-SubscriptionViolatio (19),
ss-Incompatibility (20),
unknownAlphabe (71),
ussd-Busy (72),
pw-RegistrationFailur (37),
negativePW-Check (38),
numberOfPW-AttemptsViolation (43),
shortTermDenial (29),
longTermDenial (30),
subscriberBusyForMT-SMS (31),
sm-DeliveryFailure (32),
messageWaitingListFull (33),
absentSubscriberSM (6),
noGroupCallNumberAvailable (50),
unauthorizedRequestingNetwork (52),
unauthorizedLCSClient (53),
positionMethodFailure (54),
unknownOrUnreachableLCSClient (58),
mm-EventNotSupported (59),
secureTransportError (4)
}
-- PROBLEMS
GeneralProblem ::= INTEGER { unrecognizedComponent (0),
mistypedComponent (1),
badlyStructuredComponent (2) }
InvokeProblem ::= INTEGER { duplicateInvokeID (0),
unrecognizedOperation (1),
mistypedParameter (2),
resourceLimitation (3),
initiatingRelease (4),
unrecognizedLinkedID (5),
linkedResponseUnexpected (6),
unexpectedLinkedOperation (7) }
ReturnResultProblem ::= INTEGER { unrecognizedInvokeID (0),
returnResultUnexpected (1),
mistypedParameter (2) }
ReturnErrorProblem ::= INTEGER { unrecognizedInvokeID (0),
returnErrorUnexpected (1),
unrecognizedError (2),
unexpectedError (3),
mistypedParameter (4) }
--END
Bss-APDU ::= SEQUENCE {
protocolId ProtocolId,
@ -2519,7 +2760,7 @@ IST-CommandRes ::= SEQUENCE{
-- }
ReleaseResourcesArg ::= SEQUENCE{
msrn ISDN-AddressString,
msrn ISDN-AddressString OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
...}
@ -4722,6 +4963,10 @@ FacilityNotSupParam ::= SEQUENCE {
... }
-- ::= localValue : 21
OR-NotAllowedParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...}
--incompatibleTerminal ERROR
-- PARAMETER
IncompatibleTerminalParam ::= SEQUENCE {
@ -4827,15 +5072,28 @@ NoRoamingNbParam ::= SEQUENCE {
--absentSubscriber ERROR
-- PARAMETER
AbsentSubscriberParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... ,
absentSubscriberReason [0] IMPLICIT ENUMERATED {
imsiDetach ( 0 ),
restrictedArea ( 1 ),
noPageResponse ( 2 ),
... } OPTIONAL}
extensionContainer ExtensionContainer OPTIONAL,
...,
absentSubscriberReason [0] AbsentSubscriberReason OPTIONAL
}
-- ::= localValue : 27
AbsentSubscriberReason ::= ENUMERATED {
imsiDetach (0),
restrictedArea (1),
noPageResponse (2),
... ,
purgedMS (3)
}
-- exception handling: at reception of other values than the ones listed the
-- AbsentSubscriberReason shall be ignored.
-- The AbsentSubscriberReason: purgedMS is defined for the Super-Charger feature
-- (see TS 23.116). If this value is received in a Provide Roaming Number response
-- it shall be mapped to the AbsentSubscriberReason: imsiDetach in the Send Routeing
-- Information response
--busySubscriber ERROR
-- PARAMETER
@ -4853,20 +5111,12 @@ NoSubscriberReplyParam ::= SEQUENCE {
... }
-- ::= localValue : 46
--callBarred ERROR
--forwardingViolation ERROR
-- PARAMETER
CallBarredParam ::= CHOICE {
callBarringCause CallBarringCause,
extensibleCallBarredParam SEQUENCE {
callBarringCause CallBarringCause OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
... ,
unauthorisedMessageOriginator [1] IMPLICIT NULL OPTIONAL}}
-- ::= localValue : 13
CallBarringCause ::= ENUMERATED {
barringServiceActive ( 0 ),
operatorBarring ( 1 )
}
ForwardingViolationParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... }
-- ::= localValue : 14
--forwardingFailed ERROR
-- PARAMETER
@ -4875,6 +5125,84 @@ ForwardingFailedParam ::= SEQUENCE {
... }
-- ::= localValue : 47
--ati-NotAllowed ERROR
-- PARAMETER
ATI-NotAllowedParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... }
-- ::= localValue : 49
ATSI-NotAllowedParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
ATM-NotAllowedParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
IllegalSS-OperationParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
SS-NotAvailableParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
SS-SubscriptionViolationParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
InformationNotAvailableParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
--subscriberBusyForMT-SMS ERROR
-- PARAMETER
SubBusyForMT-SMS-Param ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... ,
gprsConnectionSuspended NULL OPTIONAL}
-- ::= localValue : 31
--callBarred ERROR
-- PARAMETER
CallBarredParam ::= CHOICE {
callBarringCause CallBarringCause,
extensibleCallBarredParam ExtensibleCallBarredParam
}
-- ::= localValue : 13
CallBarringCause ::= ENUMERATED {
barringServiceActive ( 0 ),
operatorBarring ( 1 )
}
ExtensibleCallBarredParam ::= SEQUENCE {
callBarringCause CallBarringCause OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
... ,
unauthorisedMessageOriginator [1] NULL OPTIONAL
}
CUG-RejectParam ::= SEQUENCE {
cug-RejectCause CUG-RejectCause OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
...
}
CUG-RejectCause ::= ENUMERATED {
incomingCallsBarredWithinCUG (0),
subscriberNotMemberOfCUG (1),
requestedBasicServiceViolatesCUG-Constraints (5),
calledPartySS-InteractionViolation (7)
}
--or-NotAllowed ERROR
-- PARAMETER
Or-NotAllowedParam ::= SEQUENCE {
@ -4882,12 +5210,7 @@ Or-NotAllowedParam ::= SEQUENCE {
... }
-- ::= localValue : 48
--forwardingViolation ERROR
-- PARAMETER
ForwardingViolationParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... }
-- ::= localValue : 14
--cug-Reject ERROR
-- PARAMETER
@ -4901,12 +5224,6 @@ Cug-RejectParam ::= SEQUENCE {
... }
-- ::= localValue : 15
--ati-NotAllowed ERROR
-- PARAMETER
Ati-NotAllowedParam ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... }
-- ::= localValue : 49
--noGroupCallNumberAvailable ERROR
-- PARAMETER
@ -4945,10 +5262,12 @@ SS-IncompatibilityCause ::= SEQUENCE {
--pw-RegistrationFailure ERROR
-- PARAMETER
Pw-RegistrationFailureCause ::= ENUMERATED {
undetermined ( 0 ),
invalidFormat ( 1 ),
newPasswordsMismatch ( 2 ) }
PW-RegistrationFailureCause ::= ENUMERATED {
undetermined (0),
invalidFormat (1),
newPasswordsMismatch (2)
}
-- ::= localValue : 37
--negativePW-Check ERROR
@ -4969,30 +5288,27 @@ LongTermDenialParam ::= SEQUENCE {
... }
-- ::= localValue : 30
--subscriberBusyForMT-SMS ERROR
-- PARAMETER
SubBusyForMT-SMS-Param ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
... ,
gprsConnectionSuspended NULL OPTIONAL}
-- ::= localValue : 31
--sm-DeliveryFailure ERROR
-- PARAMETER
Sm-DeliveryFailureCause ::= SEQUENCE {
sm-EnumeratedDeliveryFailureCause ENUMERATED {
memoryCapacityExceeded ( 0 ),
equipmentProtocolError ( 1 ),
equipmentNotSM-Equipped ( 2 ),
unknownServiceCentre ( 3 ),
sc-Congestion ( 4 ),
invalidSME-Address ( 5 ),
subscriberNotSC-Subscriber ( 6 ) },
diagnosticInfo OCTET STRING ( SIZE( 1 .. 200 ) ) OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
... }
SM-EnumeratedDeliveryFailureCause ::= ENUMERATED {
memoryCapacityExceeded (0),
equipmentProtocolError (1),
equipmentNotSM-Equipped (2),
unknownServiceCentre (3),
sc-Congestion (4),
invalidSME-Address (5),
subscriberNotSC-Subscriber (6)
}
SM-DeliveryFailureCause ::= SEQUENCE {
sm-EnumeratedDeliveryFailureCause SM-EnumeratedDeliveryFailureCause,
diagnosticInfo SignalInfo OPTIONAL,
extensionContainer ExtensionContainer OPTIONAL,
...}
-- ::= localValue : 32
--messageWaitingListFull ERROR
-- PARAMETER
MessageWaitListFullParam ::= SEQUENCE {
@ -5042,19 +5358,26 @@ UnauthorizedLCSClient-Param ::= SEQUENCE {
--positionMethodFailure ERROR
-- PARAMETER
PositionMethodFailure-Param ::= SEQUENCE {
positionMethodFailure-Diagnostic [0] IMPLICIT ENUMERATED {
congestion ( 0 ),
insufficientResources ( 1 ),
insufficientMeasurementData ( 2 ),
inconsistentMeasurementData ( 3 ),
locationProcedureNotCompleted ( 4 ),
locationProcedureNotSupportedByTargetMS ( 5 ),
qoSNotAttainable ( 6 ),
positionMethodNotAvailableInNetwork ( 7 ),
positionMethodNotAvailableInLocationArea ( 8 ),
... } OPTIONAL,
extensionContainer [1] IMPLICIT ExtensionContainer OPTIONAL,
... }
positionMethodFailure-Diagnostic [0] IMPLICIT PositionMethodFailure-Diagnostic OPTIONAL,
extensionContainer [1] IMPLICIT ExtensionContainer OPTIONAL,
...
}
PositionMethodFailure-Diagnostic ::= ENUMERATED {
congestion (0),
insufficientResources (1),
insufficientMeasurementData (2),
inconsistentMeasurementData (3),
locationProcedureNotCompleted (4),
locationProcedureNotSupportedByTargetMS (5),
qoSNotAttainable (6),
positionMethodNotAvailableInNetwork (7),
positionMethodNotAvailableInLocationArea (8),
...
}
-- exception handling:
-- any unrecognized value shall be ignored
-- ::= localValue : 54
--unknownOrUnreachableLCSClient ERROR
@ -5064,6 +5387,24 @@ UnknownOrUnreachableLCSClient-Param ::= SEQUENCE {
... }
-- ::= localValue : 58
MM-EventNotSupported-Param ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
TargetCellOutsideGCA-Param ::= SEQUENCE {
extensionContainer ExtensionContainer OPTIONAL,
...
}
SecureTransportErrorParam ::= SEQUENCE {
securityHeader SecurityHeader,
protectedPayload ProtectedPayload OPTIONAL
}
-- The protectedPayload carries the result of applying the security function
-- defined in 3GPP TS 33.200 to the encoding of the securely transported error
-- parameter
ExtensionContainer ::= SEQUENCE {
privateExtensionList [0] IMPLICIT PrivateExtensionList OPTIONAL,
pcsExtensions [1] IMPLICIT PcsExtensions OPTIONAL,

View File

@ -117,6 +117,33 @@ Ext-ForwardingInfoFor-CSE/forwardingFeatureList ext-forwardingFeatureList
Ext-ForwFeature/noReplyConditionTime ext-noReplyConditionTime
ModificationRequestFor-CF-Info/noReplyConditionTime ext-noReplyConditionTime
#----------------------------------------------------------------------------------------
#.PDU
Component
#.FN_BODY InvokeParameter
offset = dissect_invokeData(pinfo, tree, tvb, offset);
#.FN_BODY ReturnResultParameter
offset = dissect_returnResultData(pinfo, tree, tvb, offset);
#.FN_BODY ReturnErrorParameter
offset = dissect_returnErrorData(pinfo, tree, tvb, offset);
#.FN_PARS OperationLocalvalue
VAL_PTR = &opcode
#.FN_BODY OperationLocalvalue
%(DEFAULT_BODY)s
if (check_col(pinfo->cinfo, COL_INFO)){
col_append_fstr(pinfo->cinfo, COL_INFO, val_to_str(opcode, gsm_map_opr_code_strings, "Unknown GSM-MAP (%%u)"));
}
#.FN_PARS LocalErrorcode
VAL_PTR = &errorCode
#.FN_PARS Sm-RP-UI
VAL_PTR = &tpdu_tvb
@ -321,7 +348,7 @@ ModificationRequestFor-CF-Info/noReplyConditionTime ext-noReplyConditionTime
/* gsm-0806 */
case 2:
break;
/* gsm-BSSMAP TODO Is it correct to stripp off tw first octets here?*/
/* gsm-BSSMAP TODO Is it correct to stripp off two first octets here?*/
case 3:
octet = tvb_get_guint8(parameter_tvb,0);
length = tvb_get_guint8(parameter_tvb,1);

View File

@ -54,18 +54,20 @@
/* Initialize the protocol and registered fields */
int proto_gsm_map = -1;
static int hf_gsm_map_invokeCmd = -1; /* Opcode */
static int hf_gsm_map_invokeid = -1; /* INTEGER */
static int hf_gsm_map_absent = -1; /* NULL */
static int hf_gsm_map_invokeId = -1; /* InvokeId */
static int hf_gsm_map_invoke = -1; /* InvokePDU */
static int hf_gsm_map_returnResult = -1; /* InvokePDU */
/*
static int hf_gsm_map_invokeCmd = -1; / Opcode /
static int hf_gsm_map_invokeid = -1; / INTEGER /
static int hf_gsm_map_absent = -1; / NULL /
static int hf_gsm_map_invokeId = -1; / InvokeId /
static int hf_gsm_map_invoke = -1; / InvokePDU /
static int hf_gsm_map_returnResult = -1; / InvokePDU /
static int hf_gsm_map_returnResult_result = -1;
static int hf_gsm_map_returnError_result = -1;
static int hf_gsm_map_returnError = -1;
static int hf_gsm_map_local_errorCode = -1;
static int hf_gsm_map_global_errorCode_oid = -1;
static int hf_gsm_map_global_errorCode = -1;
*/
static int hf_gsm_map_SendAuthenticationInfoArg = -1;
static int hf_gsm_map_SendAuthenticationInfoRes = -1;
static int hf_gsm_mapSendEndSignal = -1;
@ -115,13 +117,19 @@ static range_t *ssn_range;
dissector_handle_t map_handle;
/* Global variables */
static guint32 opcode=0;
static guint32 errorCode;
static proto_tree *top_tree;
static int application_context_version;
gint protocolId;
gint AccessNetworkProtocolId;
static int gsm_map_tap = -1;
/* Forward declarations */
static int dissect_invokeData(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset);
static int dissect_returnResultData(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset);
static int dissect_returnErrorData(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset);
char*
unpack_digits(tvbuff_t *tvb, int offset){
@ -359,7 +367,6 @@ static const true_false_string gsm_map_Ss_Status_a_values = {
"not Active"
};
static guint32 opcode=0;
static int
dissect_gsm_map_Opcode(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) {
@ -860,155 +867,158 @@ static int dissect_returnResultData(packet_info *pinfo, proto_tree *tree, tvbuff
return offset;
}
static int
dissect_invokeCmd(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_Opcode(FALSE, tvb, offset, pinfo, tree, hf_gsm_map_invokeCmd);
}
static int dissect_invokeid(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_ber_integer(FALSE, pinfo, tree, tvb, offset, hf_gsm_map_invokeid, NULL);
}
static const value_string InvokeId_vals[] = {
{ 0, "invokeid" },
{ 1, "absent" },
{ 0, NULL }
};
static int dissect_absent(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_NULL(FALSE, tvb, offset, pinfo, tree, hf_gsm_map_absent);
}
static const ber_choice_t InvokeId_choice[] = {
{ 0, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeid },
{ 1, BER_CLASS_UNI, BER_UNI_TAG_NULL, BER_FLAGS_NOOWNTAG, dissect_absent },
{ 0, 0, 0, 0, NULL }
};
static int
dissect_gsm_map_InvokeId(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) {
offset = dissect_ber_choice(pinfo, tree, tvb, offset,
InvokeId_choice, hf_index, ett_gsm_map_InvokeId, NULL);
static int dissect_returnErrorData(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
switch(errorCode){
case 1: /* UnknownSubscriberParam */
offset=dissect_gsm_map_UnknownSubscriberParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 4: /* SecureTransportErrorParam */
offset=dissect_gsm_map_SecureTransportErrorParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 5: /* UnidentifiedSubParam */
offset=dissect_gsm_map_UnidentifiedSubParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 6: /* AbsentSubscriberSM-Param */
offset=dissect_gsm_map_AbsentSubscriberSM_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 8: /* RoamingNotAllowedParam */
offset=dissect_gsm_map_RoamingNotAllowedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 9: /* IllegalSubscriberParam */
offset=dissect_gsm_map_IllegalSubscriberParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 10: /* BearerServNotProvParam */
offset=dissect_gsm_map_BearerServNotProvParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 11: /* TeleservNotProvParam */
offset=dissect_gsm_map_TeleservNotProvParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 12: /* IllegalEquipmentParam */
offset=dissect_gsm_map_IllegalEquipmentParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 13: /* CallBarredParam */
offset=dissect_gsm_map_CallBarredParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 14: /* ForwardingViolationParam */
offset=dissect_gsm_map_ForwardingViolationParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 15: /* CUG-RejectParam */
offset=dissect_gsm_map_CUG_RejectParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 16: /* IllegalSS-OperationParam */
offset=dissect_gsm_map_IllegalSS_OperationParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 18: /* SS-NotAvailableParam */
offset=dissect_gsm_map_SS_NotAvailableParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 19: /* SS-SubscriptionViolationParam */
offset=dissect_gsm_map_SS_SubscriptionViolationParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 20: /* SS-IncompatibilityCause */
offset=dissect_gsm_map_SS_IncompatibilityCause(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 21: /* FacilityNotSupParam */
offset=dissect_gsm_map_FacilityNotSupParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 27: /* AbsentSubscriberParam */
offset=dissect_gsm_map_AbsentSubscriberParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 28: /* IncompatibleTerminalParam */
offset=dissect_gsm_map_IncompatibleTerminalParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 29: /* ShortTermDenialParam */
offset=dissect_gsm_map_ShortTermDenialParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 30: /* LongTermDenialParam */
offset=dissect_gsm_map_LongTermDenialParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 31: /* SubBusyForMT-SMS-Param */
offset=dissect_gsm_map_SubBusyForMT_SMS_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 32: /* SM-DeliveryFailureCause */
offset=dissect_gsm_map_SM_DeliveryFailureCause(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 33: /* MessageWaitListFullParam */
offset=dissect_gsm_map_MessageWaitListFullParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 34: /* SystemFailureParam */
offset=dissect_gsm_map_SystemFailureParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 35: /* DataMissingParam */
offset=dissect_gsm_map_DataMissingParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 36: /* UnexpectedDataParam */
offset=dissect_gsm_map_UnexpectedDataParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 37: /* PW-RegistrationFailureCause */
offset=dissect_gsm_map_PW_RegistrationFailureCause(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 39: /* NoRoamingNbParam */
offset=dissect_gsm_map_NoRoamingNbParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 40: /* TracingBufferFullParam */
offset=dissect_gsm_map_TracingBufferFullParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 42: /* TargetCellOutsideGCA-Param */
offset=dissect_gsm_map_TargetCellOutsideGCA_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 44: /* NumberChangedParam */
offset=dissect_gsm_map_NumberChangedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 45: /* BusySubscriberParam */
offset=dissect_gsm_map_BusySubscriberParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 46: /* NoSubscriberReplyParam */
offset=dissect_gsm_map_NoSubscriberReplyParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 47: /* ForwardingFailedParam */
offset=dissect_gsm_map_ForwardingFailedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 48: /* OR-NotAllowedParam */
offset=dissect_gsm_map_OR_NotAllowedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 49: /* ATI-NotAllowedParam */
offset=dissect_gsm_map_ATI_NotAllowedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 50: /* NoGroupCallNbParam */
offset=dissect_gsm_map_NoGroupCallNbParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 51: /* ResourceLimitationParam */
offset=dissect_gsm_map_ResourceLimitationParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 52: /* UnauthorizedRequestingNetwork-Param */
offset=dissect_gsm_map_UnauthorizedRequestingNetwork_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 53: /* UnauthorizedLCSClient-Param */
offset=dissect_gsm_map_UnauthorizedLCSClient_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 54: /* PositionMethodFailure-Param */
offset=dissect_gsm_map_PositionMethodFailure_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 58: /* UnknownOrUnreachableLCSClient-Param */
offset=dissect_gsm_map_UnknownOrUnreachableLCSClient_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 59: /* MM-EventNotSupported-Param */
offset=dissect_gsm_map_MM_EventNotSupported_Param(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 60: /* ATSI-NotAllowedParam */
offset=dissect_gsm_map_ATSI_NotAllowedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 61: /* ATM-NotAllowedParam */
offset=dissect_gsm_map_ATM_NotAllowedParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
case 62: /* InformationNotAvailableParam */
offset=dissect_gsm_map_InformationNotAvailableParam(FALSE, tvb, offset, pinfo, tree, -1);
break;
default:
proto_tree_add_text(tree, tvb, offset, -1, "Unknown returnErrorData blob");
break;
}
return offset;
}
static int dissect_invokeId(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_InvokeId(FALSE, tvb, offset, pinfo, tree, hf_gsm_map_invokeId);
}
static const ber_sequence_t InvokePDU_sequence[] = {
{ BER_CLASS_UNI, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_invokeId },
{ BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeCmd },
{ BER_CLASS_UNI, -1/*depends on Cmd*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_invokeData },
{ 0, 0, 0, NULL }
};
static int
dissect_gsm_map_InvokePDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) {
offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
InvokePDU_sequence, hf_index, ett_gsm_map_InvokePDU);
return offset;
}
static int dissect_invoke_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_InvokePDU(TRUE, tvb, offset, pinfo, tree, hf_gsm_map_invoke);
}
static const ber_sequence_t ReturnResult_result_sequence[] = {
{ BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeCmd },
{ BER_CLASS_UNI, -1/*depends on Cmd*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_returnResultData },
{ 0, 0, 0, NULL }
};
static int
dissect_returnResult_result(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
offset = dissect_ber_sequence(FALSE, pinfo, tree, tvb, offset,
ReturnResult_result_sequence, hf_gsm_map_returnResult_result, ett_gsm_map_ReturnResult_result);
return offset;
}
static const ber_sequence_t ReturnResultPDU_sequence[] = {
{ BER_CLASS_UNI, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_invokeId },
{ BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_returnResult_result },
{ 0, 0, 0, NULL }
};
static int
dissect_gsm_map_returnResultPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) {
offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
ReturnResultPDU_sequence, hf_index, ett_gsm_map_ReturnResultPDU);
return offset;
}
static int dissect_returnResult_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_returnResultPDU(TRUE, tvb, offset, pinfo, tree, hf_gsm_map_returnResult);
}
static int
dissect_local_errorCode(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_ber_integer(FALSE, pinfo, tree, tvb, offset, hf_gsm_map_local_errorCode, NULL);
}
static int
dissect_global_errorCode(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
offset = dissect_ber_object_identifier(FALSE, pinfo, tree, tvb, offset,
hf_gsm_map_global_errorCode_oid, NULL);
return dissect_ber_integer(FALSE, pinfo, tree, tvb, offset, hf_gsm_map_global_errorCode, NULL);
}
static const ber_choice_t ReturnError_result_choice[] = {
{ 0, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_local_errorCode },
{ 1, BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_global_errorCode },
{ 0, 0, 0, 0, NULL }
};
static int
dissect_ReturnError_result(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
offset = dissect_ber_choice(pinfo, tree, tvb, offset,
ReturnError_result_choice, hf_gsm_map_returnError_result, ett_gsm_map_ReturnError_result, NULL);
return offset;
}
static const ber_sequence_t ReturnErrorPDU_sequence[] = {
{ BER_CLASS_UNI, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_invokeId },
{ BER_CLASS_UNI, -1/*choice*/,BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_ReturnError_result },
{ 0, 0, 0, NULL }
};
static int
dissect_gsm_map_ReturnErrorPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index) {
offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
ReturnErrorPDU_sequence, hf_index, ett_gsm_map_ReturnErrorPDU);
return offset;
}
static int dissect_returnError_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
return dissect_gsm_map_ReturnErrorPDU(TRUE, tvb, offset, pinfo, tree, hf_gsm_map_returnError);
}
static const value_string GSMMAPPDU_vals[] = {
{ 1, "Invoke " },
{ 2, "ReturnResult " },
{ 3, "ReturnError " },
{ 4, "Reject " },
{ 0, NULL }
};
static const ber_choice_t GSMMAPPDU_choice[] = {
{ 1, BER_CLASS_CON, 1, BER_FLAGS_IMPLTAG, dissect_invoke_impl },
{ 2, BER_CLASS_CON, 2, BER_FLAGS_IMPLTAG, dissect_returnResult_impl },
{ 3, BER_CLASS_CON, 3, BER_FLAGS_IMPLTAG, dissect_returnError_impl },
#ifdef REMOVED
{ 4, BER_CLASS_CON, 4, BER_FLAGS_IMPLTAG, dissect_reject_impl },
#endif
{ 0, 0, 0, 0, NULL }
};
static guint8 gsmmap_pdu_type = 0;
static guint8 gsm_map_pdu_size = 0;
@ -1031,12 +1041,14 @@ dissect_gsm_map_GSMMAPPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset,
gsm_map_pdu_size = tvb_get_guint8(tvb, offset+1)+2;
if (check_col(pinfo->cinfo, COL_INFO)){
col_set_str(pinfo->cinfo, COL_INFO, val_to_str(gsmmap_pdu_type, GSMMAPPDU_vals, "Unknown GSM-MAP PDU (%u)"));
col_set_str(pinfo->cinfo, COL_INFO, val_to_str(gsmmap_pdu_type, gsm_map_Component_vals, "Unknown GSM-MAP PDU (%u)"));
}
offset = dissect_gsm_map_Component(FALSE, tvb, 0, pinfo, tree, hf_gsm_map_Component_PDU);
return offset;
/*
offset = dissect_ber_choice(pinfo, tree, tvb, offset,
GSMMAPPDU_choice, hf_index, ett_gsm_map_GSMMAPPDU, NULL);
*/
return offset;
}
@ -1446,6 +1458,7 @@ void proto_register_gsm_map(void) {
/* List of fields */
static hf_register_info hf[] = {
/*
{ &hf_gsm_map_invokeCmd,
{ "invokeCmd", "gsm_map.invokeCmd",
FT_UINT32, BASE_DEC, VALS(gsm_map_opr_code_strings), 0,
@ -1462,22 +1475,6 @@ void proto_register_gsm_map(void) {
{ "invokeId", "gsm_map.invokeId",
FT_UINT32, BASE_DEC, VALS(InvokeId_vals), 0,
"InvokePDU/invokeId", HFILL }},
{ &hf_gsm_map_SendAuthenticationInfoArg,
{ "SendAuthenticationInfoArg", "gsm_map.SendAuthenticationInfoArg",
FT_BYTES, BASE_NONE, NULL, 0,
"SendAuthenticationInfoArg", HFILL }},
{ &hf_gsm_map_SendAuthenticationInfoRes,
{ "SendAuthenticationInfoRes", "gsm_map.SendAuthenticationInfoRes",
FT_BYTES, BASE_NONE, NULL, 0,
"SendAuthenticationInfoRes", HFILL }},
{ &hf_gsm_map_currentPassword,
{ "currentPassword", "gsm_map.currentPassword",
FT_STRING, BASE_NONE, NULL, 0,
"", HFILL }},
{ &hf_gsm_mapSendEndSignal,
{ "mapSendEndSignalArg", "gsm_map.mapsendendsignalarg",
FT_BYTES, BASE_NONE, NULL, 0,
"mapSendEndSignalArg", HFILL }},
{ &hf_gsm_map_invoke,
{ "invoke", "gsm_map.invoke",
FT_NONE, BASE_NONE, NULL, 0,
@ -1514,6 +1511,24 @@ void proto_register_gsm_map(void) {
{ "Password", "gsm_map.password",
FT_UINT8, BASE_DEC, VALS(gsm_map_GetPasswordArg_vals), 0,
"Password", HFILL }},
*/
{ &hf_gsm_map_SendAuthenticationInfoArg,
{ "SendAuthenticationInfoArg", "gsm_map.SendAuthenticationInfoArg",
FT_BYTES, BASE_NONE, NULL, 0,
"SendAuthenticationInfoArg", HFILL }},
{ &hf_gsm_map_SendAuthenticationInfoRes,
{ "SendAuthenticationInfoRes", "gsm_map.SendAuthenticationInfoRes",
FT_BYTES, BASE_NONE, NULL, 0,
"SendAuthenticationInfoRes", HFILL }},
{ &hf_gsm_map_currentPassword,
{ "currentPassword", "gsm_map.currentPassword",
FT_STRING, BASE_NONE, NULL, 0,
"", HFILL }},
{ &hf_gsm_mapSendEndSignal,
{ "mapSendEndSignalArg", "gsm_map.mapsendendsignalarg",
FT_BYTES, BASE_NONE, NULL, 0,
"mapSendEndSignalArg", HFILL }},
{ &hf_gsm_map_extension,
{ "Extension", "gsm_map.extension",
FT_BOOLEAN, 8, TFS(&gsm_map_extension_value), 0x80,