Home
last modified time | relevance | path

Searched refs:permission (Results 1 – 25 of 44) sorted by relevance

12

/libcore/luni/src/test/java/libcore/java/security/
DBasicPermissionTest.java39 BasicPermission permission = new TestPermission("name"); in testImplies() local
41 assertTrue(permission.implies(null)); in testImplies()
42 assertTrue(permission.implies(permission)); in testImplies()
43 assertTrue(permission.implies(permission2)); in testImplies()
48 BasicPermission permission = new TestPermission("name"); in testCheckGuard_doesntThrow() local
49 permission.checkGuard(null); in testCheckGuard_doesntThrow()
50 permission.checkGuard(new Object()); in testCheckGuard_doesntThrow()
51 permission.checkGuard(permission); in testCheckGuard_doesntThrow()
DAllPermissionTest.java33 AllPermission permission = new AllPermission("Test permission", action); in testGetAction() local
35 assertNull(permission.getActions()); in testGetAction()
40 AllPermission permission = new AllPermission(); in testImplies() local
42 assertTrue(permission.implies(null)); in testImplies()
43 assertTrue(permission.implies(permission)); in testImplies()
44 assertTrue(permission.implies(permission2)); in testImplies()
DSecurityPermissionTest.java32 SecurityPermission permission = new SecurityPermission("name", "action"); in testConstructor() local
35 assertEquals("", permission.getName()); in testConstructor()
36 assertEquals("", permission.getActions()); in testConstructor()
DAccessControlExceptionTest.java36 Permission permission = new AllPermission(); in testConstructor() local
45 throw new AccessControlException(msg, permission); in testConstructor()
48 assertSame(permission, e.getPermission()); in testConstructor()
DPermissionCollectionTest.java35 public void add(Permission permission) { in add() argument
39 public boolean implies(Permission permission) { in implies() argument
DAccessControllerTest.java97 final Permission permission = new RuntimePermission("do stuff"); in assertActionRun() local
103 AccessController.getContext().checkPermission(permission); in assertActionRun()
109 AccessController.getContext().checkPermission(permission); in assertActionRun()
DProtectionDomainTest.java110 public void add(Permission permission) { in add() argument
114 public boolean implies(Permission permission) { in implies() argument
/libcore/ojluni/src/test/java/util/concurrent/tck/
Dtck.policy3 permission java.lang.RuntimePermission "modifyThread";
4 permission java.lang.RuntimePermission "getClassLoader";
5 permission java.lang.RuntimePermission "setContextClassLoader";
6 permission java.util.PropertyPermission "*", "read";
8 permission java.security.SecurityPermission "getPolicy";
9 permission java.security.SecurityPermission "setPolicy";
10 permission java.security.SecurityPermission "setSecurityManager";
12 permission java.lang.RuntimePermission "accessDeclaredMembers";
13 permission java.io.FilePermission "<<ALL FILES>>", "read";
14 permission java.lang.reflect.ReflectPermission "suppressAccessChecks";
/libcore/luni/src/test/java/libcore/javax/net/ssl/
DSSLPermissionTest.java26 SSLPermission permission = new SSLPermission("name"); in testSslPermissions_constructor_LString() local
28 assertEquals("", permission.getName()); in testSslPermissions_constructor_LString()
29 assertEquals("", permission.getActions()); in testSslPermissions_constructor_LString()
33 SSLPermission permission = new SSLPermission("name", "actions"); in testSslPermission_constructor_LString_LString() local
35 assertEquals("", permission.getName()); in testSslPermission_constructor_LString_LString()
36 assertEquals("", permission.getActions()); in testSslPermission_constructor_LString_LString()
/libcore/ojluni/src/main/java/java/security/acl/
DAclEntry.java111 public boolean addPermission(Permission permission); in addPermission() argument
121 public boolean removePermission(Permission permission); in removePermission() argument
132 public boolean checkPermission(Permission permission); in checkPermission() argument
DAcl.java232 public boolean checkPermission(Principal principal, Permission permission); in checkPermission() argument
/libcore/ojluni/src/main/java/java/security/
DUnresolvedPermissionCollection.java74 public void add(Permission permission) in add() argument
76 if (! (permission instanceof UnresolvedPermission)) in add()
78 permission); in add()
79 UnresolvedPermission up = (UnresolvedPermission) permission; in add()
108 public boolean implies(Permission permission) in implies() argument
DPolicy.java91 public boolean implies(ProtectionDomain domain, Permission permission) { in implies() argument
105 @Override public void add(Permission permission) { in add() argument
108 @Override public boolean implies(Permission permission) { in implies() argument
DPermissionCollection.java38 public abstract void add(Permission permission); in add() argument
40 public abstract boolean implies(Permission permission); in implies() argument
DPermissions.java41 public void add(Permission permission) { } in add() argument
43 public boolean implies(Permission permission) { return true; } in implies() argument
DPolicySpi.java58 (ProtectionDomain domain, Permission permission); in engineImplies() argument
DPermission.java44 public abstract boolean implies(Permission permission); in implies() argument
DProtectionDomain.java53 public boolean implies(Permission permission) { return true; } in implies() argument
/libcore/ojluni/src/main/java/sun/net/www/protocol/file/
DFileURLConnection.java216 Permission permission; field in FileURLConnection
222 if (permission == null) { in getPermission()
225 permission = new FilePermission(decodedPath, "read"); in getPermission()
227 permission = new FilePermission( in getPermission()
231 return permission; in getPermission()
/libcore/ojluni/src/main/native/
DFileSystemPreferences.c45 jclass thisclass, jstring java_fname, jint permission) { in Java_java_util_prefs_FileSystemPreferences_chmod() argument
48 result = chmod(fname, permission); in Java_java_util_prefs_FileSystemPreferences_chmod()
70 jclass thisclass, jstring java_fname, jint permission, jboolean shared) { in Java_java_util_prefs_FileSystemPreferences_lockFile0() argument
91 fd = open(fname, O_WRONLY|O_CREAT, permission); in Java_java_util_prefs_FileSystemPreferences_lockFile0()
/libcore/ojluni/src/main/java/javax/crypto/
DCryptoPermissions.java51 public void add(Permission permission) { } in add() argument
53 public boolean implies(Permission permission) { return true; } in implies() argument
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/
DIdentityScopeTest.java44 public void checkPermission(Permission permission){ in checkPermission() argument
45 if (denied!=null && denied.implies(permission)) throw new SecurityException(); in checkPermission()
DSignerTest.java51 public void checkPermission(Permission permission){ in checkPermission() argument
52 if (denied!=null && denied.implies(permission)) throw new SecurityException(); in checkPermission()
/libcore/ojluni/src/main/java/java/net/
DHttpURLConnection.java800 Permission permission = new SocketPermission(host, "connect"); in getPermission()
801 return permission; in getPermission()
/libcore/ojluni/src/test/javax/xml/jaxp/transform/
DXSLTExFuncTest.java240 for (Permission permission : permissions) { in SimplePolicy()
241 perms.add(permission); in SimplePolicy()

12