Replaces Header Support

The Oracle® Enterprise Session Border Controller (E-SBC) supports the Replaces: header in SIP messages according to RFC 3891. The header, included within SIP INVITE messages, provides a mechanism to replace an existing early or established dialog with a different dialog. The different dialog can be used for services such as call parking, attended call transfer and various conferencing features.

The Replaces: header specifies the dialog to replace by containing the corresponding dialog identifier. The identifier includes the from tag, to tag, and call id. The orientation of endpoint-created tags, as from-tag and to-tag, matches each of the two dialogs for a standard call. For example, the Replaces: header from an endpoint that specifies assuming the dialog between the E-SBC and Bob-1 appears as follows:

Replaces:5555;from-tag=20;to-tag=10

The E-SBC validates the dialog identifier by matching an existing dialog, tries to install the new endpoint, and tries to remove the old endpoint by gracefully ending that dialog with a BYE. The replaces INVITE must come from an endpoint in the same realm as the endpoint it is replacing. If the UA sending the Replaces header is in a different realm as the original call leg (or indicates such architecture from a malformed Replaces: header), the E-SBC replies to the Replaces: endpoint with a 481 Missing Dialog. Refer to the following diagram for the standard scenario.

The OCSBC supporting the REPLACES header

Note that when the endpoints are in the same realm, you must enable the mm-in-realm parameter in realm-config or the E-SBC cannot generate the SDP for the 200 OK. Without the SDP, the call is unsuccessful.

New SDP Parameters in INVITE with Replaces

When an INVITE with Replaces: header is received, the media parameters in the new SDP are compared against the SDP of the dialog to be replaced. If any portion of the SDPs (excluding the session-origin line) is different, then the media must be renegotiated. The Oracle® Enterprise Session Border Controller sends a re-INVITE with the new SDP to the dialog opposite of the one being replaced as shown below. If the re-INVITE fails for any reason, then the original dialogs will remain.

The OCSBC supporting SDP renegotiation after a re-INVITE with Replaces header.

Early Dialog Replacement

An INVITE with Replaces: header can replace an early dialog. That is, a dialog where the final 2xx class response to INVITE request has not arrived yet. The Oracle® Enterprise Session Border Controller completes the originating side of the call with a 200 OK. The original dialog with the terminator is cancelled. SDP from the new terminator can be renegotiated if it changes.

The OCSBC using the Replaces header to replace and early dialog.

The SDP from the original 183 response is used for the 200 response back to the originator if present to complete the early transaction. If reliable provisional messages are used, then no SDP is included in the 200 response.

If no SDP is present in any of the provisional messages, then the Oracle® Enterprise Session Border Controller constructs it from the original offer and modifying the IP port information for each c= and m= line with information from the INVITE with Replaces: header. If there are more m= lines in the original offer than ports from the INVITE with Replaces: header, then the extra ports are disabled with port value of 0. If no SDP was offered in the original INVITE, then the SDP from the INVITE with Replaces: header is used as the offer in the 200 OK.

If the SDP media parameters were compatible between the replaced and replacing SDPs, then media does not need to be renegotiated and no re-INVITE is created. If the re-INVITE fails, the original dialogs are torn down using a BYE for the original server dialog.

INVITE with Replaces in Early Dialog Server Side

The Oracle® Enterprise Session Border Controller does not support replacing an early server dialog. It replies with a 481 (Dialog/Transaction does not exist) response to the endpoint requesting the replace.

The OCSBC rejecting and early server dialog.

Replace Header Configuration

Replaces: header support is configured in the session-agent, realm, or sip-interface via the sip-profile configuration element. sip-profiles are defined once and attached to a chosen interface, realm or session-agent.

The replace-dialogs parameter is set to either enabled or disabled. In addition, you may set this parameter to inherit which uses the next lower order of precedence object. If there are no sip-profiles referenced in the higher ordered object, or if all the replace-dialogs parameters are set to inherit, then the feature is disabled.

To configure Replaces: header support:

  1. In Superuser mode, type configure terminal and press Enter.
    ORACLE# configure terminal
    ORACLE(configure)#
  2. Type session-router and press Enter.
    ORACLE(configure)# session-router
    ORACLE(session-router)#
  3. Type sip-profile and press Enter. If you are adding this feature to an existing configuration, then remember you must select the configuration you want to edit.
    ORACLE (session-router)# sip-profile
    ORACLE(sip-profile)#
  4. replace-dialogs—Set this parameter to enabled to enable Replaces: header support. A replaces parameter is also inservted in the Supported: header as sent into the realm where this sip profile is applied. You may also set this parameter to inherit for the element which this sip-profile is applied to, to inheret the value from the next-lower element.
  5. Type done to save your work and continue.

Debugging

show sipd status

Includes Replaced Dialogs counts to show successfully replaced dialogs:

# show sipd status
17:41:38-142
SIP Status                -- Period -- -------- Lifetime --------
                Active    High   Total      Total  PerMax    High
Replaced Dialogs     -       -       1          1       1

show sipd errors

Includes Replace Dialog Fails to show failed dialog replacements. This counter is incremented only when the dialog replacement attempt actually occurred but failed to successfully complete.

# show sipd errors
17:58:04-181
SIP Errors/Events             ---- Lifetime ----
                       Recent      Total  PerMax
Replace Dialog Fails        0          0       0