diff --git a/UPGRADE.txt b/UPGRADE.txt
index a8eccb4ea963f93304e0e0e079deb6b60561f01c..82374eb59f69b267d7a9992c2da097862e38d142 100644
--- a/UPGRADE.txt
+++ b/UPGRADE.txt
@@ -121,6 +121,11 @@ Channel Drivers:
   Asterisk, but will be removed in the following version. Please use the groupcount functions
   in the dialplan to enforce call limits. The "limitonpeer" configuration option is
   now renamed to "counteronpeer".
+* SIP: The "username" option is now renamed to "defaultuser" to match "defaultip".
+  These are used only before registration to call a peer with the uri 
+	sip:defaultuser@defaultip
+  The "username" setting still work, but is deprecated and will not work in 
+  the next version of Asterisk.
 
 * chan_local.c: the comma delimiter inside the channel name has been changed to a
   semicolon, in order to make the Local channel driver compatible with the comma
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 26965318d3b148c7f3dfa944c9ec23d93df56739..06a84b5c53fc9366a5a24eace57522ad56e805fb 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -2887,7 +2887,7 @@ static int sip_sendtext(struct ast_channel *ast, const char *text)
 	that name and store that in the "regserver" field in the sippeers
 	table to facilitate multi-server setups.
 */
-static void realtime_update_peer(const char *peername, struct sockaddr_in *sin, const char *username, const char *fullcontact, int expirey)
+static void realtime_update_peer(const char *peername, struct sockaddr_in *sin, const char *defaultuser, const char *fullcontact, int expirey)
 {
 	char port[10];
 	char ipaddr[INET_ADDRSTRLEN];
@@ -2916,11 +2916,11 @@ static void realtime_update_peer(const char *peername, struct sockaddr_in *sin,
 	if (fc)
 		ast_update_realtime(tablename, "name", peername, "ipaddr", ipaddr,
 			"port", port, "regseconds", regseconds,
-			"username", username, fc, fullcontact, syslabel, sysname, NULL); /* note fc and syslabel _can_ be NULL */
+			"defaultuser", defaultuser, fc, fullcontact, syslabel, sysname, NULL); /* note fc and syslabel _can_ be NULL */
 	else
 		ast_update_realtime(tablename, "name", peername, "ipaddr", ipaddr,
 			"port", port, "regseconds", regseconds,
-			"username", username, syslabel, sysname, NULL); /* note syslabel _can_ be NULL */
+			"defaultuser", defaultuser, syslabel, sysname, NULL); /* note syslabel _can_ be NULL */
 }
 
 /*! \brief Automatically add peer extension to dial plan */
@@ -8660,7 +8660,7 @@ static void destroy_association(struct sip_peer *peer)
 
 	if (!sip_cfg.ignore_regexpire) {
 		if (peer->rt_fromcontact)
-			ast_update_realtime(tablename, "name", peer->name, "fullcontact", "", "ipaddr", "", "port", "", "regseconds", "0", "username", "", "regserver", "", NULL);
+			ast_update_realtime(tablename, "name", peer->name, "fullcontact", "", "ipaddr", "", "port", "", "regseconds", "0", "defaultuser", "", "regserver", "", NULL);
 		else 
 			ast_db_del("SIP/Registry", peer->name);
 	}
@@ -17961,7 +17961,7 @@ static struct sip_peer *build_peer(const char *name, struct ast_variable *v, str
 			peer->callingpres = ast_parse_caller_presentation(v->value);
 			if (peer->callingpres == -1)
 				peer->callingpres = atoi(v->value);
-		} else if (!strcasecmp(v->name, "username")) {
+		} else if (!strcasecmp(v->name, "username") | !strcmp(v->name, "defaultuser")) {	/* "username" is deprecated */
 			ast_copy_string(peer->username, v->value, sizeof(peer->username));
 		} else if (!strcasecmp(v->name, "language")) {
 			ast_copy_string(peer->language, v->value, sizeof(peer->language));
diff --git a/configs/sip.conf.sample b/configs/sip.conf.sample
index 91792bd612b92f456e860ecbd9666dc19ba918fc..131bc07ae6ef497b3faf8905c4c3f7966abd67a4 100644
--- a/configs/sip.conf.sample
+++ b/configs/sip.conf.sample
@@ -582,7 +582,6 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 ; maxcallbitrate	      maxcallbitrate
 ; rfc2833compensate           mailbox
 ;			      busylevel
-;                             username
 ;                             template
 ;                             fromdomain
 ;                             regexten
@@ -591,6 +590,7 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 ;                             port
 ;                             qualify
 ;                             defaultip
+;                             defaultuser
 ;                             rtptimeout
 ;                             rtpholdtimeout
 ;                             sendrpid
@@ -610,7 +610,7 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 ;[sip_proxy-out]
 ;type=peer          			; we only want to call out, not be called
 ;secret=guessit
-;username=yourusername			; Authentication user for outbound proxies
+;defaultuser=yourusername		; Authentication user for outbound proxies
 ;fromuser=yourusername			; Many SIP providers require this!
 ;fromdomain=provider.sip.domain	
 ;host=box.provider.com
@@ -625,7 +625,7 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 ;[provider1]
 ;type=peer
 ;host=sip.provider1.com
-;username=4015552299		; how your provider knows you
+;fromuser=4015552299		; how your provider knows you
 ;secret=youwillneverguessit
 ;callbackextension=123		; Register with this server and require calls coming back to this extension
 
@@ -760,7 +760,8 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 ;secret=blahpoly
 ;host=dynamic			; This peer register with us
 ;dtmfmode=rfc2833		; Choices are inband, rfc2833, or info
-;username=polly			; Username to use in INVITE until peer registers
+;defaultuser=polly		; Username to use in INVITE until peer registers
+;defaultip=192.168.40.123
 				; Normally you do NOT need to set this parameter
 ;disallow=all
 ;allow=ulaw                     ; dtmfmode=inband only works with ulaw or alaw!
@@ -801,7 +802,7 @@ srvlookup=yes			; Enable DNS SRV lookups on outbound calls
 				; support this (especially if one of them is 
 				; behind a NAT).
 ;defaultip=192.168.0.4		; IP address to use until registration
-;username=goran			; Username to use when calling this device before registration
+;defaultuser=goran		; Username to use when calling this device before registration
 				; Normally you do NOT need to set this parameter
 ;setvar=CUSTID=5678		; Channel variable to be set for all calls from this device