Branch: refs/heads/master
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 4c52754b8cb2ade4f877d6a03c4b84d84608d49a
      
https://github.com/OpenSIPS/opensips/commit/4c52754b8cb2ade4f877d6a03c4b84d84608d49a
  Author: Razvan Crainea <raz...@opensips.org>
  Date:   2021-08-19 (Thu, 19 Aug 2021)

  Changed paths:
    M modules/proto_bin/proto_bin.c

  Log Message:
  -----------
  proto_bin: fix crash when parsed data is printed on error

The module was trying to print the parsed data in case of an error,
however it was using the `start` field of the tcp_conn. The problem is
that the module does not use the `start` field, therefore when a request
is not entirely read from the begining, it is not updated to point to
the new structure. Therefore, when we're trying to print the buffer, it
is pointing to an address on stack.
The fix for this bug was to suppress the parsed printing, as it is
binary anyway and it is the same value as the `buf`.

Many thanks to Bernard Buitenhuis for reporting the issue.



_______________________________________________
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel

Reply via email to