Wireshark-dev: Re: [Wireshark-dev] Fwd: [PATCH] FTBP:ContentsTypeParameterandRelationship are O

From: "Graeme Lunt" <graeme.lunt@xxxxxxxxx>
Date: Sun, 24 Jun 2007 10:34:46 +0200
Anders,

> > Help with the OSI stuff would also be apriciated.
> >I am happy to help out - anything particular to look at?
> EXTERNAL is used in some of the dissectors ACSE FTAM etc
> Now coded as EXTRNALt that should be replaced as packet BER
> Should handle EXTERNAL now. The code in packet-ber.c for
> EXTERNAL isn't quite finished though, for indirect regerence
> A call back must be done to perform the same job as ACSE does today.
> Starting with the dissectors importing EXTERNALt from ACSE.
> 
> Then all OSI dissectors should be regenerated with -X and -T option
> Some of them have workarounds for tagged types which 
> shouldn't be needed
> Or asn2wrs fixed so it isn't.

I have successfully compiled with -X (no -T) pres, ros, rtse, x411 and x420
without any perceived problems.
I am getting a 13% reduction in the file size for the x411 dissector. There
are probably some workarounds I need
to remove for the tagged types but I will look to that later. 

Using -T has given me some problems. For example, for x411 I get the
following additional warnings:

:: UserWarning: The same field names for different types. Explicit field
renaming is recommended.
x121_dcc_code
 x121_dcc_code_01     AddrNumericString
PhysicalDeliveryCountryName/x121-dcc-code
 x121_dcc_code        NumericString        CountryName/_untag/x121-dcc-code

x411.cnf:529: UserWarning: Unused SET_TYPE for CountryName/x121-dcc-code
  AddrNumericString     UserAddress/x121/x121-address
CountryName/x121-dcc-code PhysicalDeliveryCountryName/x121-dcc-code
PostalCode/numeric-code

Not sure what the "_untag" is? These may of course just be asn2wrs giving
better/more warnings.

When compiling RTSE (which includes my own definition of EXTERNAL) with -T I
get:

rtse.cnf:128: UserWarning: Unused FN_BODY for
EXTERNALt/encoding/single-ASN1-type
  offset=call_rtse_oid_callback(object_identifier_id, tvb, offset,
actx->pinfo, top_tree);
rtse.cnf:115: UserWarning: Unused FN_BODY for EXTERNALt/indirect-reference
  char *oid;

Not sure why it is no longer used as the type is "EXTERNALt". Note RTSE
needs its own EXTERNAL handler as it dispatches on the direct reference from
a different table than the ACSE EXTERNAL does. Unless of course the asn2wrs
allows me to specify which table the EXTERNAL should dispatch from?

Graeme