llkd: adbd is allowed to be a bad parent on userdebug

If an errant process is identified, and the parent is adbd,
on userdebug builds bypass monitoring the process.

Test: unit tests
Bug: 120983740
Change-Id: I2af0797504326b0e95aa4377918b35d17716a6a2
This commit is contained in:
Mark Salyzyn 2018-12-13 08:28:44 -08:00
parent 1d6969ccb9
commit 599958d114
2 changed files with 5 additions and 1 deletions

View file

@ -160,7 +160,7 @@ size of 92.
NB: false is a very very very unlikely process to want to blacklist.
#### ro.llk.blacklist.parent
default 0,2 (kernel and [kthreadd]).
default 0,2,adbd (kernel, [kthreadd] and adbd).
The string "*false*" is the equivalent to an *empty* list.
Do not watch processes that have this parent.
A parent process can be comm, cmdline or pid reference.

View file

@ -55,7 +55,11 @@ unsigned llkCheckMilliseconds(void);
#define LLK_BLACKLIST_PROCESS_DEFAULT \
"0,1,2,init,[kthreadd],[khungtaskd],lmkd,llkd,watchdogd,[watchdogd],[watchdogd/0]"
#define LLK_BLACKLIST_PARENT_PROPERTY "ro.llk.blacklist.parent"
#ifdef __PTRACE_ENABLED__ // defined if userdebug build
#define LLK_BLACKLIST_PARENT_DEFAULT "0,2,[kthreadd],adbd"
#else
#define LLK_BLACKLIST_PARENT_DEFAULT "0,2,[kthreadd]"
#endif
#define LLK_BLACKLIST_UID_PROPERTY "ro.llk.blacklist.uid"
#define LLK_BLACKLIST_UID_DEFAULT ""
#define LLK_BLACKLIST_STACK_PROPERTY "ro.llk.blacklist.process.stack"