/base/security/access_token/services/accesstokenmanager/main/cpp/src/permission/ |
D | permission_validator.cpp | 66 bool PermissionValidator::IsPermissionStateValid(const PermissionStateFull& permState) in IsPermissionStateValid() argument 68 if (!DataValidator::IsPermissionNameValid(permState.permissionName)) { in IsPermissionStateValid() 72 size_t resDevIdSize = permState.resDeviceID.size(); in IsPermissionStateValid() 73 size_t grantStatSize = permState.grantStatus.size(); in IsPermissionStateValid() 74 size_t grantFlagSize = permState.grantFlags.size(); in IsPermissionStateValid() 80 if (!IsGrantStatusValid(permState.grantStatus[i]) || in IsPermissionStateValid() 81 !IsPermissionFlagValid(permState.grantFlags[i])) { in IsPermissionStateValid() 103 void PermissionValidator::DeduplicateResDevID(const PermissionStateFull& permState, PermissionState… in DeduplicateResDevID() argument 106 auto stateIter = permState.grantStatus.begin(); in DeduplicateResDevID() 107 auto flagIter = permState.grantFlags.begin(); in DeduplicateResDevID() [all …]
|
D | permission_manager.cpp | 275 PermissionListState &permState, int32_t apiVersion) in GetSelfPermissionState() argument 282 …if ((permState.permissionName == VAGUE_LOCATION_PERMISSION_NAME) && (apiVersion < ACCURATE_LOCATIO… in GetSelfPermissionState() 283 permState.state = INVALID_OPER; in GetSelfPermissionState() 287 …auto iter = std::find_if(permsList.begin(), permsList.end(), [permState](const PermissionStateFull… in GetSelfPermissionState() 288 return permState.permissionName == perm.permissionName; in GetSelfPermissionState() 292 permState.permissionName.c_str(), iter->grantStatus[0], iter->grantFlags[0]); in GetSelfPermissionState() 299 …ACCESSTOKEN_LOG_WARN(LABEL, "can not find permission: %{public}s define!", permState.permissionNam… in GetSelfPermissionState() 300 permState.state = INVALID_OPER; in GetSelfPermissionState() 303 if (!PermissionDefinitionCache::GetInstance().HasDefinition(permState.permissionName)) { in GetSelfPermissionState() 304 …ACCESSTOKEN_LOG_WARN(LABEL, "no definition for permission: %{public}s!", permState.permissionName.… in GetSelfPermissionState() [all …]
|
D | permission_policy_set.cpp | 234 [permissionName](const PermissionStateFull& permState) { in UpdatePermStateList() argument 235 return permissionName == permState.permissionName; in UpdatePermStateList()
|
/base/sensors/sensor/utils/common/src/ |
D | sensor_basic_info.cpp | 58 void SensorBasicInfo::SetPermState(bool permState) in SetPermState() argument 60 permState_ = permState; in SetPermState()
|
/base/security/access_token/services/accesstokenmanager/main/cpp/include/permission/ |
D | permission_validator.h | 32 static bool IsPermissionStateValid(const PermissionStateFull& permState); 40 …static void DeduplicateResDevID(const PermissionStateFull& permState, PermissionStateFull& result);
|
D | permission_manager.h | 64 … std::vector<PermissionStateFull> permsList, PermissionListState &permState, int32_t apiVersion);
|
/base/security/access_token/services/accesstokenmanager/main/cpp/src/token/ |
D | native_token_receptor.cpp | 57 PermissionStateFull permState; in NativeReqPermsGet() local 61 permState.permissionName = permReq; in NativeReqPermsGet() 62 permState.isGeneral = true; in NativeReqPermsGet() 63 permState.resDeviceID.push_back(DEFAULT_DEVICEID); in NativeReqPermsGet() 64 permState.grantStatus.push_back(PERMISSION_GRANTED); in NativeReqPermsGet() 65 permState.grantFlags.push_back(PERMISSION_SYSTEM_FIXED); in NativeReqPermsGet() 66 permStateList.push_back(permState); in NativeReqPermsGet()
|
/base/sensors/sensor/utils/common/include/ |
D | sensor_basic_info.h | 34 void SetPermState(bool permState);
|
/base/security/access_token/services/tokensyncmanager/src/command/ |
D | base_remote_command.cpp | 104 for (const auto& permState : tokenInfo.permStateList) { in ToNativeTokenInfoJson() local 106 ToPermStateJson(permStateJson, permState); in ToNativeTokenInfoJson() 150 for (const auto& permState : tokenInfo.permStateList) { in ToHapTokenInfosJson() local 152 ToPermStateJson(permStateJson, permState); in ToHapTokenInfosJson()
|
/base/security/access_token/interfaces/kits/accesstoken/napi/src/ |
D | napi_atmanager.cpp | 1154 PermissionListState permState; in IsDynamicRequest() local 1155 permState.permissionName = permission; in IsDynamicRequest() 1156 permState.state = -1; in IsDynamicRequest() 1157 permList.emplace_back(permState); in IsDynamicRequest() 1164 for (const auto& permState : permList) { in IsDynamicRequest() local 1166 permState.permissionName.c_str(), permState.state); in IsDynamicRequest() 1167 permissionsState.emplace_back(permState.state); in IsDynamicRequest()
|
/base/security/access_token/services/accesstokenmanager/test/unittest/cpp/src/ |
D | accesstoken_info_manager_test.cpp | 1529 PermissionStateFull permState = { variable 1537 … ASSERT_EQ(false, PermissionValidator::IsPermissionStateValid(permState)); // permissionName empty 1539 permState.resDeviceID.emplace_back("dev-002"); 1541 ASSERT_EQ(false, PermissionValidator::IsPermissionStateValid(permState)); 1584 PermissionStateFull permState = { variable 1592 ASSERT_EQ(static_cast<uint32_t>(2), permState.resDeviceID.size()); 1595 permList.emplace_back(permState);
|