Loading logcat/logcat.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ class Logcat { #endif static int openLogFile(const char* pathname, size_t sizeKB) { int fd = open(pathname, O_WRONLY | O_APPEND | O_CREAT | O_CLOEXEC, S_IRUSR | S_IWUSR); int fd = open(pathname, O_WRONLY | O_APPEND | O_CREAT | O_CLOEXEC, S_IRUSR | S_IWUSR | S_IRGRP); if (fd < 0) { return fd; } Loading logcat/logcatd +4 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,10 @@ # first reads the 'last' logcat to persistent storage with `-L` then run logcat again without # `-L` to read the current logcat buffers to persistent storage. # init sets the umask to 077 for forked processes. logpersist needs to create files that are group # readable. So relax the umask to only disallow group wx and world rwx. umask 037 has_last="false" for arg in "$@"; do if [ "$arg" == "-L" -o "$arg" == "--last" ]; then Loading logcat/logcatd.rc +2 −2 Original line number Diff line number Diff line Loading @@ -30,8 +30,8 @@ on load_persist_props_action setprop logd.logpersistd.enable true on property:logd.logpersistd.enable=true && property:logd.logpersistd=logcatd # all exec/services are called with umask(077), so no gain beyond 0700 mkdir /data/misc/logd 0700 logd log # log group should be able to read persisted logs mkdir /data/misc/logd 0750 logd log start logcatd # stop logcatd service and clear data Loading logd/logtagd.rc +1 −1 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ # logtagd event log tag service (debug only) # on post-fs-data mkdir /data/misc/logd 0700 logd log mkdir /data/misc/logd 0750 logd log write /data/misc/logd/event-log-tags "" chown logd log /data/misc/logd/event-log-tags chmod 0600 /data/misc/logd/event-log-tags Loading Loading
logcat/logcat.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -110,7 +110,7 @@ class Logcat { #endif static int openLogFile(const char* pathname, size_t sizeKB) { int fd = open(pathname, O_WRONLY | O_APPEND | O_CREAT | O_CLOEXEC, S_IRUSR | S_IWUSR); int fd = open(pathname, O_WRONLY | O_APPEND | O_CREAT | O_CLOEXEC, S_IRUSR | S_IWUSR | S_IRGRP); if (fd < 0) { return fd; } Loading
logcat/logcatd +4 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,10 @@ # first reads the 'last' logcat to persistent storage with `-L` then run logcat again without # `-L` to read the current logcat buffers to persistent storage. # init sets the umask to 077 for forked processes. logpersist needs to create files that are group # readable. So relax the umask to only disallow group wx and world rwx. umask 037 has_last="false" for arg in "$@"; do if [ "$arg" == "-L" -o "$arg" == "--last" ]; then Loading
logcat/logcatd.rc +2 −2 Original line number Diff line number Diff line Loading @@ -30,8 +30,8 @@ on load_persist_props_action setprop logd.logpersistd.enable true on property:logd.logpersistd.enable=true && property:logd.logpersistd=logcatd # all exec/services are called with umask(077), so no gain beyond 0700 mkdir /data/misc/logd 0700 logd log # log group should be able to read persisted logs mkdir /data/misc/logd 0750 logd log start logcatd # stop logcatd service and clear data Loading
logd/logtagd.rc +1 −1 Original line number Diff line number Diff line Loading @@ -2,7 +2,7 @@ # logtagd event log tag service (debug only) # on post-fs-data mkdir /data/misc/logd 0700 logd log mkdir /data/misc/logd 0750 logd log write /data/misc/logd/event-log-tags "" chown logd log /data/misc/logd/event-log-tags chmod 0600 /data/misc/logd/event-log-tags Loading