/frameworks/base/services/core/java/com/android/server/uri/ |
D | UriPermission.java | 64 int modeFlags = 0; field in UriPermission 98 final int oldModeFlags = modeFlags; in updateModeFlags() 99 modeFlags = ownedModeFlags | globalModeFlags | persistableModeFlags | persistedModeFlags; in updateModeFlags() 101 if (Log.isLoggable(TAG, Log.VERBOSE) && (modeFlags != oldModeFlags)) { in updateModeFlags() 105 + Integer.toHexString(modeFlags) + " via calling UID " in updateModeFlags() 115 void initPersistedModes(int modeFlags, long createdTime) { in initPersistedModes() argument 116 modeFlags &= (Intent.FLAG_GRANT_READ_URI_PERMISSION in initPersistedModes() 119 persistableModeFlags = modeFlags; in initPersistedModes() 120 persistedModeFlags = modeFlags; in initPersistedModes() 126 void grantModes(int modeFlags, UriPermissionOwner owner) { in grantModes() argument [all …]
|
D | UriGrantsManagerService.java | 185 final int modeFlags, int sourceUserId, int targetUserId) { in grantUriPermissionFromOwner() argument 209 modeFlags, owner, targetUserId); in grantUriPermissionFromOwner() 298 public void takePersistableUriPermission(Uri uri, final int modeFlags, in takePersistableUriPermission() argument 310 Preconditions.checkFlagsArgument(modeFlags, in takePersistableUriPermission() 322 && ((modeFlags & exactPerm.persistableModeFlags) == modeFlags); in takePersistableUriPermission() 324 && ((modeFlags & prefixPerm.persistableModeFlags) == modeFlags); in takePersistableUriPermission() 332 persistChanged |= exactPerm.takePersistableModes(modeFlags); in takePersistableUriPermission() 335 persistChanged |= prefixPerm.takePersistableModes(modeFlags); in takePersistableUriPermission() 362 public void releasePersistableUriPermission(Uri uri, final int modeFlags, in releasePersistableUriPermission() argument 375 Preconditions.checkFlagsArgument(modeFlags, in releasePersistableUriPermission() [all …]
|
D | UriGrantsManagerInternal.java | 36 final int modeFlags, UriPermissionOwner owner, int targetUserId); in grantUriPermission() argument 38 GrantUri grantUri, final int modeFlags); in revokeUriPermission() argument 39 boolean checkUriPermission(GrantUri grantUri, int uid, final int modeFlags); in checkUriPermission() argument 41 final int modeFlags, int lastTargetUid); in checkGrantUriPermission() argument 43 int callingUid, String targetPkg, Uri uri, int modeFlags, int userId); in checkGrantUriPermission() argument
|
/frameworks/base/tests/testables/src/android/testing/ |
D | TestableContext.java | 383 public int checkCallingOrSelfUriPermission(Uri uri, int modeFlags) { in checkCallingOrSelfUriPermission() argument 385 return mTestablePermissions.check(uri, modeFlags); in checkCallingOrSelfUriPermission() 387 return super.checkCallingOrSelfUriPermission(uri, modeFlags); in checkCallingOrSelfUriPermission() 391 public int checkCallingUriPermission(Uri uri, int modeFlags) { in checkCallingUriPermission() argument 393 return mTestablePermissions.check(uri, modeFlags); in checkCallingUriPermission() 395 return super.checkCallingUriPermission(uri, modeFlags); in checkCallingUriPermission() 399 public void enforceCallingOrSelfUriPermission(Uri uri, int modeFlags, String message) { in enforceCallingOrSelfUriPermission() argument 401 mTestablePermissions.enforce(uri, modeFlags); in enforceCallingOrSelfUriPermission() 403 super.enforceCallingOrSelfUriPermission(uri, modeFlags, message); in enforceCallingOrSelfUriPermission() 408 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags) { in checkUriPermission() argument [all …]
|
D | TestablePermissions.java | 64 int check(Uri uri, int modeFlags) { in check() argument 75 public void enforce(Uri uri, int modeFlags) { in enforce() argument 76 if (check(uri, modeFlags) != PackageManager.PERMISSION_GRANTED) { in enforce()
|
/frameworks/base/core/java/android/content/ |
D | ContextWrapper.java | 837 public void grantUriPermission(String toPackage, Uri uri, int modeFlags) { in grantUriPermission() argument 838 mBase.grantUriPermission(toPackage, uri, modeFlags); in grantUriPermission() 842 public void revokeUriPermission(Uri uri, int modeFlags) { in revokeUriPermission() argument 843 mBase.revokeUriPermission(uri, modeFlags); in revokeUriPermission() 847 public void revokeUriPermission(String targetPackage, Uri uri, int modeFlags) { in revokeUriPermission() argument 848 mBase.revokeUriPermission(targetPackage, uri, modeFlags); in revokeUriPermission() 852 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags) { in checkUriPermission() argument 853 return mBase.checkUriPermission(uri, pid, uid, modeFlags); in checkUriPermission() 858 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags, IBinder callerToken) { in checkUriPermission() argument 859 return mBase.checkUriPermission(uri, pid, uid, modeFlags, callerToken); in checkUriPermission() [all …]
|
D | UriPermission.java | 42 public UriPermission(Uri uri, int modeFlags, long persistedTime) { in UriPermission() argument 44 mModeFlags = modeFlags; in UriPermission()
|
D | Context.java | 5080 @Intent.GrantUriMode int modeFlags); in grantUriPermission() argument 5110 public abstract void revokeUriPermission(Uri uri, @Intent.AccessUriMode int modeFlags); in revokeUriPermission() argument 5134 @Intent.AccessUriMode int modeFlags); in revokeUriPermission() argument 5158 @Intent.AccessUriMode int modeFlags); in checkUriPermission() argument 5163 @Intent.AccessUriMode int modeFlags, IBinder callerToken); in checkUriPermission() argument 5186 public abstract int checkCallingUriPermission(Uri uri, @Intent.AccessUriMode int modeFlags); in checkCallingUriPermission() argument 5206 @Intent.AccessUriMode int modeFlags); in checkCallingOrSelfUriPermission() argument 5232 @Intent.AccessUriMode int modeFlags); in checkUriPermission() argument 5252 Uri uri, int pid, int uid, @Intent.AccessUriMode int modeFlags, String message); in enforceUriPermission() argument 5272 Uri uri, @Intent.AccessUriMode int modeFlags, String message); in enforceCallingUriPermission() argument [all …]
|
D | ContentResolver.java | 2425 @Intent.AccessUriMode int modeFlags) { 2429 ContentProvider.getUriWithoutUserId(uri), modeFlags, /* toPackage= */ null, 2441 @Intent.AccessUriMode int modeFlags) { 2446 ContentProvider.getUriWithoutUserId(uri), modeFlags, toPackage, 2462 @Intent.AccessUriMode int modeFlags) { 2466 ContentProvider.getUriWithoutUserId(uri), modeFlags, /* toPackage= */ null,
|
D | Intent.java | 5849 public static boolean isAccessUriMode(int modeFlags) { in isAccessUriMode() argument 5850 return (modeFlags & (Intent.FLAG_GRANT_READ_URI_PERMISSION in isAccessUriMode()
|
/frameworks/base/test-mock/src/android/test/mock/ |
D | MockContext.java | 690 public void grantUriPermission(String toPackage, Uri uri, int modeFlags) { in grantUriPermission() argument 695 public void revokeUriPermission(Uri uri, int modeFlags) { in revokeUriPermission() argument 700 public void revokeUriPermission(String targetPackage, Uri uri, int modeFlags) { in revokeUriPermission() argument 705 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags) { in checkUriPermission() argument 711 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags, IBinder callerToken) { in checkUriPermission() argument 712 return checkUriPermission(uri, pid, uid, modeFlags); in checkUriPermission() 716 public int checkCallingUriPermission(Uri uri, int modeFlags) { in checkCallingUriPermission() argument 721 public int checkCallingOrSelfUriPermission(Uri uri, int modeFlags) { in checkCallingOrSelfUriPermission() argument 727 String writePermission, int pid, int uid, int modeFlags) { in checkUriPermission() argument 733 Uri uri, int pid, int uid, int modeFlags, String message) { in enforceUriPermission() argument [all …]
|
/frameworks/base/core/java/android/provider/ |
D | DocumentsProvider.java | 994 final int modeFlags = getCallingOrSelfUriPermissionModeFlags(context, uri); in canonicalize() local 995 context.grantUriPermission(getCallingPackage(), narrowUri, modeFlags); in canonicalize() local 1003 int modeFlags = 0; in getCallingOrSelfUriPermissionModeFlags() local 1006 modeFlags |= Intent.FLAG_GRANT_READ_URI_PERMISSION; in getCallingOrSelfUriPermissionModeFlags() 1010 modeFlags |= Intent.FLAG_GRANT_WRITE_URI_PERMISSION; in getCallingOrSelfUriPermissionModeFlags() 1015 modeFlags |= Intent.FLAG_GRANT_PERSISTABLE_URI_PERMISSION; in getCallingOrSelfUriPermissionModeFlags() 1017 return modeFlags; in getCallingOrSelfUriPermissionModeFlags() 1151 final int modeFlags = getCallingOrSelfUriPermissionModeFlags(context, in callUnchecked() local 1153 context.grantUriPermission(getCallingPackage(), newDocumentUri, modeFlags); in callUnchecked() local 1183 final int modeFlags = getCallingOrSelfUriPermissionModeFlags(context, in callUnchecked() local [all …]
|
/frameworks/base/core/java/android/app/ |
D | IUriGrantsManager.aidl | 28 void takePersistableUriPermission(in Uri uri, int modeFlags, String toPackage, int userId); in takePersistableUriPermission() argument 29 void releasePersistableUriPermission(in Uri uri, int modeFlags, String toPackage, int userId); in releasePersistableUriPermission() argument
|
D | ContextImpl.java | 1981 public void grantUriPermission(String toPackage, Uri uri, int modeFlags) { in grantUriPermission() argument 1985 ContentProvider.getUriWithoutUserId(uri), modeFlags, resolveUserId(uri)); in grantUriPermission() local 1992 public void revokeUriPermission(Uri uri, int modeFlags) { in revokeUriPermission() argument 1996 ContentProvider.getUriWithoutUserId(uri), modeFlags, resolveUserId(uri)); in revokeUriPermission() local 2003 public void revokeUriPermission(String targetPackage, Uri uri, int modeFlags) { in revokeUriPermission() argument 2007 ContentProvider.getUriWithoutUserId(uri), modeFlags, resolveUserId(uri)); in revokeUriPermission() local 2014 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags) { in checkUriPermission() argument 2017 ContentProvider.getUriWithoutUserId(uri), pid, uid, modeFlags, in checkUriPermission() 2026 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags, IBinder callerToken) { in checkUriPermission() argument 2029 ContentProvider.getUriWithoutUserId(uri), pid, uid, modeFlags, in checkUriPermission() [all …]
|
/frameworks/base/test-runner/src/android/test/ |
D | IsolatedContext.java | 113 int uid, int modeFlags) { in checkUriPermission() argument 118 public int checkUriPermission(Uri uri, int pid, int uid, int modeFlags) { in checkUriPermission() argument
|
/frameworks/base/services/core/java/com/android/server/content/ |
D | ContentService.java | 476 private int checkUriPermission(Uri uri, int pid, int uid, int modeFlags, int userHandle) { in checkUriPermission() argument 479 uri, pid, uid, modeFlags, userHandle, null); in checkUriPermission() 1239 private int handleIncomingUser(Uri uri, int pid, int uid, int modeFlags, boolean allowNonFull, in handleIncomingUser() argument 1251 if (checkUriPermission(uri, pid, uid, modeFlags, in handleIncomingUser()
|
/frameworks/base/services/core/java/com/android/server/am/ |
D | ActivityManagerService.java | 6157 final int modeFlags, int userId, IBinder callerToken) { in checkUriPermission() argument 6172 return mUgmInternal.checkUriPermission(new GrantUri(userId, uri, false), uid, modeFlags) in checkUriPermission() 6182 final int modeFlags, int userId) { in grantUriPermission() argument 6199 Preconditions.checkFlagsArgument(modeFlags, Intent.FLAG_GRANT_READ_URI_PERMISSION in grantUriPermission() 6204 mUgmInternal.grantUriPermission(r.uid, targetPkg, grantUri, modeFlags, null, in grantUriPermission() 6215 final int modeFlags, int userId) { in revokeUriPermission() argument 6229 if (!Intent.isAccessUriMode(modeFlags)) { in revokeUriPermission() 6243 modeFlags); in revokeUriPermission()
|