Allow callers of uevent_kernel_*() access to /proc/sys/kernel/overflowuid am: 640e595a68

am: fe5554828e

Change-Id: I475310efa292fd28093c34b231b3d6ff7c406421
This commit is contained in:
Luis Hector Chavez 2017-11-08 01:51:50 +00:00 committed by android-build-merger
commit 4953e49c69
9 changed files with 15 additions and 0 deletions

View file

@ -455,6 +455,7 @@
proc_kmsg proc_kmsg
proc_loadavg proc_loadavg
proc_mounts proc_mounts
proc_overflowuid
proc_page_cluster proc_page_cluster
proc_pagetypeinfo proc_pagetypeinfo
proc_random proc_random

View file

@ -31,6 +31,7 @@ genfscon proc /sys/kernel/hotplug u:object_r:usermodehelper:s0
genfscon proc /sys/kernel/kptr_restrict u:object_r:proc_security:s0 genfscon proc /sys/kernel/kptr_restrict u:object_r:proc_security:s0
genfscon proc /sys/kernel/modprobe u:object_r:usermodehelper:s0 genfscon proc /sys/kernel/modprobe u:object_r:usermodehelper:s0
genfscon proc /sys/kernel/modules_disabled u:object_r:proc_security:s0 genfscon proc /sys/kernel/modules_disabled u:object_r:proc_security:s0
genfscon proc /sys/kernel/overflowuid u:object_r:proc_overflowuid:s0
genfscon proc /sys/kernel/perf_event_max_sample_rate u:object_r:proc_perf:s0 genfscon proc /sys/kernel/perf_event_max_sample_rate u:object_r:proc_perf:s0
genfscon proc /sys/kernel/poweroff_cmd u:object_r:usermodehelper:s0 genfscon proc /sys/kernel/poweroff_cmd u:object_r:usermodehelper:s0
genfscon proc /sys/kernel/random u:object_r:proc_random:s0 genfscon proc /sys/kernel/random u:object_r:proc_random:s0

View file

@ -26,6 +26,7 @@ type proc_misc, fs_type;
type proc_modules, fs_type; type proc_modules, fs_type;
type proc_mounts, fs_type; type proc_mounts, fs_type;
type proc_net, fs_type; type proc_net, fs_type;
type proc_overflowuid, fs_type;
type proc_page_cluster, fs_type; type proc_page_cluster, fs_type;
type proc_pagetypeinfo, fs_type; type proc_pagetypeinfo, fs_type;
type proc_perf, fs_type; type proc_perf, fs_type;

View file

@ -15,4 +15,5 @@ allow hal_usb sysfs:file read;
allow hal_usb sysfs:file open; allow hal_usb sysfs:file open;
allow hal_usb sysfs:file write; allow hal_usb sysfs:file write;
allow hal_usb sysfs:file getattr; allow hal_usb sysfs:file getattr;
allow hal_usb proc_overflowuid:file r_file_perms;

View file

@ -55,6 +55,7 @@ allow healthd tty_device:chr_file rw_file_perms;
allow healthd ashmem_device:chr_file execute; allow healthd ashmem_device:chr_file execute;
allow healthd self:process execmem; allow healthd self:process execmem;
allow healthd proc_sysrq:file rw_file_perms; allow healthd proc_sysrq:file rw_file_perms;
allow healthd proc_overflowuid:file r_file_perms;
add_service(healthd, batteryproperties_service) add_service(healthd, batteryproperties_service)

View file

@ -280,6 +280,9 @@ allow init proc_cmdline:file r_file_perms;
# Write to /proc/sys/vm/page-cluster # Write to /proc/sys/vm/page-cluster
allow init proc_page_cluster:file w_file_perms; allow init proc_page_cluster:file w_file_perms;
# Read /proc/sys/kernel/overflowuid
allow init proc_overflowuid:file r_file_perms;
# Reboot. # Reboot.
allow init self:capability sys_boot; allow init self:capability sys_boot;

View file

@ -37,6 +37,9 @@ r_dir_file(netd, proc_net)
# For /proc/sys/net/ipv[46]/route/flush. # For /proc/sys/net/ipv[46]/route/flush.
allow netd proc_net:file rw_file_perms; allow netd proc_net:file rw_file_perms;
# Access for /proc/sys/kernel/overflowuid.
allow netd proc_overflowuid:file r_file_perms;
# Enables PppController and interface enumeration (among others) # Enables PppController and interface enumeration (among others)
allow netd sysfs:dir r_dir_perms; allow netd sysfs:dir r_dir_perms;
r_dir_file(netd, sysfs_net) r_dir_file(netd, sysfs_net)

View file

@ -36,6 +36,9 @@ allow ueventd file_contexts_file:file r_file_perms;
# Use setfscreatecon() to label /dev directories and files. # Use setfscreatecon() to label /dev directories and files.
allow ueventd self:process setfscreate; allow ueventd self:process setfscreate;
# Access for /proc/sys/kernel/overflowuid.
allow ueventd proc_overflowuid:file r_file_perms;
##### #####
##### neverallow rules ##### neverallow rules
##### #####

View file

@ -24,6 +24,7 @@ allow vold {
proc_filesystems proc_filesystems
proc_meminfo proc_meminfo
proc_mounts proc_mounts
proc_overflowuid
}:file r_file_perms; }:file r_file_perms;
#Get file contexts #Get file contexts