!1310 5.0.2 remove security level verification

Merge pull request !1310 from chenbin/OpenHarmony-5.0.2-Release
This commit is contained in:
openharmony_ci 2025-01-23 08:51:27 +00:00 committed by Gitee
commit 34b01c3d9a
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 0 additions and 26 deletions

View File

@ -552,11 +552,6 @@ bool DistributedSchedPermission::CheckMigrateStartCtrlPer(const AppExecFwk::Abil
// check if continuation with same appid
HILOGI("Check migration start control permission with same appid enter.");
if (!targetAbility.visible &&
!CheckDeviceSecurityLevel(callerInfo.sourceDeviceId, want.GetElement().GetDeviceID())) {
HILOGE("check device security level failed!");
return false;
}
if (!isSameBundle) {
return true;
}

View File

@ -420,27 +420,6 @@ HWTEST_F(DistributedSchedPermissionTest, CheckStartControlPermission_001, TestSi
DTEST_LOG << "DistributedSchedPermissionTest CheckStartControlPermission_001 end ret:" << ret << std::endl;
}
/**
* @tc.name: CheckStartControlPermission_002
* @tc.desc: input invalid params
* @tc.type: FUNC
* @tc.require: issueI5T6GJ
*/
HWTEST_F(DistributedSchedPermissionTest, CheckStartControlPermission_002, TestSize.Level3)
{
DTEST_LOG << "DistributedSchedPermissionTest CheckStartControlPermission_002 begin" << std::endl;
AppExecFwk::AbilityInfo targetAbility;
targetAbility.bundleName = BUNDLE_NAME;
CallerInfo callerInfo;
bool result = BundleManagerInternal::GetCallerAppIdFromBms(BUNDLE_NAME, callerInfo.callerAppId);
EXPECT_EQ(result, true);
AAFwk::Want want;
want.AddFlags(want.FLAG_ABILITY_CONTINUATION);
bool ret = DistributedSchedPermission::GetInstance().CheckStartControlPermission(targetAbility, callerInfo, want);
EXPECT_FALSE(ret);
DTEST_LOG << "DistributedSchedPermissionTest CheckStartControlPermission_002 end ret:" << ret << std::endl;
}
/**
* @tc.name: CheckStartControlPermission_003
* @tc.desc: input invalid params