Forum Discussion

WithF5's avatar
WithF5
Icon for Nimbostratus rankNimbostratus
Jul 13, 2021

MMS and iRule - weird characters

Hi all,

Im trying to read MMS headers using iRules but I'm getting weird characters. Here is the iRule I'm using:

when CLIENT_ACCEPTED priority 200 {
    TCP::collect
}
when CLIENT_DATA {
    set pld [TCP::payload]
    log local0. "TCP payload: $pld" 
    binary scan $pld H* hex
    #set pld_ascii [binary format H* $hex]
    set pld_ascii [binary format H* $pld]
    log local0. "TCP ASCII payload: $pld_ascii" 
    if { [string tolower $pld] contains "x-mms-transaction-id"} {
            log local0. "Got MMS transaction-id"
    }
    TCP::release
    TCP::collect
}

I tried with $hex variable as well but no luck.

And here is my output:

TCP ASCII payload: ¾ô]˵ê ÿ��·Ðþ!Ôi{ }èlB��òú`ÞûáCøT¤e¬bQïL|( µ
ÆÙdg Bʳ¹§Ó¼ñOlW×mßÂë`±ôµ÷ª5Â-ÏÄ =0æ¢Ò¥nQHÖÚ'                                                                                                                         q¥
¶þ0ððö²êªÆn3`ëµw*¥rÎ
                     UxY¦ä^¶·!¼|J D¶¥JU92Y²'P«¬"Ht½JÓí Þ¼¼)&Ö                                                                                                                 1Â"
ÛE&JSv¸Q{½ãMFÉ&»«¡U¾eËL-%HÔ*\i-                                                                                                                               jtNOPµYdÛPá'Æê
UU 7(Í)Jf3í3©.,eÚ\05Zä×÷Jx±o]ºôzâEª                         �µVëõVøJ«®S&6æýâ:̹2ì¡.È»¤I¸Ð*0ÅfL\}D÷b·Òi£xqs;xb-eÙh¿mûK¸ÅÄRJÒËqi³YÑmne£h³*=ØV ¢¾ZC r$¸Qê®|
                                      Ü»R¢÷ÁUÅê
                                                ²-UÜ+X°K))*
                                                           âb KK ÷åO¬¢H"¡Z'Ý®Ö6Û1jQ/é

Plus much more weird characters.

The VS is a standard one with pretty much all default profiles.

Anyone have seen that before? How to solve it?

Thanks.

No RepliesBe the first to reply