Home
last modified time | relevance | path

Searched refs:OsAccountType (Results 1 – 25 of 71) sorted by relevance

123

/base/customization/enterprise_device_management/services/edm_plugin/src/
Dadd_os_account_plugin.cpp54 OHOS::AccountSA::OsAccountType accountType = ParseOsAccountType(type); in OnSetPolicy()
55 if (accountType == OHOS::AccountSA::OsAccountType::END) { in OnSetPolicy()
88 OHOS::AccountSA::OsAccountType AddOsAccountPlugin::ParseOsAccountType(int32_t type) in ParseOsAccountType()
90 if (type >= static_cast<int32_t>(OHOS::AccountSA::OsAccountType::ADMIN) in ParseOsAccountType()
91 && type < static_cast<int32_t>(OHOS::AccountSA::OsAccountType::END)) { in ParseOsAccountType()
92 return static_cast<OHOS::AccountSA::OsAccountType>(type); in ParseOsAccountType()
94 return OHOS::AccountSA::OsAccountType::END; in ParseOsAccountType()
/base/account/os_account/interfaces/innerkits/osaccount/native/include/
Dos_account_info.h29 } OsAccountType; typedef
54 … OsAccountInfo(int localId, const std::string localName, OsAccountType type, int64_t serialNumber);
56 …ountInfo(int localId, const std::string localName, const std::string shortName, OsAccountType type,
71 OsAccountType GetType() const;
73 void SetType(OsAccountType type);
139 OsAccountType type_ = OsAccountType::ADMIN;
Dos_account_manager.h58 …static ErrCode CreateOsAccount(const std::string &name, const OsAccountType &type, OsAccountInfo &…
70 const OsAccountType& type, OsAccountInfo& osAccountInfo);
84 … const OsAccountType& type, const CreateOsAccountOptions& options, OsAccountInfo& osAccountInfo);
110 …static ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domain…
259 static ErrCode GetOsAccountTypeFromProcess(OsAccountType &type);
/base/account/os_account/frameworks/osaccount/native/test/unittest/
Dos_account_info_test.cpp31 const OsAccountType INT_TYPE = OsAccountType::ADMIN;
194 OsAccountType type = INT_TYPE;
533 osAccountInfo.SetType(OsAccountType::NORMAL);
554 osAccountInfo.SetType(OsAccountType::GUEST);
580 osAccountInfo.SetType(OsAccountType::GUEST);
608 …OsAccountManager::CreateOsAccount(STRING_NAME, "shortName", OsAccountType::NORMAL, osAccountInfoOn…
610 …OsAccountManager::CreateOsAccount(STRING_NAME, STRING_NAME, OsAccountType::NORMAL, osAccountInfoTw…
628 …OsAccountManager::CreateOsAccount(STRING_NAME, "shortName", OsAccountType::NORMAL, options, osAcco…
631 …OsAccountManager::CreateOsAccount(STRING_NAME, STRING_NAME, OsAccountType::NORMAL, osAccountInfoTw…
664 OsAccountManager::CreateOsAccount("..", OsAccountType::NORMAL, osAccountInfoOne));
[all …]
/base/account/os_account/test/fuzztest/osaccount/createosaccount_fuzzer/
Dcreateosaccount_fuzzer.cpp35 OsAccountType testType = static_cast<OsAccountType>(size % CONSTANTS_NUMBER_FIVE); in CreateOsAccountFuzzTest()
/base/account/os_account/services/accountmgr/include/osaccount/
Diinner_os_account_manager.h35 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) override;
37 …const OsAccountType &type, OsAccountInfo &osAccountInfo, const CreateOsAccountOptions &options = {…
40 ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domainInfo,
54 ErrCode GetOsAccountType(const int id, OsAccountType &type) override;
97 ErrCode BindDomainAccount(const OsAccountType &type, const DomainAccountInfo &domainAccountInfo,
117 ErrCode PrepareOsAccountInfo(const std::string &name, const OsAccountType &type,
119 …sAccountInfo(const std::string &localName, const std::string &shortName, const OsAccountType &type,
121 …sAccountInfo(const std::string &localName, const std::string &shortName, const OsAccountType &type,
Dos_account_domain_account_callback.h30 …CheckAndCreateDomainAccountCallback(const OsAccountType &type, const DomainAccountInfo &domainAcco…
35 OsAccountType type_;
Diinner_os_account.h32 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) = 0;
34 …const OsAccountType &type, OsAccountInfo &osAccountInfo, const CreateOsAccountOptions &options = {…
37 …virtual ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domai…
51 virtual ErrCode GetOsAccountType(const int id, OsAccountType &type) = 0;
Dos_account_manager_service.h35 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) override;
37 …const OsAccountType &type, OsAccountInfo &osAccountInfo, const CreateOsAccountOptions &options = {…
38 ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domainInfo,
68 ErrCode GetOsAccountTypeFromProcess(OsAccountType &type) override;
/base/account/os_account/test/fuzztest/osaccount/createosaccountfordomain_fuzzer/
Dcreateosaccountfordomain_fuzzer.cpp37 OsAccountType testType = static_cast<OsAccountType>(size % CONSTANTS_NUMBER_FIVE); in CreateOsAccountForDomainFuzzTest()
/base/account/os_account/frameworks/osaccount/native/test/moduletest/
Dos_account_manager_module_test.cpp346 …ASSERT_EQ(OsAccountManager::CreateOsAccount(STRING_TEST_NAME, OsAccountType::GUEST, osAccountInfoO…
354 EXPECT_EQ(osAccountInfoOne.GetType(), OsAccountType::GUEST);
367 …EXPECT_NE(OsAccountManager::CreateOsAccount(STRING_NAME_OUT_OF_RANGE, OsAccountType::GUEST, osAcco…
380 …EXPECT_NE(OsAccountManager::CreateOsAccount(STRING_EMPTY, OsAccountType::GUEST, osAccountInfoOne),…
392 …ASSERT_EQ(OsAccountManager::CreateOsAccount(STRING_TEST_NAME, OsAccountType::ADMIN, osAccountInfoO…
400 EXPECT_EQ(osAccountInfoOne.GetType(), OsAccountType::ADMIN);
413 …ASSERT_EQ(OsAccountManager::CreateOsAccount(STRING_TEST_NAME, OsAccountType::NORMAL, osAccountInfo…
421 EXPECT_EQ(osAccountInfoOne.GetType(), OsAccountType::NORMAL);
434 …EXPECT_NE(OsAccountManager::CreateOsAccount(STRING_EMPTY, OsAccountType::GUEST, osAccountInfoOne),…
513 …ASSERT_EQ(OsAccountManager::CreateOsAccount(STRING_TEST_NAME, OsAccountType::GUEST, osAccountInfoO…
[all …]
/base/account/os_account/frameworks/osaccount/native/src/
Dos_account_info.cpp49 OsAccountInfo::OsAccountInfo(int localId, const std::string localName, OsAccountType type, int64_t … in OsAccountInfo()
53 …ountInfo(int localId, const std::string localName, const std::string shortName, OsAccountType type, in OsAccountInfo()
88 OsAccountType OsAccountInfo::GetType() const in GetType()
93 void OsAccountInfo::SetType(OsAccountType type) in SetType()
247 OHOS::AccountSA::GetDataByType<OsAccountType>( in FromJson()
350 if ((type_ < OsAccountType::ADMIN) || (type_ >= OsAccountType::END) || in ParamCheck()
351 (localId_ == Constants::START_USER_ID && type_ != OsAccountType::ADMIN)) { in ParamCheck()
Dos_account_manager.cpp25 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) in CreateOsAccount()
31 …const std::string &localName, const std::string &shortName, const OsAccountType &type, OsAccountIn… in CreateOsAccount()
37 const OsAccountType& type, const CreateOsAccountOptions& options, OsAccountInfo& osAccountInfo) in CreateOsAccount()
52 ErrCode OsAccountManager::CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountIn… in CreateOsAccountForDomain()
160 ErrCode OsAccountManager::GetOsAccountTypeFromProcess(OsAccountType &type) in GetOsAccountTypeFromProcess()
/base/account/os_account/services/accountmgr/test/unittest/os_account/
Dos_account_data_storage_test.cpp41 const OsAccountType INT_TYPE = OsAccountType::ADMIN;
Dos_account_file_manager_multiple_thread_test.cpp34 const OsAccountType OS_ACCOUNT_TYPE = OsAccountType::ADMIN;
/base/account/os_account/test/fuzztest/osaccount_stub/createosaccountfordomainstub_fuzzer/
Dcreateosaccountfordomainstub_fuzzer.cpp40 OsAccountType testType = static_cast<OsAccountType>(size % CONSTANTS_NUMBER_FIVE); in CreateOsAccountForDomainStubFuzzTest()
/base/account/os_account/tools/acm/src/
Daccount_command.cpp97 std::string &shortName, OsAccountType &osAccountType, std::vector<std::string> &disallowedList) in ParseCreateCommandOpt()
130 OsAccountType osAccountType = static_cast<OsAccountType>(-1); in RunAsCreateCommand()
134 if (name.size() == 0 || osAccountType == static_cast<OsAccountType>(-1)) { in RunAsCreateCommand()
141 if (osAccountType == static_cast<OsAccountType>(-1)) { in RunAsCreateCommand()
447 std::string &shortName, OsAccountType &type, std::vector<std::string> &disallowedList) in RunAsCreateCommandExistentOptionArgument()
652 ErrCode AccountCommand::AnalyzeTypeArgument(OsAccountType &type) in AnalyzeTypeArgument()
658 type = OsAccountType::ADMIN; in AnalyzeTypeArgument()
660 type = OsAccountType::NORMAL; in AnalyzeTypeArgument()
662 type = OsAccountType::GUEST; in AnalyzeTypeArgument()
/base/account/os_account/frameworks/osaccount/core/include/
Dos_account.h29 …ErrCode CreateOsAccount(const std::string &name, const OsAccountType &type, OsAccountInfo &osAccou…
30 …ateOsAccount(const std::string &localName, const std::string &shortName, const OsAccountType &type,
34 ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domainInfo,
51 ErrCode GetOsAccountTypeFromProcess(OsAccountType &type);
Dios_account.h36 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) = 0;
38 …const OsAccountType &type, OsAccountInfo &osAccountInfo, const CreateOsAccountOptions &options = {…
41 …virtual ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domai…
60 virtual ErrCode GetOsAccountTypeFromProcess(OsAccountType &type) = 0;
Dos_account_proxy.h30 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) override;
31 …ateOsAccount(const std::string &localName, const std::string &shortName, const OsAccountType &type,
35 ErrCode CreateOsAccountForDomain(const OsAccountType &type, const DomainAccountInfo &domainInfo,
54 ErrCode GetOsAccountTypeFromProcess(OsAccountType &type) override;
/base/account/os_account/tools/acm/include/
Daccount_command.h128 std::string &shortName, OsAccountType &type, std::vector<std::string> &disallowedList);
140 … std::string &shortName, OsAccountType &osAccountType, std::vector<std::string> &disallowedList);
142 ErrCode AnalyzeTypeArgument(OsAccountType &type);
/base/account/os_account/services/accountmgr/src/osaccount/
Dos_account_manager_service.cpp29 const std::map<OsAccountType, std::string> DUMP_TYPE_MAP = {
30 {OsAccountType::ADMIN, "admin"},
31 {OsAccountType::NORMAL, "normal"},
32 {OsAccountType::GUEST, "guest"},
87 const std::string &name, const OsAccountType &type, OsAccountInfo &osAccountInfo) in CreateOsAccount()
99 const OsAccountType &type, OsAccountInfo &osAccountInfo, const CreateOsAccountOptions &options) in CreateOsAccount()
133 if (!isAllowedCreateAdmin && (osAccountInfo.GetType() == OsAccountType::ADMIN)) { in CreateOsAccountWithFullInfo()
154 if (!isAllowedCreateAdmin && osAccountInfo.GetType() == OsAccountType::ADMIN) { in UpdateOsAccountWithFullInfo()
162 ErrCode OsAccountManagerService::CreateOsAccountForDomain(const OsAccountType &type, in CreateOsAccountForDomain()
173 if ((type < OsAccountType::ADMIN) || (type >= OsAccountType::END)) { in CreateOsAccountForDomain()
[all …]
/base/account/os_account/test/fuzztest/osaccount/createosaccountwithshortname_fuzzer/
Dcreateosaccountwithshortname_fuzzer.cpp56 OsAccountType testType = static_cast<OsAccountType>(size % CONSTANTS_NUMBER_FIVE); in CreateOsAccountWithShortNameFuzzTest()
/base/account/os_account/frameworks/osaccount/core/test/unittest/
Dos_account_test.cpp122 …ErrCode errCode = g_osAccount->CreateOsAccount(STRING_NAME_OUT_OF_RANGE, OsAccountType::GUEST, osA…
136 … ErrCode errCode = g_osAccount->CreateOsAccount(STRING_EMPTY, OsAccountType::GUEST, osAccountInfo);
272 OsAccountType type = NORMAL;
287 OsAccountType type = NORMAL;
306 OsAccountType type = NORMAL;
/base/account/os_account/test/fuzztest/osaccount/getosaccounttypefromprocess_fuzzer/
Dgetosaccounttypefromprocess_fuzzer.cpp32 OsAccountType testOsAccountType; in QueryOsAccountByIdFuzzTest()

123