<p></p>
<p>Sorry.</p>
<p>This is my code for filtering :</p>
<p>"request_route {</p>
<pre><code>xerr("Before filter_body");
if (filter_body("application/sdp")) { xerr("Filtered with sucess"); }
else { xerr("Filtering failed");}
</code></pre>
<p>"</p>
<p>The log is the following :</p>
<p>"2021-06-02T16:13:53.396443+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR: <script>: Before filter_body<br>
2021-06-02T16:13:53.396677+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:275]: parse_sip_header_name(): invalid end of header name for [--unique-bound]<br>
2021-06-02T16:13:53.396886+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [pplication/sdp]<br>
2021-06-02T16:13:53.397141+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:236]: parse_sip_header_name(): invalid start of header name for [<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="52852064" data-permission-text="Title is private" data-url="https://github.com/kamailio/kamailio/issues/15" data-hovercard-type="issue" data-hovercard-url="/kamailio/kamailio/issues/15/hovercard" href="https://github.com/kamailio/kamailio/issues/15">#15</a>#012v=0#15#012o=- 184]<br>
2021-06-02T16:13:53.397337+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [v=0#15#012o=- 18454]<br>
2021-06-02T16:13:53.397527+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [o=- 1845407145]<br>
2021-06-02T16:13:53.397716+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [s=-<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="52852064" data-permission-text="Title is private" data-url="https://github.com/kamailio/kamailio/issues/15" data-hovercard-type="issue" data-hovercard-url="/kamailio/kamailio/issues/15/hovercard" href="https://github.com/kamailio/kamailio/issues/15">#15</a>#012c=IN IP4 ]<br>
2021-06-02T16:13:53.397914+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [c=IN IP4 212.1]<br>
2021-06-02T16:13:53.398154+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [t=0 0#15#012m=audio]<br>
2021-06-02T16:13:53.398346+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [m=audio 22138 ]<br>
2021-06-02T16:13:53.398548+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [a=rtpmap:101 t]<br>
2021-06-02T16:13:53.398813+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [a=rtpmap:96 CL]<br>
2021-06-02T16:13:53.399037+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:236]: parse_sip_header_name(): invalid start of header name for [<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="52852064" data-permission-text="Title is private" data-url="https://github.com/kamailio/kamailio/issues/15" data-hovercard-type="issue" data-hovercard-url="/kamailio/kamailio/issues/15/hovercard" href="https://github.com/kamailio/kamailio/issues/15">#15</a>#012--unique-bou]<br>
2021-06-02T16:13:53.399230+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:275]: parse_sip_header_name(): invalid end of header name for [--unique-bound]<br>
2021-06-02T16:13:53.399428+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:266]: parse_sip_header_name(): invalid header name for [pplication/ISU]<br>
2021-06-02T16:13:53.399621+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:275]: parse_sip_header_name(): invalid end of header name for [Content-Dispos]<br>
2021-06-02T16:13:53.399815+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:236]: parse_sip_header_name(): invalid start of header name for [<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="52852064" data-permission-text="Title is private" data-url="https://github.com/kamailio/kamailio/issues/15" data-hovercard-type="issue" data-hovercard-url="/kamailio/kamailio/issues/15/hovercard" href="https://github.com/kamailio/kamailio/issues/15">#15</a>#012#1]<br>
2021-06-02T16:13:53.400028+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:236]: parse_sip_header_name(): invalid start of header name for [<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="31891578" data-permission-text="Title is private" data-url="https://github.com/kamailio/kamailio/issues/1" data-hovercard-type="issue" data-hovercard-url="/kamailio/kamailio/issues/1/hovercard" href="https://github.com/kamailio/kamailio/issues/1">#1</a>]<br>
2021-06-02T16:13:53.400234+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR:  [core/parser/parse_hname2.c:275]: parse_sip_header_name(): invalid end of header name for [--unique-bound]<br>
2021-06-02T16:13:53.400427+01:00 dev_sbc_a_vts01 /usr/local/kamailio-5.4/sbin/kamailio[2740]: ERROR: <script>: Filtering failed<br>
"</p>
<p>I've also attached the packet body :</p>
<pre><code>"Message Body
    MIME Multipart Media Encapsulation, Type: multipart/mixed, Boundary: "unique-boundary-1"
        [Type: multipart/mixed]
        First boundary: --unique-boundary-1\r\n
        Encapsulated multipart part:  (application/sdp)
            Content-Type:application/sdp\r\n\r\n
            Session Description Protocol
                Session Description Protocol Version (v): 0
                Owner/Creator, Session Id (o): - 1845407145 1 IN IP4 1.1.1.1
                Session Name (s): -
                Connection Information (c): IN IP4 1.1.1.1
                Time Description, active time (t): 0 0
                Media Description, name and address (m): audio 22138 RTP/AVP 8 0 18 3 13 101 96
                Media Attribute (a): rtpmap:101 telephone-event/8000
                Media Attribute (a): rtpmap:96 CLEARMODE/8000
        Boundary: \r\n--unique-boundary-1\r\n
        Encapsulated multipart part:  (application/isup)
            Content-Type:application/ISUP;base=itu-t92+;version=itu-t\r\n
            Content-Disposition:signal;handling=required\r\n\r\n
            ISDN User Part
                Message Type: Initial address (1)
                Nature of Connection Indicators : 0x0
                Forward Call Indicators : 0x6001
                Calling Party's category : 0xa (ordinary calling subscriber)
                Transmission medium requirement : 0 (speech)
                Called Party NumberCalled Party Number: 222222222
                Pointer to start of optional part: 10
                Parameter: (t=10, l=8) Calling party number: Calling party numberCalling Party Number: 333333333
                Parameter: (t=192, l=9) Generic number: Generic numberGeneric Number: 333333333
                End of optional parameters (0)
        Last boundary: \r\n--unique-boundary-1--\r\n"
</code></pre>
<p>If more info or testing is needed please let me know.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/2748#issuecomment-853125172">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABO7UZORWQP5BM26TGYKUE3TQZE37ANCNFSM45UBLQZA">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABO7UZIOZUJETYE3QHN5DJLTQZE37A5CNFSM45UBLQZKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOGLM2QNA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/issues/2748#issuecomment-853125172",
"url": "https://github.com/kamailio/kamailio/issues/2748#issuecomment-853125172",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>