[OpenSIPS-Devel] [OpenSIPS/opensips] cc801a: event_rabbitmq: fix dupl_string() NUL-inclusive le...
Norm Brandinger
noreply at github.com
Fri Apr 17 12:26:07 UTC 2026
Branch: refs/heads/master
Home: https://github.com/OpenSIPS/opensips
Commit: cc801a4e01cd9ee7c21b0d34d9b7a7aa32f6c3a3
https://github.com/OpenSIPS/opensips/commit/cc801a4e01cd9ee7c21b0d34d9b7a7aa32f6c3a3
Author: Norm Brandinger <n.brandinger at gmail.com>
Date: 2026-04-17 (Fri, 17 Apr 2026)
Changed paths:
M modules/event_rabbitmq/event_rabbitmq.c
Log Message:
-----------
event_rabbitmq: fix dupl_string() NUL-inclusive len corrupting AMQP shortstr (#3834)
dupl_string() incremented dst->len after NUL-terminating the unescaped
string, causing .len to include the trailing NUL byte. This made
amqp_basic_publish() encode exchange and routing-key shortstr fields
with an extra 0x00, breaking broker routing.
Remove the len++ and all downstream compensations (tls_dom_name.len--,
and the - 1 adjustments in rmq_print() for address, exchange, routing
key, and user). Also fix the un_escape() error path to free the
already-allocated shm buffer, and fix the default-user allocation to
explicitly NUL-terminate.
Closes #3828
To unsubscribe from these emails, change your notification settings at https://github.com/OpenSIPS/opensips/settings/notifications
More information about the Devel
mailing list