You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by se...@apache.org on 2007/03/13 21:58:45 UTC

svn commit: r517867 - in /jakarta/jmeter/branches/rel-2-2: bin/jmeter.properties src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java xdocs/changes.xml

Author: sebb
Date: Tue Mar 13 13:58:44 2007
New Revision: 517867

URL: http://svn.apache.org/viewvc?view=rev&rev=517867
Log:
Change HttpClient proxy definition to use NTCredentials; added http.proxyDomain property for this

Modified:
    jakarta/jmeter/branches/rel-2-2/bin/jmeter.properties
    jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
    jakarta/jmeter/branches/rel-2-2/xdocs/changes.xml

Modified: jakarta/jmeter/branches/rel-2-2/bin/jmeter.properties
URL: http://svn.apache.org/viewvc/jakarta/jmeter/branches/rel-2-2/bin/jmeter.properties?view=diff&rev=517867&r1=517866&r2=517867
==============================================================================
--- jakarta/jmeter/branches/rel-2-2/bin/jmeter.properties (original)
+++ jakarta/jmeter/branches/rel-2-2/bin/jmeter.properties Tue Mar 13 13:58:44 2007
@@ -296,6 +296,12 @@
 #jmeter.httpsampler=HTTPSampler2
 
 #---------------------------------------------------------------------------
+# JMeter Proxy configuration
+#---------------------------------------------------------------------------
+# use command-line flags for user-name and password
+#http.proxyDomain=NTLM domain, if required by HTTPClient sampler
+
+#---------------------------------------------------------------------------
 # HTTPSampleResponse Parser configuration
 #---------------------------------------------------------------------------
 

Modified: jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
URL: http://svn.apache.org/viewvc/jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java?view=diff&rev=517867&r1=517866&r2=517867
==============================================================================
--- jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java (original)
+++ jakarta/jmeter/branches/rel-2-2/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java Tue Mar 13 13:58:44 2007
@@ -105,6 +105,9 @@
     static final String PROXY_PASS = 
         JMeterUtils.getPropDefault(JMeter.HTTP_PROXY_PASS,""); // $NON-NLS-1$
     
+    private static final String PROXY_DOMAIN = 
+        JMeterUtils.getPropDefault("http.proxyDomain",""); // $NON-NLS-1$ $NON-NLS-2$
+    
     static InetAddress localAddress = null;
     
     private static final String localHost;
@@ -339,7 +342,7 @@
                 if (PROXY_USER.length() > 0){
                     httpClient.getState().setProxyCredentials(
                         new AuthScope(PROXY_HOST,PROXY_PORT,null,AuthScope.ANY_SCHEME),
-                        new UsernamePasswordCredentials(PROXY_USER,PROXY_PASS)
+                        new NTCredentials(PROXY_USER,PROXY_PASS,localHost,PROXY_DOMAIN)
                     );
                 }
             }

Modified: jakarta/jmeter/branches/rel-2-2/xdocs/changes.xml
URL: http://svn.apache.org/viewvc/jakarta/jmeter/branches/rel-2-2/xdocs/changes.xml?view=diff&rev=517867&r1=517866&r2=517867
==============================================================================
--- jakarta/jmeter/branches/rel-2-2/xdocs/changes.xml (original)
+++ jakarta/jmeter/branches/rel-2-2/xdocs/changes.xml Tue Mar 13 13:58:44 2007
@@ -177,6 +177,7 @@
 </ul>
 </li>
 <li>Bug 40325 - allow specification of proxyuser and proxypassword for WebServiceSampler</li>
+<li>Change HttpClient proxy definition to use NTCredentials; added http.proxyDomain property for this</li>
 </ul>
 
 <h3>Version 2.2</h3>



---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org