Forum Discussion

kazeem_yusuf1's avatar
kazeem_yusuf1
Icon for Nimbostratus rankNimbostratus
Dec 06, 2017

AN IRULE THAT PERFORMS HEADER ENRICHMENT AND SENDS TRAFFIC TO A Specific IP (MMSC)

I have a requirement to forward mms traffic to a specific mmsc, and perform header enrichment.

 

I have an irule to forward traffic to a specific ip address. What irule can be used to combine that with header enrichment.

 

This is my current irule.

 

when HTTP_REQUEST { if { [HTTP::host] equals "10.199.212.15" && [HTTP::uri] equals "/servlets/mms"} { pool mmsc_pool } }

 

  • Q. Do you want to add client ip in header or specific words? if client IP then follow below irule.

    Please test it in your environment and let us know if any issue.

      when HTTP_REQUEST { 
    if { [HTTP::host] equals "10.199.212.15" && [HTTP::uri] equals "/servlets/mms"} {   
        HTTP::header remove X-Forwarded-For
        HTTP::header insert X-Forwarded-For [IP::client_addr]
        pool mmsc_pool 
        } 
    }
    
    • kazeem_yusuf1's avatar
      kazeem_yusuf1
      Icon for Nimbostratus rankNimbostratus

      Thank You f5_rock, The header enrichment i want to perform is to reveal the MSISDN information. Can it be achieved

       

    • Samir_Jha_52506's avatar
      Samir_Jha_52506
      Icon for Noctilucent rankNoctilucent

      which type of value you store in MSISDN. update the sample here. I can see many irule related to MSISDN on devcentral.

       

    • kazeem_yusuf1's avatar
      kazeem_yusuf1
      Icon for Nimbostratus rankNimbostratus

      the only MSISDN information needed for now is the phone number,eg, 08034567892

       

  • The HTTP header enrichtment for MMS traffic is typically done on the WAP2 gateway, which is an network enforced HTTP proxy with a RADIUS accounting proxy, allowing to get all RADIUS packets from the GGSN as the PDP/IP conect for the client is established. Then the gateway enriches the HTTP headers with any RADIUS provided values, i.e. Calling-Station-Id woudl be your MSISDN for the MMSC. See Kannel WAP gateway for an open source WAP gateway that can do this.