kernel: Add mitigation to avoid placing manager in lib to bypass check
This commit is contained in:
@@ -57,7 +57,8 @@ bool become_manager(char *pkg)
|
||||
}
|
||||
cwd = d_path(&files_path, buf, PATH_MAX);
|
||||
if (startswith(cwd, "/data/app/") != 0 ||
|
||||
endswith(cwd, "/base.apk") != 0) {
|
||||
endswith(cwd, "==/base.apk") != 0) {
|
||||
// AOSP generate ramdom base64 with 16bit, without NO_PADDING, so it must have two "="
|
||||
continue;
|
||||
}
|
||||
// we have found the apk!
|
||||
|
||||
Reference in New Issue
Block a user