change system permission to uid 3333

Signed-off-by: winnieHu <huyu35@huawei.com>
This commit is contained in:
winnieHu
2022-05-25 17:18:58 +08:00
parent 6281783670
commit 2039ba4d4f
3 changed files with 14 additions and 26 deletions
@@ -39,7 +39,7 @@ int32_t HcGetUdid(uint8_t *udid, int32_t udidLen)
const char *GetStoragePath(void)
{
#ifndef LITE_DEVICE
const char *storageFile = "/data/data/deviceauth/hcgroup.dat";
const char *storageFile = "/data/service/el1/public/deviceauth/hcgroup.dat";
#else
const char *storageFile = "/storage/deviceauth/hcgroup.dat";
#endif
@@ -50,7 +50,7 @@ const char *GetStoragePath(void)
const char *GetStorageDirPath(void)
{
#ifndef LITE_DEVICE
const char *storageFile = "/data/data/deviceauth";
const char *storageFile = "/data/service/el1/public/deviceauth";
#else
const char *storageFile = "/storage/deviceauth";
#endif
@@ -61,7 +61,7 @@ const char *GetStorageDirPath(void)
const char *GetAccountStoragePath(void)
{
#ifndef LITE_DEVICE
const char *storageFile = "/data/data/deviceauth/account";
const char *storageFile = "/data/service/el1/public/deviceauth/account";
#else
const char *storageFile = "/storage/deviceauth/account";
#endif
+11 -2
View File
@@ -1,9 +1,18 @@
{
"jobs" : [{
"name" : "post-fs-data",
"cmds" : [
"mkdir /data/service/el1/public/deviceauth 0711 deviceauth deviceauth",
"mkdir /data/service/el1/public/deviceauth/account 0711 deviceauth deviceauth",
"start deviceauth_service"
]
}
],
"services" : [{
"name" : "deviceauth_service",
"path" : ["/system/bin/deviceauth_service"],
"uid" : "system",
"gid" : ["system", "shell"]
"uid" : "deviceauth",
"gid" : ["deviceauth", "shell"]
}
]
}
@@ -1,21 +0,0 @@
# Copyright (C) 2021 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
on post-fs-data
start deviceauth_service
service deviceauth_service /system/bin/deviceauth_service
class z_core
user system
group system shell
seclabel u:r:deviceauth_service:s0