In this section:

Summary

This document shows how to configure the UX to remove <> characters from a parameter within a header. In this specific example, the <> characters are removed from the uri parameter of a Proxy-Authentication header from an INVITE sent by the SBC x000.

 

SIP Header

Proxy-Authorization: Digest realm="Realm", nonce="MTM1NTMxMTYwNjE0N2NhYWRhYWZkZjY0NzVkYmNmMTRmZGY3ZjVlMjVhZWJl",algorithm=MD5,qop=auth, username="tech01_1723207030", uri="<sip:01274662967@80.193.254.193:5060;user=phone>", response="c3aec7cea80019ca04a9bb064383fb9d", cnonce="bef5a3cc", nc=00000001

Parameter to Match

uri="<sip:01274662967@80.193.254.193:5060;user=phone>"

Regex Match

(.*)(uri..).(.*)(phone).(.*)

Desired Output

uri="sip:01274662967@80.193.254.193:5060;user=phone"

Configure the SBC1000/2000 for Header Manipulation

  1. Create a new SIP Message Rule Tables. This entry will only activate on INVITE messages.

    Create New SIP Message Rule Tables

  2. Create a Message Rule Table entry. As Proxy-Authorization is not a pre-defined Header Name, you will need to type Proxy-Authorization manually into the field.

    Create Message Rule Table Entry


     

  3. In the Message Rule Table entry, click the Add/Edit button and enter the Message Field values as shown. This regex will match the Proxy-Authorization header and remove the <> (brackets) from the uri parameter.

    Edit Message Field

  4. Apply the SIP Message Manipulation to the Output Message Manipulation on the desired egress Signaling Group.

Debugging Output

