Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- default with systemd:
- bitbake secure-core-image-minimal -e | grep USE_DEVFS
- USE_DEVFS="1"
- By default, YP is configured with USE_DEVFS= “1”, and the owner of devices if “root” with 0600 permissions.
- ... but there are also groups which allow access of non root to various devices - a typical example is the dialout group
- ... also not all of them are with 0600 permissions
- drwxr-xr-x 16 root root 3.3K Sep 26 17:41 .
- drwxr-xr-x 17 root root 1.0K Sep 26 17:36 ..
- crw-r--r-- 1 root root 10, 235 Sep 26 17:41 autofs
- drwxr-xr-x 2 root root 560 Sep 26 17:41 block
- drwxr-xr-x 2 root root 60 Sep 26 17:41 bsg
- crw-rw---- 1 root disk 10, 234 Sep 26 17:41 btrfs-control
- drwxr-xr-x 3 root root 60 Sep 26 17:41 bus
- lrwxrwxrwx 1 root root 3 Sep 26 17:41 cdrom -> sr0
- drwxr-xr-x 2 root root 2.7K Sep 26 17:41 char
- crw------- 1 root root 5, 1 Sep 26 17:41 console
- drwxr-xr-x 6 root root 120 Sep 26 17:41 cpu
- crw------- 1 root root 10, 125 Sep 26 17:41 cpu_dma_latency
- crw------- 1 root root 10, 203 Sep 26 17:41 cuse
- drwxr-xr-x 6 root root 120 Sep 26 17:41 disk
- drwxr-xr-x 3 root root 80 Sep 26 17:41 dri
- crw-rw---- 1 root video 29, 0 Sep 26 17:41 fb0
- lrwxrwxrwx 1 root root 13 Sep 26 17:41 fd -> /proc/self/fd
- crw-rw-rw- 1 root root 1, 7 Sep 26 17:41 full
- crw-rw-rw- 1 root root 10, 229 Sep 26 17:41 fuse
- crw------- 1 root root 10, 228 Sep 26 17:41 hpet
- crw------- 1 root root 10, 183 Sep 26 17:41 hwrng
- lrwxrwxrwx 1 root root 12 Sep 26 17:41 initctl -> /run/initctl
- drwxr-xr-x 4 root root 180 Sep 26 17:41 input
- crw-r--r-- 1 root root 1, 11 Sep 26 17:41 kmsg
- lrwxrwxrwx 1 root root 28 Sep 26 17:41 log -> /run/systemd/journal/dev-log
- crw-rw---- 1 root disk 10, 237 Sep 26 17:41 loop-control
- brw-rw---- 1 root disk 7, 0 Sep 26 17:41 loop0
- brw-rw---- 1 root disk 7, 1 Sep 26 17:41 loop1
- brw-rw---- 1 root disk 7, 2 Sep 26 17:41 loop2
- brw-rw---- 1 root disk 7, 3 Sep 26 17:41 loop3
- brw-rw---- 1 root disk 7, 4 Sep 26 17:41 loop4
- brw-rw---- 1 root disk 7, 5 Sep 26 17:41 loop5
- brw-rw---- 1 root disk 7, 6 Sep 26 17:41 loop6
- brw-rw---- 1 root disk 7, 7 Sep 26 17:41 loop7
- drwxr-xr-x 2 root root 60 Sep 26 17:41 mapper
- drwxrwxrwt 2 root root 40 Sep 26 17:41 mqueue
- drwxr-xr-x 2 root root 60 Sep 26 17:41 net
- crw-rw-rw- 1 root root 1, 3 Sep 26 17:41 null
- crw-r----- 1 root kmem 1, 4 Sep 26 17:41 port
- crw------- 1 root root 108, 0 Sep 26 17:41 ppp
- crw-rw-rw- 1 root tty 5, 2 Sep 26 17:41 ptmx
- drwxr-xr-x 2 root root 0 Sep 26 17:41 pts
- brw-rw---- 1 root disk 1, 0 Sep 26 17:41 ram0
- brw-rw---- 1 root disk 1, 1 Sep 26 17:41 ram1
- brw-rw---- 1 root disk 1, 10 Sep 26 17:41 ram10
- brw-rw---- 1 root disk 1, 11 Sep 26 17:41 ram11
- brw-rw---- 1 root disk 1, 12 Sep 26 17:41 ram12
- brw-rw---- 1 root disk 1, 13 Sep 26 17:41 ram13
- brw-rw---- 1 root disk 1, 14 Sep 26 17:41 ram14
- brw-rw---- 1 root disk 1, 15 Sep 26 17:41 ram15
- brw-rw---- 1 root disk 1, 2 Sep 26 17:41 ram2
- brw-rw---- 1 root disk 1, 3 Sep 26 17:41 ram3
- brw-rw---- 1 root disk 1, 4 Sep 26 17:41 ram4
- brw-rw---- 1 root disk 1, 5 Sep 26 17:41 ram5
- brw-rw---- 1 root disk 1, 6 Sep 26 17:41 ram6
- brw-rw---- 1 root disk 1, 7 Sep 26 17:41 ram7
- brw-rw---- 1 root disk 1, 8 Sep 26 17:41 ram8
- brw-rw---- 1 root disk 1, 9 Sep 26 17:41 ram9
- crw-rw-rw- 1 root root 1, 8 Sep 26 17:41 random
- crw-rw-r-- 1 root root 10, 242 Sep 26 17:41 rfkill
- lrwxrwxrwx 1 root root 4 Sep 26 17:41 rtc -> rtc0
- crw------- 1 root root 254, 0 Sep 26 17:41 rtc0
- drwxrwxrwt 2 root root 40 Sep 26 17:41 shm
- drwxr-xr-x 2 root root 80 Sep 26 17:41 snd
- brw-rw---- 1 root cdrom 11, 0 Sep 26 17:41 sr0
- lrwxrwxrwx 1 root root 15 Sep 26 17:41 stderr -> /proc/self/fd/2
- lrwxrwxrwx 1 root root 15 Sep 26 17:41 stdin -> /proc/self/fd/0
- lrwxrwxrwx 1 root root 15 Sep 26 17:41 stdout -> /proc/self/fd/1
- crw-rw-rw- 1 root tty 5, 0 Sep 26 17:43 tty
- crw--w---- 1 root tty 4, 0 Sep 26 17:41 tty0
- crw--w---- 1 root tty 4, 1 Sep 26 17:41 tty1
- crw--w---- 1 root tty 4, 10 Sep 26 17:41 tty10
- crw--w---- 1 root tty 4, 11 Sep 26 17:41 tty11
- crw--w---- 1 root tty 4, 12 Sep 26 17:41 tty12
- crw--w---- 1 root tty 4, 13 Sep 26 17:41 tty13
- crw--w---- 1 root tty 4, 14 Sep 26 17:41 tty14
- crw--w---- 1 root tty 4, 15 Sep 26 17:41 tty15
- crw--w---- 1 root tty 4, 16 Sep 26 17:41 tty16
- crw--w---- 1 root tty 4, 17 Sep 26 17:41 tty17
- crw--w---- 1 root tty 4, 18 Sep 26 17:41 tty18
- crw--w---- 1 root tty 4, 19 Sep 26 17:41 tty19
- crw--w---- 1 root tty 4, 2 Sep 26 17:41 tty2
- crw--w---- 1 root tty 4, 20 Sep 26 17:41 tty20
- crw--w---- 1 root tty 4, 21 Sep 26 17:41 tty21
- crw--w---- 1 root tty 4, 22 Sep 26 17:41 tty22
- crw--w---- 1 root tty 4, 23 Sep 26 17:41 tty23
- crw--w---- 1 root tty 4, 24 Sep 26 17:41 tty24
- crw--w---- 1 root tty 4, 25 Sep 26 17:41 tty25
- crw--w---- 1 root tty 4, 26 Sep 26 17:41 tty26
- crw--w---- 1 root tty 4, 27 Sep 26 17:41 tty27
- crw--w---- 1 root tty 4, 28 Sep 26 17:41 tty28
- crw--w---- 1 root tty 4, 29 Sep 26 17:41 tty29
- crw--w---- 1 root tty 4, 3 Sep 26 17:41 tty3
- crw--w---- 1 root tty 4, 30 Sep 26 17:41 tty30
- crw--w---- 1 root tty 4, 31 Sep 26 17:41 tty31
- crw--w---- 1 root tty 4, 32 Sep 26 17:41 tty32
- crw--w---- 1 root tty 4, 33 Sep 26 17:41 tty33
- crw--w---- 1 root tty 4, 34 Sep 26 17:41 tty34
- crw--w---- 1 root tty 4, 35 Sep 26 17:41 tty35
- crw--w---- 1 root tty 4, 36 Sep 26 17:41 tty36
- crw--w---- 1 root tty 4, 37 Sep 26 17:41 tty37
- crw--w---- 1 root tty 4, 38 Sep 26 17:41 tty38
- crw--w---- 1 root tty 4, 39 Sep 26 17:41 tty39
- crw--w---- 1 root tty 4, 4 Sep 26 17:41 tty4
- crw--w---- 1 root tty 4, 40 Sep 26 17:41 tty40
- crw--w---- 1 root tty 4, 41 Sep 26 17:41 tty41
- crw--w---- 1 root tty 4, 42 Sep 26 17:41 tty42
- crw--w---- 1 root tty 4, 43 Sep 26 17:41 tty43
- crw--w---- 1 root tty 4, 44 Sep 26 17:41 tty44
- crw--w---- 1 root tty 4, 45 Sep 26 17:41 tty45
- crw--w---- 1 root tty 4, 46 Sep 26 17:41 tty46
- crw--w---- 1 root tty 4, 47 Sep 26 17:41 tty47
- crw--w---- 1 root tty 4, 48 Sep 26 17:41 tty48
- crw--w---- 1 root tty 4, 49 Sep 26 17:41 tty49
- crw--w---- 1 root tty 4, 5 Sep 26 17:41 tty5
- crw--w---- 1 root tty 4, 50 Sep 26 17:41 tty50
- crw--w---- 1 root tty 4, 51 Sep 26 17:41 tty51
- crw--w---- 1 root tty 4, 52 Sep 26 17:41 tty52
- crw--w---- 1 root tty 4, 53 Sep 26 17:41 tty53
- crw--w---- 1 root tty 4, 54 Sep 26 17:41 tty54
- crw--w---- 1 root tty 4, 55 Sep 26 17:41 tty55
- crw--w---- 1 root tty 4, 56 Sep 26 17:41 tty56
- crw--w---- 1 root tty 4, 57 Sep 26 17:41 tty57
- crw--w---- 1 root tty 4, 58 Sep 26 17:41 tty58
- crw--w---- 1 root tty 4, 59 Sep 26 17:41 tty59
- crw--w---- 1 root tty 4, 6 Sep 26 17:41 tty6
- crw--w---- 1 root tty 4, 60 Sep 26 17:41 tty60
- crw--w---- 1 root tty 4, 61 Sep 26 17:41 tty61
- crw--w---- 1 root tty 4, 62 Sep 26 17:41 tty62
- crw--w---- 1 root tty 4, 63 Sep 26 17:41 tty63
- crw--w---- 1 root tty 4, 7 Sep 26 17:41 tty7
- crw--w---- 1 root tty 4, 8 Sep 26 17:41 tty8
- crw--w---- 1 root tty 4, 9 Sep 26 17:41 tty9
- crw------- 1 root tty 4, 64 Sep 26 17:51 ttyS0
- crw--w---- 1 root tty 4, 65 Sep 26 17:41 ttyS1
- crw-rw---- 1 root dialout 4, 66 Sep 26 17:41 ttyS2
- crw-rw---- 1 root dialout 4, 67 Sep 26 17:41 ttyS3
- crw------- 1 root root 10, 223 Sep 26 17:41 uinput
- crw-rw-rw- 1 root root 1, 9 Sep 26 17:41 urandom
- crw-rw---- 1 root tty 7, 0 Sep 26 17:41 vcs
- crw-rw---- 1 root tty 7, 1 Sep 26 17:41 vcs1
- crw-rw---- 1 root tty 7, 2 Sep 26 17:41 vcs2
- crw-rw---- 1 root tty 7, 3 Sep 26 17:41 vcs3
- crw-rw---- 1 root tty 7, 4 Sep 26 17:41 vcs4
- crw-rw---- 1 root tty 7, 5 Sep 26 17:41 vcs5
- crw-rw---- 1 root tty 7, 6 Sep 26 17:41 vcs6
- crw-rw---- 1 root tty 7, 128 Sep 26 17:41 vcsa
- crw-rw---- 1 root tty 7, 129 Sep 26 17:41 vcsa1
- crw-rw---- 1 root tty 7, 130 Sep 26 17:41 vcsa2
- crw-rw---- 1 root tty 7, 131 Sep 26 17:41 vcsa3
- crw-rw---- 1 root tty 7, 132 Sep 26 17:41 vcsa4
- crw-rw---- 1 root tty 7, 133 Sep 26 17:41 vcsa5
- crw-rw---- 1 root tty 7, 134 Sep 26 17:41 vcsa6
- crw-rw---- 1 root tty 7, 64 Sep 26 17:41 vcsu
- crw-rw---- 1 root tty 7, 65 Sep 26 17:41 vcsu1
- crw-rw---- 1 root tty 7, 66 Sep 26 17:41 vcsu2
- crw-rw---- 1 root tty 7, 67 Sep 26 17:41 vcsu3
- crw-rw---- 1 root tty 7, 68 Sep 26 17:41 vcsu4
- crw-rw---- 1 root tty 7, 69 Sep 26 17:41 vcsu5
- crw-rw---- 1 root tty 7, 70 Sep 26 17:41 vcsu6
- brw-rw---- 1 root disk 253, 0 Sep 26 17:41 vda
- crw------- 1 root root 10, 127 Sep 26 17:41 vga_arbiter
- crw-rw-rw- 1 root root 10, 126 Sep 26 17:41 vsock
- crw-rw-rw- 1 root root 1, 5 Sep 26 17:41 zero
- sysv + rust coreutils:
- drwxr-xr-x 15 root root 3.0K Sep 26 18:09 .
- drwxr-xr-x 17 root root 1.0K Sep 26 18:09 ..
- crw-r--r-- 1 root root 10, 235 Sep 26 18:09 autofs
- drwxr-xr-x 2 root root 560 Sep 26 18:09 block
- drwxr-xr-x 2 root root 60 Sep 26 18:09 bsg
- crw-rw---- 1 root disk 10, 234 Sep 26 18:09 btrfs-control
- drwxr-xr-x 3 root root 60 Sep 26 18:09 bus
- lrwxrwxrwx 1 root root 3 Sep 26 18:09 cdrom -> sr0
- drwxr-xr-x 2 root root 2.4K Sep 26 18:09 char
- crw------- 1 root root 5, 1 Sep 26 18:09 console
- drwxr-xr-x 6 root root 120 Sep 26 18:09 cpu
- crw------- 1 root root 10, 125 Sep 26 18:09 cpu_dma_latency
- crw------- 1 root root 10, 203 Sep 26 18:09 cuse
- drwxr-xr-x 5 root root 100 Sep 26 18:09 disk
- drwxr-xr-x 3 root root 80 Sep 26 18:09 dri
- crw-rw---- 1 root video 29, 0 Sep 26 18:09 fb0
- lrwxrwxrwx 1 root root 13 Sep 26 18:09 fd -> /proc/self/fd
- crw-rw-rw- 1 root root 1, 7 Sep 26 18:09 full
- crw-rw-rw- 1 root root 10, 229 Sep 26 18:09 fuse
- crw------- 1 root root 10, 228 Sep 26 18:09 hpet
- crw------- 1 root root 10, 183 Sep 26 18:09 hwrng
- prw------- 1 root root 0 Sep 26 18:09 initctl
- drwxr-xr-x 4 root root 180 Sep 26 18:09 input
- crw-r--r-- 1 root root 1, 11 Sep 26 18:09 kmsg
- srw-rw-rw- 1 root root 0 Sep 26 18:09 log
- crw-rw---- 1 root disk 10, 237 Sep 26 18:09 loop-control
- brw-rw---- 1 root disk 7, 0 Sep 26 18:09 loop0
- brw-rw---- 1 root disk 7, 1 Sep 26 18:09 loop1
- brw-rw---- 1 root disk 7, 2 Sep 26 18:09 loop2
- brw-rw---- 1 root disk 7, 3 Sep 26 18:09 loop3
- brw-rw---- 1 root disk 7, 4 Sep 26 18:09 loop4
- brw-rw---- 1 root disk 7, 5 Sep 26 18:09 loop5
- brw-rw---- 1 root disk 7, 6 Sep 26 18:09 loop6
- brw-rw---- 1 root disk 7, 7 Sep 26 18:09 loop7
- drwxr-xr-x 2 root root 60 Sep 26 18:09 mapper
- lrwxrwxrwx 1 root root 12 Sep 26 18:09 mtab -> /proc/mounts
- drwxr-xr-x 2 root root 60 Sep 26 18:09 net
- crw-rw-rw- 1 root root 1, 3 Sep 26 18:09 null
- crw-r----- 1 root kmem 1, 4 Sep 26 18:09 port
- crw------- 1 root root 108, 0 Sep 26 18:09 ppp
- crw-rw-rw- 1 root tty 5, 2 Sep 26 18:09 ptmx
- drwxr-xr-x 2 root root 0 Sep 26 18:09 pts
- brw-rw---- 1 root disk 1, 0 Sep 26 18:09 ram0
- brw-rw---- 1 root disk 1, 1 Sep 26 18:09 ram1
- brw-rw---- 1 root disk 1, 10 Sep 26 18:09 ram10
- brw-rw---- 1 root disk 1, 11 Sep 26 18:09 ram11
- brw-rw---- 1 root disk 1, 12 Sep 26 18:09 ram12
- brw-rw---- 1 root disk 1, 13 Sep 26 18:09 ram13
- brw-rw---- 1 root disk 1, 14 Sep 26 18:09 ram14
- brw-rw---- 1 root disk 1, 15 Sep 26 18:09 ram15
- brw-rw---- 1 root disk 1, 2 Sep 26 18:09 ram2
- brw-rw---- 1 root disk 1, 3 Sep 26 18:09 ram3
- brw-rw---- 1 root disk 1, 4 Sep 26 18:09 ram4
- brw-rw---- 1 root disk 1, 5 Sep 26 18:09 ram5
- brw-rw---- 1 root disk 1, 6 Sep 26 18:09 ram6
- brw-rw---- 1 root disk 1, 7 Sep 26 18:09 ram7
- brw-rw---- 1 root disk 1, 8 Sep 26 18:09 ram8
- brw-rw---- 1 root disk 1, 9 Sep 26 18:09 ram9
- crw-rw-rw- 1 root root 1, 8 Sep 26 18:09 random
- crw-rw-r-- 1 root root 10, 242 Sep 26 18:09 rfkill
- lrwxrwxrwx 1 root root 4 Sep 26 18:09 rtc -> rtc0
- crw------- 1 root root 254, 0 Sep 26 18:09 rtc0
- drwxrwxrwt 2 root root 40 Sep 26 18:09 shm
- drwxr-xr-x 2 root root 80 Sep 26 18:09 snd
- brw-rw---- 1 root cdrom 11, 0 Sep 26 18:09 sr0
- lrwxrwxrwx 1 root root 15 Sep 26 18:09 stderr -> /proc/self/fd/2
- lrwxrwxrwx 1 root root 15 Sep 26 18:09 stdin -> /proc/self/fd/0
- lrwxrwxrwx 1 root root 15 Sep 26 18:09 stdout -> /proc/self/fd/1
- crw-rw-rw- 1 root tty 5, 0 Sep 26 18:09 tty
- crw--w---- 1 root tty 4, 0 Sep 26 18:09 tty0
- crw--w---- 1 root root 4, 1 Sep 26 18:09 tty1
- crw--w---- 1 root tty 4, 10 Sep 26 18:09 tty10
- crw--w---- 1 root tty 4, 11 Sep 26 18:09 tty11
- crw--w---- 1 root tty 4, 12 Sep 26 18:09 tty12
- crw--w---- 1 root tty 4, 13 Sep 26 18:09 tty13
- crw--w---- 1 root tty 4, 14 Sep 26 18:09 tty14
- crw--w---- 1 root tty 4, 15 Sep 26 18:09 tty15
- crw--w---- 1 root tty 4, 16 Sep 26 18:09 tty16
- crw--w---- 1 root tty 4, 17 Sep 26 18:09 tty17
- crw--w---- 1 root tty 4, 18 Sep 26 18:09 tty18
- crw--w---- 1 root tty 4, 19 Sep 26 18:09 tty19
- crw--w---- 1 root tty 4, 2 Sep 26 18:09 tty2
- crw--w---- 1 root tty 4, 20 Sep 26 18:09 tty20
- crw--w---- 1 root tty 4, 21 Sep 26 18:09 tty21
- crw--w---- 1 root tty 4, 22 Sep 26 18:09 tty22
- crw--w---- 1 root tty 4, 23 Sep 26 18:09 tty23
- crw--w---- 1 root tty 4, 24 Sep 26 18:09 tty24
- crw--w---- 1 root tty 4, 25 Sep 26 18:09 tty25
- crw--w---- 1 root tty 4, 26 Sep 26 18:09 tty26
- crw--w---- 1 root tty 4, 27 Sep 26 18:09 tty27
- crw--w---- 1 root tty 4, 28 Sep 26 18:09 tty28
- crw--w---- 1 root tty 4, 29 Sep 26 18:09 tty29
- crw--w---- 1 root tty 4, 3 Sep 26 18:09 tty3
- crw--w---- 1 root tty 4, 30 Sep 26 18:09 tty30
- crw--w---- 1 root tty 4, 31 Sep 26 18:09 tty31
- crw--w---- 1 root tty 4, 32 Sep 26 18:09 tty32
- crw--w---- 1 root tty 4, 33 Sep 26 18:09 tty33
- crw--w---- 1 root tty 4, 34 Sep 26 18:09 tty34
- crw--w---- 1 root tty 4, 35 Sep 26 18:09 tty35
- crw--w---- 1 root tty 4, 36 Sep 26 18:09 tty36
- crw--w---- 1 root tty 4, 37 Sep 26 18:09 tty37
- crw--w---- 1 root tty 4, 38 Sep 26 18:09 tty38
- crw--w---- 1 root tty 4, 39 Sep 26 18:09 tty39
- crw--w---- 1 root tty 4, 4 Sep 26 18:09 tty4
- crw--w---- 1 root tty 4, 40 Sep 26 18:09 tty40
- crw--w---- 1 root tty 4, 41 Sep 26 18:09 tty41
- crw--w---- 1 root tty 4, 42 Sep 26 18:09 tty42
- crw--w---- 1 root tty 4, 43 Sep 26 18:09 tty43
- crw--w---- 1 root tty 4, 44 Sep 26 18:09 tty44
- crw--w---- 1 root tty 4, 45 Sep 26 18:09 tty45
- crw--w---- 1 root tty 4, 46 Sep 26 18:09 tty46
- crw--w---- 1 root tty 4, 47 Sep 26 18:09 tty47
- crw--w---- 1 root tty 4, 48 Sep 26 18:09 tty48
- crw--w---- 1 root tty 4, 49 Sep 26 18:09 tty49
- crw--w---- 1 root tty 4, 5 Sep 26 18:09 tty5
- crw--w---- 1 root tty 4, 50 Sep 26 18:09 tty50
- crw--w---- 1 root tty 4, 51 Sep 26 18:09 tty51
- crw--w---- 1 root tty 4, 52 Sep 26 18:09 tty52
- crw--w---- 1 root tty 4, 53 Sep 26 18:09 tty53
- crw--w---- 1 root tty 4, 54 Sep 26 18:09 tty54
- crw--w---- 1 root tty 4, 55 Sep 26 18:09 tty55
- crw--w---- 1 root tty 4, 56 Sep 26 18:09 tty56
- crw--w---- 1 root tty 4, 57 Sep 26 18:09 tty57
- crw--w---- 1 root tty 4, 58 Sep 26 18:09 tty58
- crw--w---- 1 root tty 4, 59 Sep 26 18:09 tty59
- crw--w---- 1 root tty 4, 6 Sep 26 18:09 tty6
- crw--w---- 1 root tty 4, 60 Sep 26 18:09 tty60
- crw--w---- 1 root tty 4, 61 Sep 26 18:09 tty61
- crw--w---- 1 root tty 4, 62 Sep 26 18:09 tty62
- crw--w---- 1 root tty 4, 63 Sep 26 18:09 tty63
- crw--w---- 1 root tty 4, 7 Sep 26 18:09 tty7
- crw--w---- 1 root tty 4, 8 Sep 26 18:09 tty8
- crw--w---- 1 root tty 4, 9 Sep 26 18:09 tty9
- crw------- 1 root tty 4, 64 Sep 26 18:09 ttyS0
- crw--w---- 1 root root 4, 65 Sep 26 18:09 ttyS1
- crw-rw---- 1 root dialout 4, 66 Sep 26 18:09 ttyS2
- crw-rw---- 1 root dialout 4, 67 Sep 26 18:09 ttyS3
- crw------- 1 root root 10, 223 Sep 26 18:09 uinput
- crw-rw-rw- 1 root root 1, 9 Sep 26 18:09 urandom
- crw-rw---- 1 root tty 7, 0 Sep 26 18:09 vcs
- crw-rw---- 1 root tty 7, 1 Sep 26 18:09 vcs1
- crw-rw---- 1 root tty 7, 128 Sep 26 18:09 vcsa
- crw-rw---- 1 root tty 7, 129 Sep 26 18:09 vcsa1
- crw-rw---- 1 root tty 7, 64 Sep 26 18:09 vcsu
- crw-rw---- 1 root tty 7, 65 Sep 26 18:09 vcsu1
- brw-rw---- 1 root disk 253, 0 Sep 26 18:09 vda
- crw------- 1 root root 10, 127 Sep 26 18:09 vga_arbiter
- crw-rw-rw- 1 root root 10, 126 Sep 26 18:09 vsock
- crw-rw-rw- 1 root root 1, 5 Sep 26 18:09 zero
- -----
- In wrote a little script to check access to /dev entries for root, sudo and non sudo users and ran it on a systemd and sys-v image.
- Access permissions define who is allowed to access what and there are some files on sys-v where root has no write access.
- ===>
- /dev/fd -> /proc/self/fd
- ls /dev/fd
- 0
- 1
- 2
- 3
- Access: (0500/dr-x------) Uid: ( 0/ root) Gid: ( 0/ root) : /proc/self/fd
- /proc/self/fd is readable for monitoring
- /proc/self/fd is readable for root
- /proc/self/fd is NOT writeable for monitoring
- ---> /proc/self/fd is NOT writeable for root <---
- <===
- ===>
- /dev/mtab -> /proc/mounts -> /proc/self/mounts
- cat /dev/mtab
- /dev/root / ext4 rw,relatime 0 0
- devtmpfs /dev devtmpfs rw,relatime,size=109152k,nr_inodes=27288,mode=755 0 0
- proc /proc proc rw,relatime 0 0
- sysfs /sys sysfs rw,relatime 0 0
- none /sys/kernel/debug debugfs rw,relatime 0 0
- tmpfs /run tmpfs rw,nosuid,nodev,mode=755 0 0
- tmpfs /var/volatile tmpfs rw,relatime 0 0
- devpts /dev/pts devpts rw,relatime,gid=5,mode=620,ptmxmode=000 0 0
- Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) : /proc/mounts
- /proc/mounts is readable for monitoring
- /proc/mounts is readable for root
- /proc/mounts is NOT writeable for monitoring
- ---> /proc/mounts is NOT writeable for root <---
- Access: (0444/-r--r--r--) Uid: ( 0/ root) Gid: ( 0/ root) : /proc/self/mounts
- /proc/self/mounts is readable for monitoring
- /proc/self/mounts is readable for root
- /proc/self/mounts is NOT writeable for monitoring
- ---> /proc/self/mounts is NOT writeable for root <---
- <===
- Now here comes the fun!!!
- systemd does not seem to create /dev/mtab and /dev/fd has different permissions:
- systemd:
- Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/fd
- /dev/fd is readable for monitoring
- /dev/fd is readable for nonroot
- /dev/fd is readable for root
- /dev/fd is writeable for monitoring
- /dev/fd is writeable for nonroot
- /dev/fd is writeable for root
- sys-v:
- Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/fd
- /dev/fd is readable for monitoring
- /dev/fd is readable for nonroot
- /dev/fd is readable for root
- /dev/fd is NOT writeable for monitoring
- /dev/fd is NOT writeable for nonroot
- ---> /dev/fd is NOT writeable for root <---
- that's not permissions, since those seems to be the same, but the actual device ;)
- some permissions are slightly different:
- systemd:
- Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/initctl
- sys-v:
- Access: (0600/prw-------) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/initctl
- with the same effect on reading/writing, but one is a symlink and the other a pipe
- systemd:
- Access: (0777/lrwxrwxrwx) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/log
- sys-v:
- Access: (0666/srw-rw-rw-) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/log
- the "setuid" bit, which might have security implications ;)
- systemd:
- Access: (0620/crw--w----) Uid: ( 0/ root) Gid: ( 5/ tty) : /dev/tty1
- sys-v:
- Access: (0620/crw--w----) Uid: ( 0/ root) Gid: ( 0/ root) : /dev/tty1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement