summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChia-chi Yeh <chiachi@android.com>2010-12-15 15:34:35 +0800
committerChia-chi Yeh <chiachi@android.com>2010-12-18 23:26:12 +0800
commit2ad6621ec6cbc10836ef05ca965077fc059b2bf8 (patch)
tree68303a9a75d586efd3676da1135f66050f0da4ac
parente227057e5d8bd669bda98d9f2c2ec07693295bef (diff)
downloadnist-sip-2ad6621ec6cbc10836ef05ca965077fc059b2bf8.tar.gz
Only add maddr to the uri when it is different from the host.
Bug: 3284110 Change-Id: Ib167dab4f37f799f497c787d1bc861539fd900c7
-rw-r--r--java/gov/nist/javax/sip/clientauthutils/AuthenticationHelperImpl.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/java/gov/nist/javax/sip/clientauthutils/AuthenticationHelperImpl.java b/java/gov/nist/javax/sip/clientauthutils/AuthenticationHelperImpl.java
index c15b569..aa29616 100644
--- a/java/gov/nist/javax/sip/clientauthutils/AuthenticationHelperImpl.java
+++ b/java/gov/nist/javax/sip/clientauthutils/AuthenticationHelperImpl.java
@@ -211,6 +211,9 @@ public class AuthenticationHelperImpl implements AuthenticationHelper {
if ( challengedRequest.getRouteHeaders() == null ) {
Hop hop = ((SIPClientTransaction) challengedTransaction).getNextHop();
SipURI sipUri = (SipURI) reoriginatedRequest.getRequestURI();
+ // BEGIN android-added
+ if ( !hop.getHost().equalsIgnoreCase(sipUri.getHost()) )
+ // END android-added
sipUri.setMAddrParam(hop.getHost());
if ( hop.getPort() != -1 ) sipUri.setPort(hop.getPort());
}