[2012-01-10 13:16:53,774] 2641 0001 com.net.ux.sip TRACE (Executive.cpp:81) - Run: Message Rule (17) matched at least one message rule
[2012-01-10 13:16:53,774] 2642 0001 com.net.ux.sip TRACE (Executive.cpp:58) - Run: Protocol Engine::getting ruleid (15)
[2012-01-10 13:16:53,775] 2643 0001 com.net.ux.sip TRACE (Executive.cpp:75) - Run: Processing Message Rule (ProxyAuthURI)
[2012-01-10 13:16:53,775] 2644 0001 com.net.ux.sip TRACE (Executive.cpp:127) - processMessageRule: Processing Message Rule (15)
[2012-01-10 13:16:53,775] 2645 0001 com.net.ux.sip TRACE (Executive.cpp:1252) - MatchSipMessageRule: StartLine from configuration (invite)From Msg (INVITE sip:3539@demo6.vx.net:5060 SIP/2.0
)
[2012-01-10 13:16:53,775] 2646 0001 com.net.ux.sip TRACE (Executive.cpp:1262) - MatchSipMessageRule: Request configuration (invite)From Msg (invite)
[2012-01-10 13:16:53,775] 2647 0001 com.net.ux.sip DEBUG (HeaderRule.h:549) - debugInfo: ReaderRuleRegexModify: HeaderRulePayload:: mReplacement
[2012-01-10 13:16:53,775] 2648 0001 com.net.ux.sip DEBUG (ProtocolField.h:93) - debugInfo: FieldElement:: FieldType(1) Source(\1\2\3\4\5)
[2012-01-10 13:16:53,775] 2649 0001 com.net.ux.sip DEBUG (ProtocolField.h:211) - debugInfo: FieldElementLiteral:: stringLiteral(\1\2\3\4\5)
[2012-01-10 13:16:53,775] 2650 0001 com.net.ux.sip DEBUG (HeaderRule.h:486) - debugInfo: HeaderRuleRegex:: Expression((.*)(uri..).(.*)(phone).(.*))
[2012-01-10 13:16:53,775] 2651 0001 com.net.ux.sip DEBUG (HeaderRule.h:115) - debugInfo: HeaderRule:: HeaderRuleType(1)
[2012-01-10 13:16:53,775] 2652 0001 com.net.ux.sip DEBUG (RuleBase.h:123) - debugInfo: RuleBase:: RuleBaseType(1)  Result(1) Description(proxyauthURIbrackets) valid(true), Condition Expression(No conditions for this header rule)
[2012-01-10 13:16:53,775] 2653 0001 com.net.ux.sip TRACE (Executive.cpp:211) - processMessageRule: Processing Header rule
[2012-01-10 13:16:53,776] 2654 0001 com.net.ux.sip DEBUG (Executive.cpp:316) - processHeaderRule: Processing header Rule (proxyauthURIbrackets)
[2012-01-10 13:16:53,776] 2655 0001 com.net.ux.sip TRACE (Executive.cpp:428) - processHeaderRule: Processing Rule Regex Modify
[2012-01-10 13:16:53,776] 2656 0001 com.net.ux.sip TRACE (Executive.cpp:727) - buildField: Building fields with element count=1
[2012-01-10 13:16:53,776] 2657 0001 com.net.ux.sip TRACE (Executive.cpp:755) - buildField: Building field literal
[2012-01-10 13:16:53,776] 2658 0001 com.net.ux.sip TRACE (Executive.cpp:1297) - checkOrdinalAll: ObjectToken:: StringIndex(proxy-authorization) Ordinal(1)
[2012-01-10 13:16:53,776] 2659 0001 com.net.ux.sip TRACE (Executive.cpp:823) - headerRegexModify: Header regex single ordinal
[2012-01-10 13:16:53,776] 2660 0001 com.net.ux.sip TRACE (SipMessage.cpp:1312) - getObjectValue: name:(3:Header) value:
[2012-01-10 13:16:53,776] 2661 0001 com.net.ux.sip TRACE (Executive.cpp:859) - doHeaderRegexModify: Executing headerRegex modify, Header to change: Digest realm="Realm", nonce="MTM1NTMxMTYwNjE0N2NhYWRhYWZkZjY0NzVkYmNmMTRmZGY3ZjVlMjVhZWJl",algorithm=MD5,qop=auth, username="tech_1723207030", uri="<sip:01274662967@80.193.254.193:5060;user=phone>", response="c3aec7cea80019ca04a9bb064383fb9d", cnonce="bef5a3cc", nc=00000001
[2012-01-10 13:16:53,777] 2662 0001 com.net.ux.sip TRACE (Executive.cpp:872) - doHeaderRegexModify: Header after Regex change: Digest realm="Realm", nonce="MTM1NTMxMTYwNjE0N2NhYWRhYWZkZjY0NzVkYmNmMTRmZGY3ZjVlMjVhZWJl",algorithm=MD5,qop=auth, username="tech_1723207030", uri="sip:01274662967@80.193.254.193:5060;user=phone", response="c3aec7cea80019ca04a9bb064383fb9d", cnonce="bef5a3cc", nc=00000001
[2012-01-10 13:16:53,777] 2663 0001 com.net.ux.sip TRACE (SipMessage.cpp:1392) - setObjectValue: name:(3:Header) value:Digest realm="Realm", nonce="MTM1NTMxMTYwNjE0N2NhYWRhYWZkZjY0NzVkYmNmMTRmZGY3ZjVlMjVhZWJl",algorithm=MD5,qop=auth, username="tech_1723207030", uri="sip:01274662967@80.193.254.193:5060;user=phone", response="c3aec7cea80019ca04a9bb064383fb9d", cnonce="bef5a3cc", nc=00000001
[2012-01-10 13:16:53,777] 2664 0001 com.net.ux.sip TRACE (Executive.cpp:218) - processMessageRule: HeaderRule executed
[2012-01-10 13:16:53,778] 2665 0001 com.net.ux.sip TRACE (Executive.cpp:81) - Run: Message Rule (15) matched at least one message rule
[2012-01-10 13:16:53,778] 2666 0001 com.net.ux.sip DEBUG (Transaction.cpp:699) - egressProtocolRepair: Transaction Protocol Repair, out of Egress executive
[201
INVITE sip:3539@demo6.vx.net:5060 SIP/2.0
Allow: INVITE, ACK, CANCEL, BYE, UPDATE, NOTIFY, OPTIONS, REFER, REGISTER
Call-ID: call-F2D72600-0000-0010-0C13-11@10.1.1.74
Contact: <sip:anonymous@10.1.1.74:5060;transport=TCP>
Content-Length: 256
Content-Type: application/sdp
CSeq: 1 INVITE
From:  <sip:anonymous@10.1.1.74:5060>;tag=a01014a-636
Max-Forwards: 70
P-Asserted-Identity:  <sip:anonymous@10.1.1.74:5060>
Privacy: critical
Proxy-Authorization: Digest realm="Realm", nonce="MTM1NTMxMTYwNjE0N2NhYWRhYWZkZjY0NzVkYmNmMTRmZGY3ZjVlMjVhZWJl",algorithm=MD5,qop=auth, username="tech_1723207030", uri="sip:01274662967@80.193.254.193:5060;user=phone", response="c3aec7cea80019ca04a9bb064383fb9d", cnonce="bef5a3cc", nc=00000001
Supported: replaces,update,100rel
To:  <sip:3539@demo6.vx.net:5060>
User-Agent: NET UX 2.2.1v187 UX
Via: SIP/2.0/TCP 10.1.1.74:5060;branch=z9hG4bK-UX-0a01-014a-3e87
  • No labels