[PATCH netfilter-next] netfilter: nf_conntrack_sip: tear down expectations on CANCEL
From: Florian Fainelli
Date: Tue Dec 01 2026 - 15:58:12 EST
From: Anand Gore <anand.gore@xxxxxxxxxxxx>
RFC 3261 requires a CANCEL request to terminate the pending INVITE
transaction it targets the same way a BYE would for an established
dialog, including releasing any RTP/RTCP expectations created for it.
Route CANCEL through process_bye_request(), which already does this
for BYE.
Signed-off-by: Anand Gore <anand.gore@xxxxxxxxxxxx>
[florian: commit message, forward ported]
Signed-off-by: Florian Fainelli <florian.fainelli@xxxxxxxxxxxx>
---
net/netfilter/nf_conntrack_sip.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/net/netfilter/nf_conntrack_sip.c b/net/netfilter/nf_conntrack_sip.c
index b05dc8858d09..1e649bd2c0d8 100644
--- a/net/netfilter/nf_conntrack_sip.c
+++ b/net/netfilter/nf_conntrack_sip.c
@@ -1516,6 +1516,7 @@ static const struct sip_handler sip_handlers[] = {
SIP_HANDLER("ACK", process_sdp, NULL),
SIP_HANDLER("PRACK", process_sdp, process_prack_response),
SIP_HANDLER("BYE", process_bye_request, NULL),
+ SIP_HANDLER("CANCEL", process_bye_request, NULL),
SIP_HANDLER("REGISTER", process_register_request, process_register_response),
};
--
2.34.1