/base/location/frameworks/location_common/common/source/ |
D | common_utils.cpp | 36 bool CommonUtils::CheckLocationPermission(uint32_t tokenId, uint32_t firstTokenId) in CheckLocationPermission() argument 38 return CheckPermission(ACCESS_LOCATION, tokenId, firstTokenId); in CheckLocationPermission() 63 bool CommonUtils::CheckBackgroundPermission(uint32_t tokenId, uint32_t firstTokenId) in CheckBackgroundPermission() argument 65 return CheckPermission(ACCESS_BACKGROUND_LOCATION, tokenId, firstTokenId); in CheckBackgroundPermission() 68 bool CommonUtils::CheckApproximatelyPermission(uint32_t tokenId, uint32_t firstTokenId) in CheckApproximatelyPermission() argument 70 return CheckPermission(ACCESS_APPROXIMATELY_LOCATION, tokenId, firstTokenId); in CheckApproximatelyPermission() 73 bool CommonUtils::CheckSecureSettings(uint32_t tokenId, uint32_t firstTokenId) in CheckSecureSettings() argument 75 return CheckPermission(MANAGE_SECURE_SETTINGS, tokenId, firstTokenId); in CheckSecureSettings() 88 int CommonUtils::GetPermissionLevel(uint32_t tokenId, uint32_t firstTokenId) in GetPermissionLevel() argument 91 if (CheckPermission(ACCESS_APPROXIMATELY_LOCATION, tokenId, firstTokenId) && in GetPermissionLevel() [all …]
|
D | app_identity.cpp | 30 …ity::AppIdentity(pid_t uid, pid_t pid, uint32_t tokenId, uint64_t tokenIdEx, uint32_t firstTokenId) in AppIdentity() argument 31 : uid_(uid), pid_(pid), tokenId_(tokenId), tokenIdEx_(tokenIdEx), firstTokenId_(firstTokenId) in AppIdentity()
|
/base/location/interfaces/inner_api/include/ |
D | app_identity.h | 26 …cit AppIdentity(pid_t uid, pid_t pid, uint32_t tokenId, uint64_t tokenIdEx, uint32_t firstTokenId); 74 inline void SetFirstTokenId(uint32_t firstTokenId) in SetFirstTokenId() argument 76 firstTokenId_ = firstTokenId; in SetFirstTokenId()
|
D | common_utils.h | 166 static bool CheckLocationPermission(uint32_t tokenId, uint32_t firstTokenId); 167 static bool CheckApproximatelyPermission(uint32_t tokenId, uint32_t firstTokenId); 168 static bool CheckBackgroundPermission(uint32_t tokenId, uint32_t firstTokenId); 169 …tatic bool CheckPermission(const std::string &permission, uint32_t tokenId, uint32_t firstTokenId); 170 static bool CheckSecureSettings(uint32_t tokenId, uint32_t firstTokenId); 178 static int GetPermissionLevel(uint32_t tokenId, uint32_t firstTokenId);
|
/base/location/test/fuzztest/locator/reportmanager_fuzzer/ |
D | reportmanager_fuzzer.cpp | 53 uint32_t firstTokenId = data[index++]; in ReportManagerFuzzerTest() local 54 reportManager->GetPermittedLocation(uid, tokenId, firstTokenId, location); in ReportManagerFuzzerTest()
|
/base/location/services/location_locator/locator/source/ |
D | report_manager.cpp | 115 …r<Location> ReportManager::GetPermittedLocation(pid_t uid, uint32_t tokenId, uint32_t firstTokenId, in GetPermittedLocation() argument 127 if (!CommonUtils::CheckLocationPermission(tokenId, firstTokenId) && in GetPermittedLocation() 128 CommonUtils::CheckApproximatelyPermission(tokenId, firstTokenId)) { in GetPermittedLocation() 130 } else if ((!CommonUtils::CheckLocationPermission(tokenId, firstTokenId) && in GetPermittedLocation() 131 !CommonUtils::CheckApproximatelyPermission(tokenId, firstTokenId)) || in GetPermittedLocation() 133 !CommonUtils::CheckBackgroundPermission(tokenId, firstTokenId))) { in GetPermittedLocation()
|
D | request.cpp | 92 void Request::SetFirstTokenId(uint32_t firstTokenId) in SetFirstTokenId() argument 94 this->firstTokenId_ = firstTokenId; in SetFirstTokenId()
|
D | locator_background_proxy.cpp | 248 uint32_t firstTokenId = request->GetFirstTokenId(); in CheckPermission() local 249 return ((CommonUtils::CheckLocationPermission(tokenId, firstTokenId) || in CheckPermission() 250 CommonUtils::CheckApproximatelyPermission(tokenId, firstTokenId)) && in CheckPermission() 251 CommonUtils::CheckBackgroundPermission(tokenId, firstTokenId)); in CheckPermission()
|
D | request_manager.cpp | 410 uint32_t firstTokenId = request->GetFirstTokenId(); in AddRequestToWorkRecord() local 412 if (!CommonUtils::CheckLocationPermission(tokenId, firstTokenId) && in AddRequestToWorkRecord() 413 !CommonUtils::CheckApproximatelyPermission(tokenId, firstTokenId)) { in AddRequestToWorkRecord()
|
/base/useriam/user_auth_framework/services/ipc/src/ |
D | ipc_common.cpp | 165 uint32_t firstTokenId = stub.GetFirstTokenID(); in CheckDirectCallerAndFirstCallerIfSet() local 168 …if ((firstTokenId != 0 && AccessTokenKit::VerifyAccessToken(firstTokenId, permission) != RET_SUCCE… in CheckDirectCallerAndFirstCallerIfSet()
|
/base/location/test/location_common/source/ |
D | common_utils_test.cpp | 207 uint32_t firstTokenId = 0; variable 209 EXPECT_EQ(false, CommonUtils::CheckLocationPermission(invalidTokenId, firstTokenId)); 210 EXPECT_EQ(false, CommonUtils::CheckApproximatelyPermission(invalidTokenId, firstTokenId)); 211 EXPECT_EQ(false, CommonUtils::CheckBackgroundPermission(invalidTokenId, firstTokenId)); 212 EXPECT_EQ(false, CommonUtils::CheckSecureSettings(invalidTokenId, firstTokenId));
|
/base/location/services/location_locator/locator/include/ |
D | report_manager.h | 38 … std::unique_ptr<Location> GetPermittedLocation(pid_t uid, uint32_t tokenId, uint32_t firstTokenId,
|
D | request.h | 52 void SetFirstTokenId(uint32_t firstTokenId);
|