Home
last modified time | relevance | path

Searched refs:MODE_ALLOWED (Results 1 – 25 of 113) sorted by relevance

12345

/frameworks/base/services/tests/mockingservicestests/src/com/android/server/appop/
DAppOpsServiceTest.java21 import static android.app.AppOpsManager.MODE_ALLOWED;
168 mAppOpsService.setMode(OP_READ_SMS, mMyUid, sMyPackageName, MODE_ALLOWED); in testNoteOperationAndGetOpsForPackage()
174 assertContainsOp(loggedOps, OP_READ_SMS, mTestStartMillis, -1, MODE_ALLOWED); in testNoteOperationAndGetOpsForPackage()
180 assertContainsOp(loggedOps, OP_READ_SMS, mTestStartMillis, -1, MODE_ALLOWED); in testNoteOperationAndGetOpsForPackage()
192 mAppOpsService.setMode(OP_COARSE_LOCATION, mMyUid, sMyPackageName, MODE_ALLOWED); in testNoteOperationAndGetOpsForPackage_controlledByDifferentOp()
195 null, false)).isEqualTo(MODE_ALLOWED); in testNoteOperationAndGetOpsForPackage_controlledByDifferentOp()
198 MODE_ALLOWED /* default for WIFI_SCAN; this is not changed or used in this test */); in testNoteOperationAndGetOpsForPackage_controlledByDifferentOp() local
206 MODE_ALLOWED /* default for WIFI_SCAN; this is not changed or used in this test */); in testNoteOperationAndGetOpsForPackage_controlledByDifferentOp() local
212 mAppOpsService.setMode(OP_READ_SMS, mMyUid, sMyPackageName, MODE_ALLOWED); in testStatePersistence()
225 assertContainsOp(loggedOps, OP_READ_SMS, mTestStartMillis, -1, MODE_ALLOWED); in testStatePersistence()
[all …]
/frameworks/base/services/robotests/src/com/android/server/pm/
DCrossProfileAppsServiceImplRoboTest.java19 import static android.app.AppOpsManager.MODE_ALLOWED;
254 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_noPermissions_throwsSecurityException()
267 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_missingInteractAcrossUsersAndFull_throwsSecurityException()
275 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_setsAppOp()
276 assertThat(getCrossProfileAppOp()).isEqualTo(MODE_ALLOWED); in setInteractAcrossProfilesAppOp_setsAppOp()
289 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_configureInteractAcrossProfilesPermissionWithoutAppOpsPermissions_setsAppOp()
291 assertThat(getCrossProfileAppOp()).isEqualTo(MODE_ALLOWED); in setInteractAcrossProfilesAppOp_configureInteractAcrossProfilesPermissionWithoutAppOpsPermissions_setsAppOp()
303 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_appOpsPermissionsWithoutConfigureInteractAcrossProfilesPermission_setsAppOp()
305 assertThat(getCrossProfileAppOp()).isEqualTo(MODE_ALLOWED); in setInteractAcrossProfilesAppOp_appOpsPermissionsWithoutConfigureInteractAcrossProfilesPermission_setsAppOp()
313 CROSS_PROFILE_APP_PACKAGE_NAME, MODE_ALLOWED); in setInteractAcrossProfilesAppOp_setsAppOpWithUsersAndWithoutFull()
[all …]
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/util/
DWifiPermissionsUtilTest.java180 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testCanReadPeersMacAddressCurrentUserAndAllPermissions()
203 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testCanReadPeersMacAddressCurrentProfileAndAllPermissions()
247 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testenforceCanAccessScanResults_UserOrProfileNotCurrent()
269 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testCannotAccessScanResults_NoInteractAcrossUsersFullPermission()
292 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testLegacyForegroundAppWithOtherPermissionsDenied()
320 mAllowCoarseLocationApps = AppOpsManager.MODE_ALLOWED; in testLegacyAppHasLocationAndAllPermissions()
321 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testLegacyAppHasLocationAndAllPermissions()
367 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testCannotAccessScanResults_LocationModeDisabled()
400 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testEnforceCannotAccessScanResults_LocationModeDisabledHasChangeWifiState()
434 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED; in testEnforceCannotAccessScanResults_LocationModeDisabledHasAccessWifiState()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/appops/
DAppOpsControllerTest.java103 AppOpsManager.MODE_ALLOWED); in addCallback_includedCode()
157 TEST_UID, TEST_PACKAGE_NAME, AppOpsManager.MODE_ALLOWED); in getActiveItems_differentDetails()
168 TEST_UID, TEST_PACKAGE_NAME, AppOpsManager.MODE_ALLOWED); in getActiveItemsForUser()
179 AppOpsManager.MODE_ALLOWED); in opNotedScheduledForRemoval()
191 AppOpsManager.MODE_ALLOWED); in noItemsAfterStopListening()
205 AppOpsManager.MODE_ALLOWED); in noDoubleUpdateOnOpNoted()
207 AppOpsManager.MODE_ALLOWED); in noDoubleUpdateOnOpNoted()
221 AppOpsManager.MODE_ALLOWED); in onDoubleOPNoted_scheduleTwiceForRemoval()
223 AppOpsManager.MODE_ALLOWED); in onDoubleOPNoted_scheduleTwiceForRemoval()
241 AppOpsManager.MODE_ALLOWED); in testActiveOpNotRemovedAfterNoted()
[all …]
/frameworks/base/services/tests/mockingservicestests/src/com/android/server/location/
DAppOpsHelperTest.java18 import static android.app.AppOpsManager.MODE_ALLOWED;
111 doReturn(MODE_ALLOWED).when( in testCheckLocationAccess()
122 doReturn(MODE_ALLOWED).when( in testCheckLocationAccess()
136 doReturn(MODE_ALLOWED).when( in testNoteLocationAccess()
150 doReturn(MODE_ALLOWED).when( in testNoteLocationAccess()
166 doReturn(MODE_ALLOWED).when( in testStartLocationMonitoring()
182 doReturn(MODE_ALLOWED).when( in testStartHighPowerLocationMonitoring()
218 doReturn(MODE_ALLOWED).when( in testNoteMockLocationAccess()
/frameworks/base/core/java/android/content/
DContentProvider.java21 import static android.app.AppOpsManager.MODE_ALLOWED;
240 != AppOpsManager.MODE_ALLOWED) { in query()
323 != AppOpsManager.MODE_ALLOWED) { in insert()
351 != AppOpsManager.MODE_ALLOWED) { in bulkInsert()
388 != AppOpsManager.MODE_ALLOWED) { in applyBatch()
394 != AppOpsManager.MODE_ALLOWED) { in applyBatch()
428 != AppOpsManager.MODE_ALLOWED) { in delete()
450 != AppOpsManager.MODE_ALLOWED) { in update()
574 != AppOpsManager.MODE_ALLOWED) { in canonicalize()
610 != AppOpsManager.MODE_ALLOWED) { in uncanonicalize()
[all …]
/frameworks/base/services/core/java/com/android/server/
DMmsServiceBroker.java341 callingPkg) != AppOpsManager.MODE_ALLOWED) { in sendMessage()
361 callingPkg) != AppOpsManager.MODE_ALLOWED) { in downloadMessage()
378 callingPkg) != AppOpsManager.MODE_ALLOWED) { in importTextMessage()
392 callingPkg) != AppOpsManager.MODE_ALLOWED) { in importMultimediaMessage()
405 callingPkg) != AppOpsManager.MODE_ALLOWED) { in deleteStoredMessage()
415 callingPkg) != AppOpsManager.MODE_ALLOWED) { in deleteStoredConversation()
425 callingPkg) != AppOpsManager.MODE_ALLOWED) { in updateStoredMessageStatus()
436 callingPkg) != AppOpsManager.MODE_ALLOWED) { in archiveStoredConversation()
447 callingPkg) != AppOpsManager.MODE_ALLOWED) { in addTextMessageDraft()
459 callingPkg) != AppOpsManager.MODE_ALLOWED) { in addMultimediaMessageDraft()
[all …]
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/
DLocationPermissionCheckerTest.java180 mAllowCoarseLocationApps = AppOpsManager.MODE_ALLOWED;
181 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED;
198 mAllowFineLocationApps = AppOpsManager.MODE_ALLOWED;
199 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED;
213 mAllowFineLocationApps = AppOpsManager.MODE_ALLOWED;
214 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED;
255 mWifiScanAllowApps = AppOpsManager.MODE_ALLOWED;
/frameworks/base/core/java/android/app/
DAppOpsManager.java345 MODE_ALLOWED,
357 public static final int MODE_ALLOWED = 0; field in AppOpsManager
2178 AppOpsManager.MODE_ALLOWED, // COARSE_LOCATION
2179 AppOpsManager.MODE_ALLOWED, // FINE_LOCATION
2180 AppOpsManager.MODE_ALLOWED, // GPS
2181 AppOpsManager.MODE_ALLOWED, // VIBRATE
2182 AppOpsManager.MODE_ALLOWED, // READ_CONTACTS
2183 AppOpsManager.MODE_ALLOWED, // WRITE_CONTACTS
2184 AppOpsManager.MODE_ALLOWED, // READ_CALL_LOG
2185 AppOpsManager.MODE_ALLOWED, // WRITE_CALL_LOG
[all …]
/frameworks/base/services/core/java/com/android/server/location/
DAppOpsHelper.java130 callerIdentity.packageName) == AppOpsManager.MODE_ALLOWED; in checkLocationAccess()
194 callerIdentity.listenerId) == AppOpsManager.MODE_ALLOWED; in noteMockLocationAccess()
213 callerIdentity.listenerId) == AppOpsManager.MODE_ALLOWED; in startLocationMonitoring()
248 callerIdentity.listenerId) == AppOpsManager.MODE_ALLOWED; in noteOpNoThrow()
DRemoteListenerHelper.java183 callerIdentity.packageName) == AppOpsManager.MODE_ALLOWED; in hasPermission()
188 == AppOpsManager.MODE_ALLOWED; in hasPermission()
/frameworks/base/services/tests/servicestests/src/com/android/server/appop/
DAppOpsNotedWatcherTest.java69 eq(AppOpsManager.MODE_ALLOWED)); in testWatchNotedOps()
73 eq(AppOpsManager.MODE_ALLOWED)); in testWatchNotedOps()
97 eq(AppOpsManager.MODE_ALLOWED)); in testWatchNotedOps()
DAppOpsStartedWatcherTest.java66 eq(AppOpsManager.MODE_ALLOWED)); in testWatchStartedOps()
70 eq(AppOpsManager.MODE_ALLOWED)); in testWatchStartedOps()
94 eq(AppOpsManager.MODE_ALLOWED)); in testWatchStartedOps()
/frameworks/base/services/core/java/com/android/server/appop/
DAudioRestrictionManager.java87 if (mode != AppOpsManager.MODE_ALLOWED) { in checkAudioOperation()
91 return AppOpsManager.MODE_ALLOWED; in checkAudioOperation()
102 return AppOpsManager.MODE_ALLOWED; in checkZenModeRestrictionLocked()
114 if (mode != AppOpsManager.MODE_ALLOWED) { in setZenModeAudioRestriction()
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/
DPhoneSubInfoControllerTest.java156 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetDeviceIdWithOutPermission()
239 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetNaiWithOutPermission()
322 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetImeiWithOutPermission()
387 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetDeviceSvnWithOutPermission()
466 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetSubscriberIdWithOutPermission()
550 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetIccSerialNumberWithOutPermission()
617 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetLine1NumberWithOutPermissionTargetPreR()
642 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetLine1NumberWithOutPermissionTargetPreR()
668 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetLine1NumberWithOutPermissionTargetPreR()
711 doReturn(AppOpsManager.MODE_ALLOWED).when(mAppOsMgr).noteOp( in testGetLine1NumberWithOutPermissionTargetR()
[all …]
DTelephonyPermissionsTest.java157 eq(FEATURE), nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneState_hasPermissionAndAppOp()
199 eq(FEATURE), nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneStateOnAnyActiveSub_hasPermissionAndAppOp()
239 eq(FEATURE), nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneNumber_defaultSmsApp()
259 nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneNumber_hasReadSms()
270 eq(FEATURE), nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneNumber_hasReadPhoneNumbers()
286 eq(FEATURE), nullable(String.class))).thenReturn(AppOpsManager.MODE_ALLOWED); in testCheckReadPhoneNumber_hasReadSmsNoAppop()
401 AppOpsManager.MODE_ALLOWED); in testCheckReadDeviceIdentifiers_hasAppOpNullSubscription()
/frameworks/base/core/tests/coretests/src/android/content/
DPermissionCheckerTest.java79 Binder.getCallingUid(), mContext.getPackageName(), AppOpsManager.MODE_ALLOWED); in testCheckPermissionForPreflight_appOpPermission_modeAllowed_returnsGranted()
91 Binder.getCallingUid(), mContext.getPackageName(), AppOpsManager.MODE_ALLOWED); in testCheckPermissionForPreflight_appOpPermission_packageNameIsNull_returnsGranted()
152 Binder.getCallingUid(), mContext.getPackageName(), AppOpsManager.MODE_ALLOWED); in testCheckPermissionForDataDelivery_appOpPermission_modeAllowed_returnsGranted()
164 Binder.getCallingUid(), mContext.getPackageName(), AppOpsManager.MODE_ALLOWED); in testCheckPermissionForDataDelivery_appOpPermission_packageNameIsNull_returnsGranted()
/frameworks/base/telephony/common/com/android/internal/telephony/
DTelephonyPermissions.java158 callingFeatureId, null) == AppOpsManager.MODE_ALLOWED; in checkReadPhoneState()
211 callingFeatureId, null) == AppOpsManager.MODE_ALLOWED; in checkReadPhoneStateOnAnyActiveSub()
408 callingPackageName, null) == AppOpsManager.MODE_ALLOWED; in checkReadCallLog()
474 null) == AppOpsManager.MODE_ALLOWED) { in checkReadPhoneNumber()
481 callingFeatureId, null) == AppOpsManager.MODE_ALLOWED) { in checkReadPhoneNumber()
491 callingFeatureId, null) == AppOpsManager.MODE_ALLOWED) { in checkReadPhoneNumber()
/frameworks/base/packages/SystemUI/src/com/android/systemui/pip/phone/
DPipAppOpsListener.java19 import static android.app.AppOpsManager.MODE_ALLOWED;
53 packageName) != MODE_ALLOWED) {
/frameworks/base/core/tests/coretests/src/android/provider/
DTestDocumentsProvider.java98 return AppOpsManager.MODE_ALLOWED; in enforceReadPermissionInner()
104 return AppOpsManager.MODE_ALLOWED; in enforceWritePermissionInner()
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DSmsPermissions.java105 callingAttributionTag, null) == AppOpsManager.MODE_ALLOWED; in checkCallingCanSendSms()
120 == AppOpsManager.MODE_ALLOWED; in checkCallingOrSelfCanSendSms()
/frameworks/native/libs/binder/include/binder/
DAppOpsManager.h35 MODE_ALLOWED = IAppOpsService::MODE_ALLOWED, enumerator
DPermissionController.h41 MODE_ALLOWED = 0, enumerator
/frameworks/base/services/core/java/com/android/server/am/
DAssistDataRequester.java20 import static android.app.AppOpsManager.MODE_ALLOWED;
219 == MODE_ALLOWED && allowFetchData) { in requestData()
263 == MODE_ALLOWED && allowFetchScreenshot) { in requestData()
/frameworks/base/services/tests/wmtests/src/com/android/server/wm/
DAssistDataRequesterTest.java19 import static android.app.AppOpsManager.MODE_ALLOWED;
150 doReturn(assistStructureAllowed ? MODE_ALLOWED : MODE_ERRORED).when(mAppOpsManager) in setupMocks()
152 doReturn(assistScreenshotAllowed ? MODE_ALLOWED : MODE_ERRORED).when(mAppOpsManager) in setupMocks()

12345