CroatiaControlLtd/asterix

Wrong handling of CAT001 when multiple records in data block and missing I010

Opened this issue · 0 comments

In following conditions parser fails to parse data record:

  • there is CAT001 data block with 2 records (Note that this is old way of data packing in Asterix, and in new categories it should not be allowed (but only on record per data block)),
  • and second record does not contain item 010 (Data Source Identifier) (see recommendation below)
  • and second record contains plot information (not track)

The reason is the parser relies on the assumption that item 010 is present in record. That way it can determine bit from item 020 before parsing it and choose proper UAP.

Note that in Asterix specification it is recommended to send this item in each data record, but it is not compulsory .

5.3.2 Encoding Rules
5.3.2.1 Data Item I001/010 (Data Source Identifier) is compulsory and shall always be transmitted in each Data Block, at least in the first Record of a sequence of Records originating from the same data source.
Recommendation The Data Source Identifier should be transmitted in every Record.

Here is the sample of erroneous packet:

01002cfd20381520533d148c008105f00ab07d202027d415a00a1d046c10ba7d2020176114ec074e05f012ca02000cf4381502183ba66904