Skip to content
Snippets Groups Projects
  1. Mar 29, 2018
    • Jeff Vander Stoep's avatar
      Improve neverallows on /proc and /sys · 3079d01a
      Jeff Vander Stoep authored
      Access to these files was removed in Oreo. Enforce that access is not
      granted by partners via neverallow rule.
      
      Also disallow most untrusted app access to net.dns.* properties.
      
      Bug: 77225170
      Test: system/sepolicy/tools/build_policies.sh
      Change-Id: I85b634af509203393dd2d9311ab5d30c65f157c1
      (cherry picked from commit 886aa54b)
      3079d01a
    • Alan Stokes's avatar
      Suppress harmless denials for file creation in cgroupfs. · 92c149d0
      Alan Stokes authored
      The kernel generates file creation audits when O_CREAT is passed even
      if the file already exists - which it always does in the cgroup cases.
      
      We add neverallow rules to prevent mistakenly allowing unnecessary
      create access. We also suppress these denials, which just add noise to
      the log, for the more common culprits.
      
      Bug: 72643420
      Bug: 74182216
      
      Test: Ran build_policies.sh and checked failures were unrelated.
      Test: Device still boots, denials gone.
      Change-Id: I034b41ca70da1e73b81fe90090e656f4a3b542dc
      92c149d0
  2. Mar 28, 2018
    • Joel Galenson's avatar
      Hide some denials. · a66d1a45
      Joel Galenson authored
      These denials occur fairly often, causing some logspam.
      
      Bug: 77225170
      Test: Boot device.
      Change-Id: Icd73a992aee44007d0873743f706758f9a19a112
      a66d1a45
    • Jaekyun Seok's avatar
      Allow vendor-init-settable to persist.radio.multisim.config · 7d3bd8db
      Jaekyun Seok authored
      A default value of persist.radio.multisim.config can be set by SoC
      vendors, and so vendor-init-settable should be allowed to it.
      
      Bug: 73871799
      Test: succeeded building and tested with taimen
      Change-Id: Ie62b91e7e3d7e05425b742838417f1cab7b3fed4
      Merged-In: Ie62b91e7e3d7e05425b742838417f1cab7b3fed4
      (cherry picked from commit ac8c6e3d)
      7d3bd8db
    • Andreas Gampe's avatar
      Statsd: Allow statsd to contact perfprofd in userdebug · 2767f9d3
      Andreas Gampe authored
      Give statsd rights to connect to perfprofd in userdebug.
      
      (cherry picked from commit 488030ee)
      
      Bug: 73175642
      Test: mmma system/extras/perfprofd
      Merged-In: Idea0a6b757d1b16ec2e6c8719e24900f1e5518fd
      Change-Id: Idea0a6b757d1b16ec2e6c8719e24900f1e5518fd
      2767f9d3
  3. Mar 26, 2018
    • Jeff Vander Stoep's avatar
      crashdump: cleanup logs · cc0304cf
      Jeff Vander Stoep authored
      Suppress WAI denials from crashdump.
      
      Test: build/flash Taimen. Verify no new denials.
      Bug: 68319037
      Change-Id: If39d057cb020def7afe89fd95e049e45cce2ae16
      cc0304cf
    • Primiano Tucci's avatar
      perfetto: allow traced to write into FDs received by the client · e9b8bff6
      Primiano Tucci authored
      This allows an optimization that consists in the "perfetto" cmdline
      client passing directly the file descriptor for the output trace
      to traced (as opposite to having traced streaming back the trace
      data to "perfetto" and having that one doing the write() into file).
      This reduces sensibly the memory traffic and CPU overhead of traces
      with a minor change.
      
      Bug: 73625179
      Test: builds + perfetto_integrationtests w/ long_trace.cfg
      Change-Id: I81f5a230338ced20dc543fd91c5a0bd0e58725f2
      Merged-In: I81f5a230338ced20dc543fd91c5a0bd0e58725f2
      (cherry picked from aosp/648831)
      e9b8bff6
  4. Mar 24, 2018
    • Chenbo Feng's avatar
      Allow system server to access bpf fs · 88ef20aa
      Chenbo Feng authored
      The permission to allow system_server to access sys/fs/bpf/ directory
      is missing. Add it back so it can get the bpf maps from the bpf_fs.
      
      Test: device boot and no more denial information of system_server try to
      searcg in fs_bpf
            atest android.net.cts.TrafficStatsTest
      Bug: 75285088
      
      Change-Id: I1040cde6c038eccc4e91c69a10b20aa7a18b19f6
      (cherry picked from aosp commit f83bbd17)
      88ef20aa
  5. Mar 23, 2018
  6. Mar 22, 2018
    • Mikhail Naganov's avatar
      Allow system_server to update timerslack_ns for hal_audio_default · b506a352
      Mikhail Naganov authored
      Based on the following audit message:
      
      type=1400 audit(1521738979.005:385): avc: denied { write } for pid=1269
      comm="Binder:1269_B" name="timerslack_ns" dev="proc" ino=254190
      scontext=u:r:system_server:s0 tcontext=u:r:hal_audio_default:s0
      tclass=file permissive=1
      
      Bug: 74110604
      Test: adb shell dmesg | grep hal_audio_default
      Change-Id: I4c2e787588eb9d223d5e50e1bc8f67876de97c2e
      b506a352
    • Primiano Tucci's avatar
      Reland: perfetto: allow traced_probes to execute atrace · f3fd4d6b
      Primiano Tucci authored
      This CL adds the SELinux permissions required to execute
      atrace and get userspace tracing events from system services.
      This is to enable tracing of events coming from surfaceflinger,
      audio HAL, etc.
      atrace, when executed, sets a bunch of debug.atrace. properties
      and sends an IPC via binder/hwbinder to tell the services to
      reload that property.
      
      This CL does NOT affect systrace. In that case (i.e. when
      atrace is executed from adb/shell) atrace still runs in
      the shell domain and none of those changes apply.
      
      Change-Id: I11b096d5c5c5593f18bce87f06c1a7b1ffa7910e
      Merged-In: I11b096d5c5c5593f18bce87f06c1a7b1ffa7910e
      Merged-In: Iba195d571aec9579195d79d4970f760e417608c6
      Bug: b/73340039
      f3fd4d6b
  7. Mar 21, 2018
    • Chenbo Feng's avatar
      Allow netd to setup xt_bpf iptable rules · 68ef8c07
      Chenbo Feng authored
      To better record the network traffic stats for each network interface.
      We use xt_bpf netfilter module to do the iface stats accounting instead
      of the cgroup bpf filter we currently use for per uid stats accounting.
      The xt_bpf module will take pinned eBPF program as iptables rule and run
      the program when packet pass through the netfilter hook. To setup the
      iptables rules. netd need to be able to access bpf filesystem and run the
      bpf program at boot time. The program used will still be created and
      pinned by the bpfloader process.
      
      Test: With selinux enforced, run "iptables -L -t raw" should show the
      xt_bpf related rule present in bw_raw_PREROUTING chain.
      Bug: 72111305
      
      Change-Id: I11efe158d6bd5499df6adf15e8123a76cd67de04
      (cherry picked from aosp commit 5c95c168)
      68ef8c07
    • Fyodor Kupolov's avatar
      Added SELinux policy for BinderCallsStatsService · 624dc30d
      Fyodor Kupolov authored
      Test: manual
      Bug: 75318418
      Merged-In: I700c1b8b613dba1c99f4fbffdd905c0052c1b2e7
      Change-Id: I700c1b8b613dba1c99f4fbffdd905c0052c1b2e7
      624dc30d
  8. Mar 20, 2018
    • Tri Vo's avatar
      proc_type attribute for files under /proc. · 62e6850a
      Tri Vo authored
      With this attribute it will be easier to reference /proc files.
      
      Bug: 74182216
      Test: policy builds
      Change-Id: I5b7da508d821e45f122832261a742a201e8fdf2c
      (cherry picked from commit 41bf08e5)
      62e6850a
    • Joel Galenson's avatar
      Allow audioserver to access audio_device on non-Treble devices. · b54d87f8
      Joel Galenson authored
      This should fix audio on non-Treble devices.
      
      Bug: 75949883
      Test: Built policy.
      Merged-In: I90a4648aaf975d59be36afd5f62c88a015af10f7
      Change-Id: I90a4648aaf975d59be36afd5f62c88a015af10f7
      (cherry picked from commit 6e8bfa2d)
      b54d87f8
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_mac_permissions.xml · 1067bffa
      Bowgo Tsai authored
      Bug: 64240127
      Test: normal boot a device
      Change-Id: I276ba6bc88eabb0d5562e4e96d3860eedb76aed5
      Merged-In: I276ba6bc88eabb0d5562e4e96d3860eedb76aed5
      (cherry picked from commit af7d85f8)
      1067bffa
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_hwservice_contexts · 13e5d757
      Bowgo Tsai authored
      Bug: 64240127
      Test: normal boot and recovery boot a device
      Change-Id: I22d29e8476380d19aca1be359e0228ab6bbc3b0f
      Merged-In: I22d29e8476380d19aca1be359e0228ab6bbc3b0f
      (cherry picked from commit ad6231f5)
      13e5d757
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_property_contexts · 6d3822d4
      Bowgo Tsai authored
      Bug: 64240127
      Test: normal boot and recovery boot a device
      Change-Id: Ibd71219f60644e57370c0293decf11d82f1cb35c
      Merged-In: Ibd71219f60644e57370c0293decf11d82f1cb35c
      (cherry picked from commit 1f717b10)
      6d3822d4
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_seapp_contexts · 82444056
      Bowgo Tsai authored
      Bug: 64240127
      Test: normal boot a device
      Change-Id: I3626357237cc18a99511f1ebd9dd3ff5a7655963
      Merged-In: I3626357237cc18a99511f1ebd9dd3ff5a7655963
      (cherry picked from commit ecf656b0)
      82444056
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_file_contexts · d3e94f26
      Bowgo Tsai authored
      Bug: 64240127
      Test: normal boot and recovery boot a device
      Change-Id: I087292fb23d05fc17272778d668ac78a721b2593
      Merged-In: I087292fb23d05fc17272778d668ac78a721b2593
      (cherry picked from commit bae1517a)
      d3e94f26
    • Bowgo Tsai's avatar
      Add /odm/etc/selinux/odm_sepolicy.cil · 95fbf451
      Bowgo Tsai authored
      This change adds the support of odm sepolicy customization, which can
      be configured through the newly added build varaible:
          - BOARD_ODM_SEPOLICY_DIRS += device/${ODM_NAME}/${BOM_NAME}/sepolicy
      
      Also moving precompiled sepolicy to /odm when BOARD_ODM_SEPOLICY_DIRS
      is set. On a DUT, precompiled sepolicy on /odm will override the one in
      /vendor. This is intentional because /odm is the hardware customization
      for /vendor and both should be updated together if desired.
      
      Bug: 64240127
      Test: boot a device with /odm partition
      Change-Id: Ia8f81a78c88cbfefb3ff19e2ccd2648da6284d09
      Merged-In: Ia8f81a78c88cbfefb3ff19e2ccd2648da6284d09
      (cherry picked from commit 45457e3a)
      95fbf451
  9. Mar 19, 2018
    • Chong Zhang's avatar
      allow mediaprovider to use media extractor · 9161b992
      Chong Zhang authored
      When extraction exif info, certain file formats may requires
      parsing the container. Allow mediaprovider to use extractor
      to do the parsing.
      
      bug: 73978990
      Test: manually test the scenario in b/73978990 and verify
            the Exif is extracted correctly.
      
      Change-Id: I1cd46d793ebc9c38b816a3b63f361967e551d046
      (cherry picked from commit 8e3fef3d)
      9161b992
  10. Mar 18, 2018
  11. Mar 12, 2018
  12. Mar 11, 2018
  13. Mar 08, 2018
    • Amit Mahajan's avatar
      Move rild from public to vendor. · eeda6c61
      Amit Mahajan authored
      Also change the neverallow exceptions to be for hal_telephony_server
      instead of rild.
      
      Test: Basic telephony sanity, treehugger
      Bug: 36427227
      Change-Id: If892b28416d98ca1f9c241c5fcec70fbae35c82e
      eeda6c61
    • Joel Galenson's avatar
      Ensure taking a bugreport generates no denials. · ba0c279d
      Joel Galenson authored
      This commit adds new SELinux permissions and neverallow rules so that
      taking a bugreport does not produce any denials.
      
      Bug: 73256908
      Test: Captured bugreports on Sailfish and Walleye and verified
      that there were no denials.
      
      Merged-In: If3f2093a2b51934938e3d7e5c42036b2e2bf6de9
      Change-Id: If3f2093a2b51934938e3d7e5c42036b2e2bf6de9
      (cherry picked from commit daf1cdfa)
      ba0c279d
    • Jiyong Park's avatar
      /odm is another vendor partition other than /vendor · e64edff1
      Jiyong Park authored
      Sub directories under /odm (or /vendor/odm when there isn't an odm
      partition) are labeled so that artifacts under the sub directories are
      treated the same as their counterpart in the vendor partition.
      
      For example, /odm/app/* is labeled as vendor_app_file just like
      /vendor/app/*.
      
      Bug: 71366495
      Test: m -j
      
      Merged-In: I72a14fd55672cd2867edd88ced9828ea49726694
      Change-Id: I72a14fd55672cd2867edd88ced9828ea49726694
      (cherry picked from commit 2f101551)
      e64edff1
  14. Mar 07, 2018
    • Ruchi Kandoi's avatar
      Add secure_element_device · e0e2342e
      Ruchi Kandoi authored
      Test: eSE initializes at boot
      Bug: 64881253
      Change-Id: Ib2388b7368c790c402c000adddf1488bee492cce
      (cherry picked from commit ea3cf000)
      e0e2342e
    • Kweku Adams's avatar
      Enabling incidentd to get top and ps data. · bcf8b115
      Kweku Adams authored
      Bug: 72177715
      Bug: 72384374
      Test: flash device and make sure incidentd is getting data without SELinux denials
      Change-Id: I684fe014e19c936017a466ec2d6cd2e1f03022c0
      (cherry picked from commit 06ac7dba)
      bcf8b115
    • Joel Galenson's avatar
      Clean up bug_map. · f3f93eaf
      Joel Galenson authored
      Remove a fixed bug from bug_map.
      
      Bug: 62140539
      Test: Built policy.
      Change-Id: I2ce9e48de92975b6e37ca4a3a4c53f9478b006ef
      f3f93eaf
    • Joel Galenson's avatar
      Track platform_app SELinux denial. · 2995e996
      Joel Galenson authored
      This should fix presubmit tests.
      
      Bug: 74331887
      Test: Built policy.
      Change-Id: Ie9ef75a7f9eaebf1103e3d2f3b4521e9abaf2fe7
      2995e996
    • Chenbo Feng's avatar
      Fix sepolicy for bpf object · 6cd70c2f
      Chenbo Feng authored
      With the new patches backported to 4.9 kernels, the bpf file system now
      take the same file open flag as bpf_obj_get. So system server now need
      read permission only for both bpf map and fs_bpf since we do not need
      system server to edit the map. Also, the netd will always pass stdin
      stdout fd to the process forked by it and do allow it will cause the
      fork and execev fail. We just allow it pass the fd to bpfloader for now
      until we have a better option.
      
      Test: bpfloader start successful on devices with 4.9 kernel.
            run cts -m CtsNetTestCases -t android.net.cts.TrafficStatsTest
      Bug: 74096311
      Bug: 30950746
      
      Change-Id: I747a51cb05ae495c155e7625a3021fc77f921e0d
      6cd70c2f
  15. Mar 01, 2018
    • Jerry Zhang's avatar
      Add functionfs access to system_server. · 1d401545
      Jerry Zhang authored
      UsbDeviceManager in system_server now
      helps set up the endpoint files.
      
      Bug: 72877174
      Test: No selinux denials
      Change-Id: I96b11ee68799ac29b756d2034e7f5e4660dbed98
      1d401545
  16. Feb 28, 2018
    • Jeff Vander Stoep's avatar
      system_server: grant read access to vendor/framework · 9e33565c
      Jeff Vander Stoep authored
      avc: denied { getattr } for path="/vendor/framework"
      scontext=u:r:system_server:s0 tcontext=u:object_r:vendor_framework_file:s0
      tclass=dir
      
      Bug: 68826235
      Test: boot Taimen, verify denials no longer occur.
      Change-Id: Id4b311fd423342c8d6399c3b724417aff9d1cd88
      9e33565c
    • Ajay Panicker's avatar
      Allow audioserver to access Bluetooth Properties · e32d9406
      Ajay Panicker authored
      Now that Bluetooth supports delay reporting, audioserver needs
      access to Bluetooth Properties in order to determine whether the
      feature is enabled or disabled.
      
      Bug: 32755225
      Test: Enable the property and see that there was no error accessing it
      Change-Id: I519d49deb2df4efb3cc2cce9c6d497db18b50c13
      e32d9406
  17. Feb 27, 2018
    • Joel Galenson's avatar
      Clean up bug_map. · 40c112c8
      Joel Galenson authored
      Remove a fixed bug from bug_map.
      
      Bug: 73068008
      Test: Built policy.
      Change-Id: Id0072788953cb6b939a11caace0158da7799f540
      40c112c8
    • Tej Singh's avatar
      Statsd sepolicy for thermal hal · c26ac738
      Tej Singh authored
      Updates statsd sepolicy so it can use the thermal hal.
      
      Test: verified these policies solved sepolicy issues with thermal hal.
      Change-Id: I36839a72494b084d5742c4d83c3ce9814102b974
      c26ac738
Loading