Author: keith
Date: Wed Aug  6 11:31:50 2008
New Revision: 20489
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=20489

Log:
Using the customProtocolFactory in Proxy only when https sites are called


Modified:
   trunk/mashup/java/modules/www/WSRequestXSSproxy.jsp

Modified: trunk/mashup/java/modules/www/WSRequestXSSproxy.jsp
URL: 
http://wso2.org/svn/browse/wso2/trunk/mashup/java/modules/www/WSRequestXSSproxy.jsp?rev=20489&r1=20488&r2=20489&view=diff
==============================================================================
--- trunk/mashup/java/modules/www/WSRequestXSSproxy.jsp (original)
+++ trunk/mashup/java/modules/www/WSRequestXSSproxy.jsp Wed Aug  6 11:31:50 2008
@@ -142,11 +142,13 @@
 
     opts.setTo(new EndpointReference(uri));
     PersistenceManager pm = new PersistenceManager();
-    String adminUsername = 
pm.getConfigurationProperty(MashupConstants.PRIMARY_USER_ID);
-    if (adminUsername != null) {
+    if (uri.startsWith("https")) {
+        String adminUsername = 
pm.getConfigurationProperty(MashupConstants.PRIMARY_USER_ID);
+        if (adminUsername != null) {
             ProtocolSocketFactory psf = new 
CustomProtocolSocketFactory(adminUsername);
             Protocol protocol = new Protocol("custom-https", psf, 443);
             opts.setProperty(HTTPConstants.CUSTOM_PROTOCOL_HANDLER, protocol);
+        }
     }
 
     // Parse

_______________________________________________
Mashup-dev mailing list
[email protected]
http://mailman.wso2.org/cgi-bin/mailman/listinfo/mashup-dev

Reply via email to