Configuring SIP Header Manipulation Element Rules

Element rules are a subset of the SIP header manipulation rules and are applied at the element type level rather than at the entire header value.

To configure dynamic SIP header manipulation rules:

  1. In Superuser mode, type configure terminal and press Enter.
    ORACLE# configure terminal
  2. Type session-router and press Enter to access the signaling-level configuration elements.
    ORACLE(configure)# session-router
    ORACLE(session-router)#
  3. Type sip-manipulation and press Enter.
    ORACLE(session-router)# sip-manipulation
    ORACLE(sip-manipulation)#
  4. Type header-rules and press Enter.
    ORACLE(sip-manipulation)# header-rules
  5. Type element-rules and press Enter.
    ORACLE(sip-header-rules)# element-rules
    ORACLE(sip-element-rules)#
  6. name—Enter the unique identifier for this element rule. There is no default for this value.
  7. parameter-name—Enter the SIP header parameter/element on which you want the Oracle® Enterprise Session Border Controller (E-SBC) to use this rule. There is no default for this parameter.
  8. type—Specify the type of parameter to which this element rule will be applied. The default value is none. The valid values are:
    • header-value | header-param-name | header-param | uri-display | uri-user | uri-user-param | uri-host | uri-port | uri-param-name | uri-param | uri-header-name | uri-header

      To configure HMR so that there is impact only on the status-line; the value will be used for matching according to the comparison-type:

    • status-code—Designates the status code of the response line; accepts any string, but during the manipulation process only recognizes the range from 1 to 699.

    • reason-phrase—Designates the reason of the response line; accepts any string.

  9. match-val-type—Enter the value type that you want to match when this rule is applied. The default value is ANY. Valid values are:
    • IP | FQDN | ANY

  10. comparison-type—Enter the way that you want SIP headers to be compared from one of the available. This choice dictates how the E-SBC processes the match rules against the SIP header parameter/element. The default is refer-case-sensitive.
    • boolean | refer-case-sensitive | refer-case-insensitive | pattern-rule

  11. action—Enter the action that you want this rule to perform on the SIP header parameter/element. The default is none. The valid rules are:
    • add | replace | delete-element | delete-header | store | none

      Remember that you should enter rules with the action type store before you enter rules with other types of actions.

      When you set the action type to store, the E-SBC always treats the match value you enter as a regular expression. As a default, the regular expression is uses for the match value is .+ (which indicates a match value of at least one character), unless you set a more specific regular expression match value.

  12. match-value—Enter the value to match against the header value in SIP packets; the E-SBC matches these against the value of the parameter/element. This is where you can enter values to match using regular expression values, or stored pattern matches. Your entries can contain Boolean operators.

    When you configure HMR (using SIP manipulation rules, elements rules, etc.), you can now use escape characters in the match-value parameter to support escaping Boolean and string manipulation operators..

    You can also escape the escape character itself, so that it is used as a literal string. For example, the E-SBC now treats the string \+1234 as +1234.

    The following are escape characters: +, -, +^, -^, &, |, \, (, ), ., $, ^, and “.

    You can also use two variables, $REMOTE_PORT and $LOCAL_PORT, which resolve respectively to the far-end and remote UDP or TCP port value.

  13. new-value—When the action parameter is set to add or to manipulate, enter the new value that you want to substitute for the entire header value. This is where you can set stored regular expression values for the E-SBC to use when it adds or manipulates parameters/elements.

    When you configure HMR (using SIP manipulation rules, elements rules, etc.), you can now use escape characters in the new-value parameter to support escaping Boolean and string manipulation operators..

    You can also escape the escape character itself, so that it is used as a literal string. For example, the E-SBC now treats the string \+1234 as +1234.

    The following are escape characters: +, -, +^, -^, &, |, \, (, ), ., $, ^, and “.

    You can also use two variables, $REMOTE_PORT and $LOCAL_PORT, which resolve respectively to the far-end and remote UDP or TCP port value.