[jboss-remoting-commits] JBoss Remoting SVN: r3779 - remoting2/branches/2.x/src/main/org/jboss/remoting/transport/http.
jboss-remoting-commits at lists.jboss.org
jboss-remoting-commits at lists.jboss.org
Wed Mar 26 03:24:49 EDT 2008
Author: ron.sigal at jboss.com
Date: 2008-03-26 03:24:49 -0400 (Wed, 26 Mar 2008)
New Revision: 3779
Modified:
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/http/HTTPClientInvoker.java
Log:
JBREM-934: Put System.getProperty() in AccessController.doPrivileged() calls.
Modified: remoting2/branches/2.x/src/main/org/jboss/remoting/transport/http/HTTPClientInvoker.java
===================================================================
--- remoting2/branches/2.x/src/main/org/jboss/remoting/transport/http/HTTPClientInvoker.java 2008-03-26 05:28:46 UTC (rev 3778)
+++ remoting2/branches/2.x/src/main/org/jboss/remoting/transport/http/HTTPClientInvoker.java 2008-03-26 07:24:49 UTC (rev 3779)
@@ -868,7 +868,20 @@
}
if (username == null || username.length() == 0)
{
- username = System.getProperty("http.basic.username");
+ try
+ {
+ username = (String)AccessController.doPrivileged( new PrivilegedExceptionAction()
+ {
+ public Object run() throws Exception
+ {
+ return System.getProperty("http.basic.username");
+ }
+ });
+ }
+ catch (PrivilegedActionException e)
+ {
+ log.debug("error", e.getCause());
+ }
}
if (metadata != null)
{
@@ -876,7 +889,20 @@
}
if (password == null)
{
- password = System.getProperty("http.basic.password");
+ try
+ {
+ password = (String)AccessController.doPrivileged( new PrivilegedExceptionAction()
+ {
+ public Object run() throws Exception
+ {
+ return System.getProperty("http.basic.password");
+ }
+ });
+ }
+ catch (PrivilegedActionException e)
+ {
+ log.debug("error", e.getCause());
+ }
}
if (username != null && password != null)
More information about the jboss-remoting-commits
mailing list