chan_sip: Optionally supply fromuser/fromdomain in SIP dial string.

Previously you could add [!dnid] to the SIP dial string to alter the To:
header. This change allows you to alter the From header as well.

SIP dial string extra options now look like this:

    [![touser[@todomain]][![fromuser][@fromdomain]]]

INCOMPATIBLE CHANGE: If you were using an exclamation mark in your To:
header, that is no longer possible.

ASTERISK-25803 #close

Change-Id: I2457e9ba7a89eb1da22084bab5a4d4328e189db7
This commit is contained in:
Walter Doekes
2016-02-19 11:30:15 +01:00
parent 6fc57b3e1f
commit c00082329e
4 changed files with 63 additions and 3 deletions

View File

@@ -24,6 +24,9 @@
; SIP/devicename/extension
; SIP/devicename/extension/IPorHost
; SIP/username@domain//IPorHost
; And to alter the To: or the From: header, you can additionally append
; the following to any of the above strings:
; [![touser[@todomain]][![fromuser][@fromdomain]]]
;
;
; Devicename
@@ -57,6 +60,14 @@
;
; SIP/sales@mysipproxy!sales@edvina.net
;
; (Specifying only @todomain without touser will create an invalid SIP
; request.)
;
; Similarly, you can specify the From header as well, after a second
; exclamation mark:
;
; SIP/customer@mysipproxy!!customersupport@wearespindle.com
;
; A new feature for 1.8 allows one to specify a host or IP address to use
; when routing the call. This is typically used in tandem with func_srv if
; multiple methods of reaching the same domain exist. The host or IP address