Skip to content
Snippets Groups Projects
  1. Oct 15, 2014
    • Robin Lee's avatar
      Pull keychain-data policy out of system-data · 51bfecf4
      Robin Lee authored
      Migrators should be allowed to write to /data/misc/keychain in order
      to remove it. Similarly /data/misc/user should be writable by system
      apps.
      
      TODO: Revoke zygote's rights to read from /data/misc/keychain on
      behalf of some preloaded security classes.
      
      Bug: 17811821
      Change-Id: I9e9c6883cff1dca3755732225404909c16a0e547
      51bfecf4
  2. Oct 10, 2014
  3. Sep 08, 2014
    • dcashman's avatar
      Add support for factory reset protection. · 47bd7300
      dcashman authored
      Address the following denials:
      <12>[  417.732129] type=1400 audit(365340.189:47): avc: denied { read } for pid=1737 comm="Binder_2" name="mmcblk0p18" dev="tmpfs" ino=12406 scontext=u:r:system_server:s0 tcontext=u:object_r:block_device:s0 tclass=blk_file permissive=0
      <12>[  417.882126] type=1400 audit(365340.339:48): avc: denied { read } for pid=1737 comm="Binder_2" name="mmcblk0p18" dev="tmpfs" ino=12406 scontext=u:r:system_server:s0 tcontext=u:object_r:block_device:s0 tclass=blk_file permissive=0
      
      Bug: 16710840
      Change-Id: I8cb5b4b17dffe14f0bf05d63eb8f6ab8d5c09f53
      47bd7300
  4. Aug 29, 2014
  5. Jul 28, 2014
  6. Jul 25, 2014
    • Narayan Kamath's avatar
      Revert "fix system_server dex2oat exec" · aa8e657e
      Narayan Kamath authored
      This reverts commit 10370f5f.
      
      The underlying issue has been fixed and the system_server
      will now go via installd to get stuff compiled, if required.
      
      bug: 16317188
      
      Change-Id: I77a07748a39341f7082fb9fc9792c4139c90516d
      aa8e657e
  7. Jul 18, 2014
  8. Jul 16, 2014
    • Riley Spahn's avatar
      Remove auditallow from system_server. · d2635764
      Riley Spahn authored
      system_server auditallow statements were causing logspam and
      there is not a good way to negate services from specific devices
      so as a fix we are removing all system_server auditallows. These
      logs may not be useful anyway because I suspsect that system_server
      will probe for most all services anyway.
      
      (cherry picked from commit 5a25fbf7)
      
      Change-Id: Ibadf1ce5e66f279fc49fd8fa20dfc64c960dd57f
      d2635764
  9. Jul 15, 2014
    • Riley Spahn's avatar
      Add access control for each service_manager action. · 344fc109
      Riley Spahn authored
      Add SELinux MAC for the service manager actions list
      and find. Add the list and find verbs to the
      service_manager class. Add policy requirements for
      service_manager to enforce policies to binder_use
      macro.
      
      (cherry picked from commit b8511e0d)
      
      Change-Id: I980d4a8acf6a0c6e99a3a7905961eb5564b1be15
      344fc109
    • Nick Kralevich's avatar
      fix system_server dex2oat exec · 10370f5f
      Nick Kralevich authored
      Addresses the following denial:
      
        W/system_server( 2697): type=1400 audit(0.0:9): avc: denied { execute } for name="dex2oat" dev="mmcblk0p31" ino=118 scontext=u:r:system_server:s0 tcontext=u:object_r:dex2oat_exec:s0 tclass=file permissive=0
      
      Bug: 16317188
      Change-Id: I168842b3e281efcb0632049632ed3817c2025e4d
      10370f5f
    • Ed Heyl's avatar
      reconcile aosp (3a8c5dc0) after branching. Please do not merge. · 81839dfb
      Ed Heyl authored
      Change-Id: Ic8ee83ed6ffef02bddd17e1175416fc2481db7b2
      81839dfb
  10. Jul 10, 2014
  11. Jul 09, 2014
  12. Jul 08, 2014
    • Jeff Sharkey's avatar
      Rules to allow installing package directories. · c02c98d3
      Jeff Sharkey authored
      Earlier changes had extended the rules, but some additional changes
      are needed.
      
      avc: denied { relabelfrom } for name="vmdl-723825123.tmp"
          dev="mmcblk0p28" ino=162910 scontext=u:r:system_server:s0
          tcontext=u:object_r:apk_data_file:s0 tclass=dir
      
      Bug: 14975160
      Change-Id: Ia644c73ec10460a2a529fe197ade6afe46694651
      c02c98d3
  13. Jul 07, 2014
    • Jeff Sharkey's avatar
      Rules to allow installing package directories. · be092af0
      Jeff Sharkey authored
      Earlier changes had extended the rules, but some additional changes
      are needed.
      
      avc: denied { relabelfrom } for name="vmdl-723825123.tmp"
          dev="mmcblk0p28" ino=162910 scontext=u:r:system_server:s0
          tcontext=u:object_r:apk_data_file:s0 tclass=dir
      
      Bug: 14975160
      Change-Id: I875cfc3538d4b098d27c7c7b756d1868a54cc976
      be092af0
  14. Jul 04, 2014
    • Nick Kralevich's avatar
      system_server: bring back sdcard_type neverallow rule · d00eff47
      Nick Kralevich authored
      We had disabled the neverallow rule when system_server was
      in permissive_or_unconfined(), but forgot to reenable it.
      Now that system_server is in enforcing/confined, bring it
      back.
      
      Change-Id: I6f74793d4889e3da783361c4d488b25f804ac8ba
      d00eff47
  15. Jul 01, 2014
  16. Jun 26, 2014
    • Riley Spahn's avatar
      Adding policies for KeyStore MAC. · 1196d2a5
      Riley Spahn authored
      Add keystore_key class and an action for each action supported
      by keystore. Add policies that replicate the access control that
      already exists in keystore. Add auditallow rules for actions
      not known to be used frequently. Add macro for those domains
      wishing to access keystore.
      
      Change-Id: Iddd8672b9e9b72b45ee208e6eda608cc9dc61edc
      1196d2a5
  17. Jun 25, 2014
    • Nick Kralevich's avatar
      Allow system_server to read all /proc files · 8c6552ac
      Nick Kralevich authored
      system_server scans through /proc to keep track of process
      memory and CPU usage. It needs to do this for all processes,
      not just appdomain processes, to properly account for CPU and
      memory usage.
      
      Allow it.
      
      Addresses the following errors which have been showing up
      in logcat:
      
        W/ProcessCpuTracker(12159): Skipping unknown process pid 1
        W/ProcessCpuTracker(12159): Skipping unknown process pid 2
        W/ProcessCpuTracker(12159): Skipping unknown process pid 3
      
      Bug: 15862412
      Change-Id: I0a75314824404e060c6914c06a371f2ff2e80512
      8c6552ac
  18. Jun 23, 2014
    • Stephen Smalley's avatar
      Align SELinux property policy with init property_perms. · fee49159
      Stephen Smalley authored
      
      Introduce a net_radio_prop type for net. properties that can be
      set by radio or system.
      Introduce a system_radio_prop type for sys. properties that can be
      set by radio or system.
      Introduce a dhcp_prop type for properties that can be set by dhcp or system.
      Drop the rild_prop vs radio_prop distinction; this was an early
      experiment to see if we could separate properties settable by rild
      versus other radio UID processes but it did not pan out.
      
      Remove the ability to set properties from unconfineddomain.
      Allow init to set any property.  Allow recovery to set ctl_default_prop
      to restart adbd.
      
      Change-Id: I5ccafcb31ec4004dfefcec8718907f6b6f3e0dfd
      Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
      fee49159
  19. Jun 19, 2014
    • Paul Jensen's avatar
      Allow Bluetooth app to initiate DHCP service on bt-pan interface. · 97a2cfdf
      Paul Jensen authored
      bug:15407087
      Change-Id: I3dea9c1110583f11f093d048455a1cc739d05658
      97a2cfdf
    • Nick Kralevich's avatar
      system_server: allow open /dev/snd and read files · 04e730b6
      Nick Kralevich authored
      system_server needs to open /dev/snd and access files
      within that directory. Allow it.
      
      system_server need to parse the ALSA card descriptors after a USB device
      has been inserted. This happens from USBService in system_server.
      
      Addresses the following denial:
      
        system_server( 1118): type=1400 audit(0.0:19): avc: denied { search } for comm=5573625365727669636520686F7374 name="snd" dev="tmpfs" ino=8574 scontext=u:r:system_server:s0 tcontext=u:object_r:audio_device:s0 tclass=dir
      
      and likely others
      
      Change-Id: Id274d3feb7bf337f492932e5e664d65d0b8d05b8
      04e730b6
  20. Jun 17, 2014
    • Stephen Smalley's avatar
      Eliminate some duplicated rules. · 00b180df
      Stephen Smalley authored
      
      As reported by sepolicy-analyze -D -P /path/to/sepolicy.
      No semantic difference reported by sediff between the policy
      before and after this change.
      
      Deduplication of selinuxfs read access resolved by taking the
      common rules to domain.te (and thereby getting rid of the
      selinux_getenforce macro altogether).
      
      Change-Id: I4de2f86fe2efe11a167e8a7d25dd799cefe482e5
      Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
      00b180df
  21. Jun 16, 2014
    • Nick Kralevich's avatar
      Fix SELinux policies to allow resource overlays. · fad4d5fb
      Nick Kralevich authored
      The following commits added support for runtime resource overlays.
      
        New command line tool 'idmap'
        * 65a05fd56dbc9fd9c2511a97f49c445a748fb3c5
        Runtime resource overlay, iteration 2
        * 48d22323ce39f9aab003dce74456889b6414af55
        Runtime resource overlay, iteration 2, test cases
        * ad6ed950dbfa152c193dd7e49c369d9e831f1591
      
      During SELinux tightening, support for these runtime resource
      overlays was unknowingly broken. Fix it.
      
      This change has been tested by hackbod and she reports that
      everything is working after this change. I haven't independently
      verified the functionality.
      
      Test cases are available for this by running:
        * python frameworks/base/core/tests/overlaytests/testrunner.py
      
      Change-Id: I1c70484011fd9041bec4ef34f93f7a5509906f40
      fad4d5fb
  22. Jun 14, 2014
    • Nick Kralevich's avatar
      system_server profile access · a76d9ddf
      Nick Kralevich authored
      Still not fixed. *sigh*
      
      Addresses the following denial:
      
      <4>[   40.515398] type=1400 audit(15842931.469:9): avc: denied { read } for pid=814 comm="system_server" name="profiles" dev="mmcblk0p28" ino=105874 scontext=u:r:system_server:s0 tcontext=u:object_r:dalvikcache_profiles_data_file:s0 tclass=dir
      
      Change-Id: I705a4cc9c508200ace46780c18b7112b62f27994
      a76d9ddf
  23. Jun 13, 2014
    • Nick Kralevich's avatar
      allow system_server getattr on /data/dalvik-cache/profiles · 96d9af42
      Nick Kralevich authored
      86703051 wasn't complete. I thought
      getattr on the directory wasn't needed but I was wrong. Not sure
      how I missed this.
      
      Addresses the following denial:
      
        <4>[   40.699344] type=1400 audit(15795140.469:9): avc: denied { getattr } for pid=1087 comm="system_server" path="/data/dalvik-cache/profiles" dev="mmcblk0p28" ino=105874 scontext=u:r:system_server:s0 tcontext=u:object_r:dalvikcache_profiles_data_file:s0 tclass=dir
      
      Change-Id: Ibc176b2b00083bafaa91ab78d0f8dc1ca3c208b6
      96d9af42
  24. Jun 12, 2014
    • Nick Kralevich's avatar
      Remove world-read access to /data/dalvik-cache/profiles · 86703051
      Nick Kralevich authored
      Remove /data/dalvik-cache/profiles from domain. Profiling information
      leaks data about how people interact with apps, so we don't want
      the data to be available in all SELinux domains.
      
      Add read/write capabilities back to app domains, since apps need to
      read/write profiling data.
      
      Remove restorecon specific rules. The directory is now created by
      init, not installd, so installd doesn't need to set the label.
      
      Change-Id: Ic1b44009faa30d704855e97631006c4b990a4ad3
      86703051
    • Riley Spahn's avatar
      Add SELinux rules for service_manager. · f90c41f6
      Riley Spahn authored
      Add a service_mananger class with the verb add.
      Add a type that groups the services for each of the
      processes that is allowed to start services in service.te
      and an attribute for all services controlled by the service
      manager. Add the service_contexts file which maps service
      name to target label.
      
      Bug: 12909011
      Change-Id: I017032a50bc90c57b536e80b972118016d340c7d
      f90c41f6
  25. Jun 11, 2014
    • Ruchi Kandoi's avatar
      DO NOT MERGE adds system_server permissions · 28ca3327
      Ruchi Kandoi authored
      
      Adds permission to system_server to write sysfs file
      
      Need this for changing the max_cpufreq and min_cpufreq for the low power
      mode.
      
      Denials:
      type=1400 audit(1402431554.756:14): avc: denied { write } for pid=854
      comm="PowerManagerSer" name="scaling_max_freq" dev="sysfs" ino=9175
      scontext=u:r:system_server:s0 tcontext=u:object_r:sysfs_devices_system_cpu:s0
      tclass=file
      
      Change required for Change-Id: I1cf458c4f128818ad1286e5a90b0d359b6913bb8
      
      Change-Id: Ic5ce3c8327e973bfa1d53f298c07dcea1550b646
      Signed-off-by: default avatarRuchi <Kandoi&lt;kandoiruchi@google.com>
      28ca3327
  26. Jun 10, 2014
    • Ruchi Kandoi's avatar
      system_server: Adds permission to system_server to write sysfs file · 13d58863
      Ruchi Kandoi authored
      
      Need this for changing the max_cpufreq and min_cpufreq for the low power
      mode.
      
      Denials:
      type=1400 audit(1402431554.756:14): avc: denied { write } for pid=854
      comm="PowerManagerSer" name="scaling_max_freq" dev="sysfs" ino=9175
      scontext=u:r:system_server:s0 tcontext=u:object_r:sysfs_devices_system_cpu:s0
      tclass=file
      
      Change required for Change-Id: I1cf458c4f128818ad1286e5a90b0d359b6913bb8
      
      Change-Id: Ic5ce3c8327e973bfa1d53f298c07dcea1550b646
      Signed-off-by: default avatarRuchi <Kandoi&lt;kandoiruchi@google.com>
      13d58863
  27. Jun 09, 2014
  28. Jun 04, 2014
    • Stephen Smalley's avatar
      Allow system_server access to /data/media files passed via Binder. · 2cc6d63d
      Stephen Smalley authored
      
      Addresses denials such as:
       avc: denied { read } for comm="Binder_6" path="/data/media/0/zedge/ringtone/love_tone_2014-ringtone-1665292.mp3" dev="mmcblk0p28" ino=1534267 scontext=u:r:system_server:s0 tcontext=u:object_r:media_rw_data_file:s0 tclass=file
       avc: denied { getattr } for comm="Binder_9" path="/data/media/0/zedge/ringtone/love_tone_2014-ringtone-1665292.mp3" dev="mmcblk0p28" ino=1534267 scontext=u:r:system_server:s0 tcontext=u:object_r:media_rw_data_file:s0 tclass=file
      
      Change-Id: I5e5744eecf2cbd4fc584db8584be4e9101bcb60c
      Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
      2cc6d63d
  29. May 29, 2014
  30. May 23, 2014
    • Nick Kralevich's avatar
      Introduce wakelock_use() · 8599e34b
      Nick Kralevich authored
      Introduce wakelock_use(). This macro declares that a domain uses
      wakelocks.
      
      Wakelocks require both read-write access to files in /sys/power, and
      CAP_BLOCK_SUSPEND. This macro helps ensure that both capabilities and
      file access are granted at the same time.
      
      Still TODO: fix device specific wakelock use.
      
      Change-Id: Ib98ff374a73f89e403acd9f5e024988f59f08115
      8599e34b
  31. May 14, 2014
    • Stephen Smalley's avatar
      Remove graphics_device access. · a16a59e2
      Stephen Smalley authored
      
      Neither mediaserver nor system_server appear to require
      direct access to graphics_device, i.e. the framebuffer
      device.  Drop it.
      
      Change-Id: Ie9d1be3f9071584155cddf248ea85e174b7e50a6
      Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
      a16a59e2
    • Stephen Smalley's avatar
      Allow system_server to read tombstones. · 782e084d
      Stephen Smalley authored
      
      Address denials such as:
       avc:  denied  { read } for  name="tombstones" dev="dm-0" ino=765537 scontext=u:r:system_server:s0 tcontext=u:object_r:tombstone_data_file:s0 tclass=dir
       avc:  denied  { open } for  name="tombstones" dev="dm-0" ino=765537 scontext=u:r:system_server:s0 tcontext=u:object_r:tombstone_data_file:s0 tclass=dir
       avc:  denied  { getattr } for  path="/data/tombstones/tombstone_00" dev="dm-0" ino=765538 scontext=u:r:system_server:s0 tcontext=u:object_r:tombstone_data_file:s0 tclass=file
       avc:  denied  { read } for  name="tombstone_00" dev="dm-0" ino=765538 scontext=u:r:system_server:s0 tcontext=u:object_r:tombstone_data_file:s0 tclass=file
       avc:  denied  { open } for  name="tombstone_00" dev="dm-0" ino=765538 scontext=u:r:system_server:s0 tcontext=u:object_r:tombstone_data_file:s0 tclass=file
      
      Change-Id: Iae5a10bed9483589660b84a88b6b9f8f8e9a8f5c
      Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
      782e084d
  32. May 13, 2014
Loading