harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From telli...@apache.org
Subject svn commit: r832457 - /harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java
Date Tue, 03 Nov 2009 15:36:54 GMT
Author: tellison
Date: Tue Nov  3 15:36:53 2009
New Revision: 832457

URL: http://svn.apache.org/viewvc?rev=832457&view=rev
Log:
Part of HARMONY-6367 ([classlib] Some Methods doesn't have security Permissions check as compared
to SUN JDK)
Perform a putProviderProperty test for Provider.load(InputStream).

Modified:
    harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java

Modified: harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java?rev=832457&r1=832456&r2=832457&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/security/src/main/java/common/java/security/Provider.java
Tue Nov  3 15:36:53 2009
@@ -193,6 +193,10 @@
 
     @Override
     public synchronized void load(InputStream inStream) throws IOException {
+        SecurityManager sm = System.getSecurityManager();
+        if (sm != null) {
+            sm.checkSecurityAccess("putProviderProperty." + name); //$NON-NLS-1$
+        }
         Properties tmp = new Properties();
         tmp.load(inStream);
         myPutAll(tmp);



Mime
View raw message