Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Xts Acts
提交
06d69eb6
X
Xts Acts
项目概览
OpenHarmony
/
Xts Acts
1 年多 前同步成功
通知
9
Star
22
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
X
Xts Acts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
06d69eb6
编写于
9月 15, 2022
作者:
伞
伞木希美
提交者:
Gitee
9月 15, 2022
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
。。。
Signed-off-by:
N
伞木希美
<
zhanghanlin9@huawei.com
>
上级
45f2ac4a
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
38 addition
and
38 deletion
+38
-38
security_lite/permission_posix/pms/src/ActsPMSRevokeRuntimeTest.cpp
...ite/permission_posix/pms/src/ActsPMSRevokeRuntimeTest.cpp
+24
-24
security_lite/permission_posix/pms/src/ActsPMSUpdatePermissionTest.cpp
.../permission_posix/pms/src/ActsPMSUpdatePermissionTest.cpp
+14
-14
未找到文件。
security_lite/permission_posix/pms/src/ActsPMSRevokeRuntimeTest.cpp
浏览文件 @
06d69eb6
...
...
@@ -89,12 +89,12 @@ protected:
};
/*
* @tc.name:
testSecPMPMS_126
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5000
* @tc.desc: revoke permissions to large and small PIDs
* @tc.type: FUNC
* @tc.require: AR000E07N7
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
126
,
Function
|
MediumTest
|
Level3
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5000
,
Function
|
MediumTest
|
Level3
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
MAX_PID
);
...
...
@@ -113,12 +113,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_126, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_127
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5100
* @tc.desc: revoke permissions while not load permiossion
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
127
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5100
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
int
ret
=
g_interface
->
RevokeRuntimePermission
(
TEST_TASKID
,
g_systemPers
[
0
].
name
);
...
...
@@ -129,12 +129,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_127, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_128
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5200
* @tc.desc: revoke runtime app permissions
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
128
,
Function
|
MediumTest
|
Level0
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5200
,
Function
|
MediumTest
|
Level0
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -147,12 +147,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_128, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_129
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5300
* @tc.desc: revoke permissions without request
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
129
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5300
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
1
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -165,12 +165,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_129, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_13
0
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_540
0
* @tc.desc: revoke system_grant permissions
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
13
0
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
540
0
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -183,12 +183,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_130, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_131
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5500
* @tc.desc: revoke user_grant permissions
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
131
,
Function
|
MediumTest
|
Level1
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5500
,
Function
|
MediumTest
|
Level1
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -204,12 +204,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_131, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_132
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5600
* @tc.desc: revoke unknown permissions
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
132
,
Function
|
MediumTest
|
Level3
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5600
,
Function
|
MediumTest
|
Level3
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -222,12 +222,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_132, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_133
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5700
* @tc.desc: revoke runtime permissions after revoke permission
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
133
,
Function
|
MediumTest
|
Level3
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5700
,
Function
|
MediumTest
|
Level3
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
g_interface
->
GrantPermission
(
TEST_APP_ID
,
g_systemPers
[
0
].
name
);
...
...
@@ -242,12 +242,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_133, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_134
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5800
* @tc.desc: revoke runtime permissions after grant permission
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
134
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5800
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
g_interface
->
GrantPermission
(
TEST_APP_ID
,
g_systemPers
[
0
].
name
);
...
...
@@ -261,12 +261,12 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_134, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_135
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_5900
* @tc.desc: revoke runtime permissions continuously
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
135
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
5900
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
@@ -285,24 +285,24 @@ HWTEST_F(ActsPMSRevokeRuntimeTest, testSecPMPMS_135, Function | MediumTest | Lev
}
/*
* @tc.name:
testSecPMPMS_136
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_6000
* @tc.desc: revoke permissions of unnormal task
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
136
,
Function
|
MediumTest
|
Level3
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
6000
,
Function
|
MediumTest
|
Level3
)
{
int
ret
=
g_interface
->
RevokeRuntimePermission
(
ABNORMAL_TASKID
,
g_systemPers
[
0
].
name
);
EXPECT_EQ
(
ret
,
PERM_ERRORCODE_TASKID_NOT_EXIST
)
<<
"revoke ret = "
<<
ret
<<
endl
;
}
/*
* @tc.name:
testSecPMPMS_137
* @tc.name:
SUB_SEC_AppSEC_PermissionMgmt_PMS_6100
* @tc.desc: revoke permissions of unnormal permission
* @tc.type: FUNC
* @tc.require: AR000F4FSI
*/
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
137
,
Function
|
MediumTest
|
Level4
)
HWTEST_F
(
ActsPMSRevokeRuntimeTest
,
testSecPMPMS_
6100
,
Function
|
MediumTest
|
Level4
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
LoadPermissions
(
TEST_APP_ID
,
TEST_TASKID
);
...
...
security_lite/permission_posix/pms/src/ActsPMSUpdatePermissionTest.cpp
浏览文件 @
06d69eb6
...
...
@@ -98,11 +98,11 @@ long GetCurrentTimeMillis()
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_001
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6200
* @tc.name Update permission flags
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
001
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6200
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -130,11 +130,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_001, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_002
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6300
* @tc.name Update permission flags (No reminds after rejection)
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
002
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6300
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -162,11 +162,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_002, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_003
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6400
* @tc.name Update permission flags (Name does not exist)
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
003
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6400
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -199,11 +199,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_003, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_004
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6500
* @tc.name Update permission flags (Name empty)
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
004
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6500
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -236,11 +236,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_004, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_005
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6600
* @tc.name Update permission flags (Name invalid)
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
005
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6600
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -269,11 +269,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_005, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_006
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6700
* @tc.name Updatepermissionflags interface stability test
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
006
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6700
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
@@ -302,11 +302,11 @@ HWTEST_F(ActsPMSUpdatePermissionTest, testSecPMUpdatePMFlags_006, Function | Med
}
/**
* @tc.number S
ecurity_AppSecurity_PermissionManager_L1_UpdatePermissionFlags_007
* @tc.number S
UB_SEC_AppSEC_PermissionMgmt_PMS_6800
* @tc.name Updatepermissionflags interface performace test
* @tc.desc [C- SECURITY -1000]
*/
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
007
,
Function
|
MediumTest
|
Level2
)
HWTEST_F
(
ActsPMSUpdatePermissionTest
,
testSecPMUpdatePMFlags_
6800
,
Function
|
MediumTest
|
Level2
)
{
SaveOrUpdatePermissions
(
TEST_APP_ID
,
g_systemPers
,
SYS_PERM_NUM
,
FIRST_INSTALL
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录