Skip to content

Use of octetstring and bitstring in LENGTHTO (C side)

Related forum topic:

https://www.eclipse.org/forums/index.php/m/1842035/

Request detail

Hello,

I'm currently implementing a NAS encoder based on 3GPP TTCN files. However it specifies length fields as octetstrings, such as Type4Length_Type and Type6Length_Type (which are the typedefs of octetstrings).

For example in the following structure:

  type record ESM_MessageContainer {                            /* 24.301 cl. 9.9.3.15 */
    IEI8_Type                   iei                   optional,   /* present in case of TLV; omit in case of LV */
    Type6Length_Type            iel,
    octetstring                 esmPdu                            /* ESM PDU without NAS security header*/
  };

Here the field 'iel' specifies the length of 'esmPdu'.

But, Titan doesn't allow to use non-integer field in LENGTHTO variant with the following error:

error: The LENGTHTO field must be an integer or union type instead of 'octetstring'

Is there any chance to have a fix for this issue (to be able to use octetstring in LENGTHTO) ?

Edited by Adam Knapp