From a78403ed1837bcfe79a77497d95d26c8de968929 Mon Sep 17 00:00:00 2001 From: Anders Broman Date: Tue, 17 May 2005 20:30:49 +0000 Subject: Make it possible to dissect h221nonstandarddata and fix some errors from the new asn2eth generator. svn path=/trunk/; revision=14387 --- asn1/h245/h245.cnf | 31 ++++++++++++++++++++++--------- asn1/h245/packet-h245-template.c | 3 +++ 2 files changed, 25 insertions(+), 9 deletions(-) (limited to 'asn1/h245') diff --git a/asn1/h245/h245.cnf b/asn1/h245/h245.cnf index b670ec3f4d..6228a8cdf7 100644 --- a/asn1/h245/h245.cnf +++ b/asn1/h245/h245.cnf @@ -425,7 +425,7 @@ guint32 tsapIdentifier; #.FN_FTR NonStandardIdentifier/h221NonStandard h221NonStandard = ((t35CountryCode * 256) + t35Extension) * 65536 + manufacturerCode; proto_tree_add_uint(tree, hf_h245Manufacturer, tvb, (offset>>3)-4, 4, h221NonStandard); - + nsp_handle = dissector_get_port_handle(nsp_h221_dissector_table, h221NonStandard); #.FN_BODY NonStandardIdentifier/h221NonStandard/t35CountryCode offset = dissect_per_constrained_integer(tvb, offset, pinfo, tree, hf_index, 0U, 255U, &t35CountryCode, NULL, FALSE); @@ -435,6 +435,19 @@ guint32 tsapIdentifier; #.FN_BODY NonStandardIdentifier/h221NonStandard/manufacturerCode offset = dissect_per_constrained_integer(tvb, offset, pinfo, tree, hf_index, 0U, 65535U, &manufacturerCode, NULL, FALSE); +#.FN_BODY NonStandardParameter/data + guint32 value_offset, value_len; + tvbuff_t *next_tvb; + + offset = dissect_per_octet_string(tvb, offset, pinfo, tree, + hf_index, -1, -1, + &value_offset, &value_len); + + if (value_len > 0) { + next_tvb = tvb_new_subset(tvb, value_offset, value_len, value_len); + call_dissector((nsp_handle)?nsp_handle:data_handle, next_tvb, pinfo, tree); + } + #.END #---------------------------------------------------------------------------------------- #.TYPE_RENAME @@ -507,7 +520,7 @@ OpenLogicalChannel/forwardLogicalChannelParameters/multiplexParameters OLC_forw_ OpenLogicalChannel/reverseLogicalChannelParameters/multiplexParameters OLC_rev_multiplexParameters OpenLogicalChannel/reverseLogicalChannelParameters OLC_reverseLogicalChannelParameters OpenLogicalChannelAck/reverseLogicalChannelParameters OLC_ack_reverseLogicalChannelParameters -CloseLogicalChannel/reason clc_reason +CloseLogicalChannel/reason Clc_reason VCCapability/availableBitRates/type Avb_type MultiplexElement/type Me_type RedundancyEncodingDTModeElement/type Re_type @@ -660,7 +673,7 @@ MultiplexEntrySendAck/multiplexTableEntryNumber multiplexTableEntryNumbers MultiplexEntrySendRelease/multiplexTableEntryNumber multiplexTableEntryNumbers CapabilityIdentifier/standard standardOid MiscellaneousIndication/type/videoNotDecodedMBs/temporalReference temporalReference_0_255 -CloseLogicalChannel/source CloseLogicalChannel_source +CloseLogicalChannel/source cLC_source FECCapability/rfc2733/separateStream separateStreamBool FECCapability/rfc2733/separateStream/samePort samePortBool VCCapability/aal1/srtsClockRecovery srtsClockRecovery_bool @@ -717,8 +730,8 @@ NewATMVCCommand/aal/aal1/clockRecovery/nullClockRecovery nullClockRecoveryflag NewATMVCIndication/aal/aal1/clockRecovery/nullClockRecovery nullClockRecoveryflag NewATMVCCommand/aal/aal1/errorCorrection/nullErrorCorrection nullErrorCorrectionFlag NewATMVCIndication/aal/aal1/errorCorrection/nullErrorCorrection nullErrorCorrectionFlag -H223AL2MParameters/headerFEC AL2HeaderFEC -H223AL1MParameters/headerFEC AL1HeaderFEC +H223AL2MParameters/headerFEC aL2HeaderFEC +H223AL1MParameters/headerFEC aL1HeaderFEC H223AL1MParameters/crcLength crcLength2 H223AL3MParameters/crcLength crlength2 SendTerminalCapabilitySet/specificRequest/multiplexCapability multiplexCapabilityBool @@ -740,7 +753,7 @@ RequestChannelCloseReject/cause req_chan_clos_rej_cause TerminalCapabilitySetReject/cause tcs_rej_cause MaintenanceLoopReject/cause maintloop_rej_cause FunctionNotSupported/cause fns_cause -Restriction/maximumBitRate Res_maximumBitRate +Restriction/maximumBitRate res_maximumBitRate RedundancyEncodingDTMode/primary prmary_dtmode RedundancyEncoding/rtpRedundancyEncoding/primary primary FECMode/rfc2733Mode/mode fec_mode @@ -756,11 +769,11 @@ MultiplexElement/repeatCount me_repeatCount FECCapability/rfc2733 fecc_rfc2733 RequestModeAck/response req_mode_ack_response UserInputIndication/signalUpdate/rtp si_rtp -VCCapability/availableBitRates/type Avb_type -MultiplexElement/type Me_type +VCCapability/availableBitRates/type avb_type +MultiplexElement/type me_type RedundancyEncodingDTModeElement/type re_type MaintenanceLoopRequest/type mlr_type -MaintenanceLoopAck/type Mla_type +MaintenanceLoopAck/type mla_type MaintenanceLoopReject/type mlrej_type MiscellaneousCommand/type mc_type MiscellaneousIndication/type mi_type diff --git a/asn1/h245/packet-h245-template.c b/asn1/h245/packet-h245-template.c index 55581f871f..66212567c8 100644 --- a/asn1/h245/packet-h245-template.c +++ b/asn1/h245/packet-h245-template.c @@ -62,6 +62,7 @@ static dissector_handle_t rtcp_handle=NULL; static dissector_table_t nsp_object_dissector_table; static dissector_table_t nsp_h221_dissector_table; static dissector_handle_t nsp_handle; +static dissector_handle_t data_handle; static dissector_handle_t h245_handle; static dissector_handle_t MultimediaSystemControlMessage_handle; @@ -356,6 +357,8 @@ void proto_register_h245(void) { void proto_reg_handoff_h245(void) { rtp_handle = find_dissector("rtp"); rtcp_handle = find_dissector("rtcp"); + data_handle = find_dissector("data"); + h245_handle=create_dissector_handle(dissect_h245, proto_h245); dissector_add_handle("tcp.port", h245_handle); -- cgit v1.2.3