Change From "asterisk" on options ping


#1

How do you change the default From: header for Asterisk originated messages like options?

Example:

From: “asterisksip:[b]asterisk[/b]@192.168.1.1:5080;tag=as3383be41.

Contact: sip:[b]asterisk[/b]@192.168.1.1:5080.


#2

This is being taken from DEFAULT_CALLERID in chan_sip.c. It looks like this is overridden by the caller ID specified in the global section. Moreover, it looks like fromuser takes precedence, and if you don’t have RPID, denying caller ID will set it to Unknown, but with lower precedence than fromuser.

The logic that applies most of this chain of default is in initreqprep() in chan_sip.c. The override by the global caller ID is in the configuration file option processing.