Home
last modified time | relevance | path

Searched refs:secontext (Results 1 – 25 of 42) sorted by relevance

12

/system/core/init/
Dueventd_test.cpp153 char* secontext; in TEST() local
154 ASSERT_EQ(0, selabel_lookup(sehandle.get(), &secontext, files_and_modes[i].file, in TEST()
156 files_and_modes[i].expected_context = secontext; in TEST()
157 freecon(secontext); in TEST()
169 char* secontext; in TEST() local
170 int result = selabel_lookup(sehandle.get(), &secontext, files_and_modes[i].file, in TEST()
175 if (files_and_modes[i].expected_context != secontext) { in TEST()
180 freecon(secontext); in TEST()
Dutil.cpp115 std::string secontext; in CreateSocket() local
116 if (SelabelLookupFileContext(addr.sun_path, S_IFSOCK, &secontext) && !secontext.empty()) { in CreateSocket()
117 setfscreatecon(secontext.c_str()); in CreateSocket()
130 if (!secontext.empty()) { in CreateSocket()
182 std::string secontext; in OpenFile() local
183 if (SelabelLookupFileContext(path, mode, &secontext) && !secontext.empty()) { in OpenFile()
184 setfscreatecon(secontext.c_str()); in OpenFile()
189 if (!secontext.empty()) { in OpenFile()
252 std::string secontext; in make_dir() local
253 if (SelabelLookupFileContext(path, mode, &secontext) && !secontext.empty()) { in make_dir()
[all …]
Ddevices.cpp250 std::string secontext; in MakeDevice() local
251 if (!SelabelLookupFileContextBestMatch(path, links, mode, &secontext)) { in MakeDevice()
255 if (!secontext.empty()) { in MakeDevice()
256 setfscreatecon(secontext.c_str()); in MakeDevice()
271 if (mknod(path.c_str(), mode, dev) && (errno == EEXIST) && !secontext.empty()) { in MakeDevice()
279 bool different = fcon != secontext; in MakeDevice()
282 if (different && lsetfilecon(path.c_str(), secontext.c_str())) { in MakeDevice()
283 PLOG(ERROR) << "Cannot set '" << secontext << "' SELinux label on '" << path in MakeDevice()
294 if (!secontext.empty()) { in MakeDevice()
Dbuiltins.cpp787 std::string secontext; in MakeSymlink() local
789 if (SelabelLookupFileContext(linkpath, 0, &secontext) && !secontext.empty()) { in MakeSymlink()
790 setfscreatecon(secontext.c_str()); in MakeSymlink()
795 if (!secontext.empty()) { in MakeSymlink()
/system/vold/
Dvold_prepare_subdirs.cpp60 auto secontext = std::unique_ptr<char, void (*)(char*)>(nullptr, freecon); in prepare_dir() local
63 secontext.reset(tmp_secontext); in prepare_dir()
66 << gid << " context " << (secontext ? secontext.get() : "null") in prepare_dir()
68 if (secontext) { in prepare_dir()
69 if (setfscreatecon(secontext.get()) != 0) { in prepare_dir()
77 if (secontext) { in prepare_dir()
84 if (strcmp(secontext.get(), oldsecontext.get()) != 0) { in prepare_dir()
86 << ((char*)secontext.get()) << ": " << path; in prepare_dir()
87 if (lsetfilecon(path.c_str(), secontext.get()) != 0) { in prepare_dir()
DUtils.cpp85 char* secontext = nullptr; in CreateDeviceNode() local
87 if (!selabel_lookup(sehandle, &secontext, cpath, S_IFBLK)) { in CreateDeviceNode()
88 setfscreatecon(secontext); in CreateDeviceNode()
101 if (secontext) { in CreateDeviceNode()
103 freecon(secontext); in CreateDeviceNode()
122 char* secontext = nullptr; in PrepareDir() local
124 if (!selabel_lookup(sehandle, &secontext, cpath, S_IFDIR)) { in PrepareDir()
125 setfscreatecon(secontext); in PrepareDir()
131 if (secontext) { in PrepareDir()
133 freecon(secontext); in PrepareDir()
/system/sepolicy/prebuilts/api/26.0/private/
Disolated_app.te33 # is modified to change the secontext when accessing the lower filesystem.
Dadbd.te124 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/26.0/public/
Dmediaserver.te122 # This should be removed if sdcardfs is modified to alter the secontext for its
Dkernel.te74 # This should be removed if sdcardfs is modified to alter the secontext for its
Ddumpstate.te193 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/27.0/public/
Dmediaserver.te122 # This should be removed if sdcardfs is modified to alter the secontext for its
Dkernel.te75 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/27.0/private/
Disolated_app.te33 # is modified to change the secontext when accessing the lower filesystem.
Dadbd.te126 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/29.0/public/
Dmediaserver.te116 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/28.0/public/
Dkernel.te76 # This should be removed if sdcardfs is modified to alter the secontext for its
Dmediaserver.te119 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/30.0/public/
Dmediaserver.te115 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/public/
Dmediaserver.te113 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/prebuilts/api/28.0/private/
Disolated_app.te31 # is modified to change the secontext when accessing the lower filesystem.
Dadbd.te131 # This should be removed if sdcardfs is modified to alter the secontext for its
/system/sepolicy/private/
Disolated_app.te35 # is modified to change the secontext when accessing the lower filesystem.
/system/sepolicy/prebuilts/api/29.0/private/
Disolated_app.te31 # is modified to change the secontext when accessing the lower filesystem.
/system/sepolicy/prebuilts/api/30.0/private/
Disolated_app.te35 # is modified to change the secontext when accessing the lower filesystem.

12