Menu

#31 Improper embedded SOH handling in tag 213 -

open
nobody
None
5
2010-05-10
2010-05-10
rcamera
No

When receiving a SOH character in the XmlData field, the message is not passed to `fromApp'. There is an "Invalid message: Expected BodyLength=100, Recieved BodyLength=101" error logged. The sending application (also quickfix) has no problem calculating the length of the message it is generating.

If I receive a (nearly) identical message with a PIPE or STX instead of an SOH, the message is correctly handled with 9=101.

I am able to reproduce this problem on linux (compiled) and windows (bin-vs9) with version 1.13.2

Discussion

  • rcamera

    rcamera - 2010-05-10

    "messages" and "event" logs -

     
  • rcamera

    rcamera - 2010-05-10

    Able to reproduce problem on windows version 1.13.3 (bin-vs9).

     
  • rcamera

    rcamera - 2010-05-12

    Also able to reproduce on linux with version 1.13.3.

    The same problem happens with embedded SOH characters in RawData as well - I'm guessing this is true with all `Data' fields.

    I've begun tracking the problem in more detail and have found that `m_string' in FieldBase is populated with the field UP TO the embedded SOH. This is because of the logic in Message::extractField which says that the field ends at the first SOH encountered. There is additional logic to handle `Data' field types, but i am unable to enter into this logic.

    Any help with this would be greatly appreciated.

    Thanks,

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.