Skip to contentSkip to conversation

tmpfs_t

DISCUSSION Stephen D. Smalley 1 participant 1 message Feb 4, 2003 SELinux security module

lore
Share & tools
lore
#0 lore raw
Quoted 5 lines

For UML and busy Apache servers using tmpfs as /tmp is common practise. The current SE Linux setup will force many of the people who run big servers to change their operation in a way that will hurt performance to support running SE Linux.

You can use tmpfs as /tmp, as long as you are ok with the same labeling behavior and policy for /tmp and for System V shared memory and shared anonymous mappings. That may be reasonable.

Quoted 6 lines

I've experimented with using chcon to set the type after mounting which seems to work OK.

I believe that the best option is to label the root inode of tmpfs as system_u:object_r:tmp_t via initial_sid_contexts. I've been looking at the kernel code, is superblock_doinit() the right place to do a change?

Doesn't help. We already provide labeling for tmpfs (see the tmpfs entry in policy/fs_use). There is only an issue if you want to distinguish different instances of tmpfs mounts.

--
Stephen Smalley, NSA
[email protected]

--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.