Merge "Limit Activity taskAffinity to application uid"
This commit is contained in:
committed by
Android (Google) Code Review
commit
9cfe912384
@@ -1520,7 +1520,13 @@ final class ActivityRecord extends WindowToken implements WindowManagerService.A
|
||||
hasBeenLaunched = false;
|
||||
mStackSupervisor = supervisor;
|
||||
|
||||
taskAffinity = aInfo.taskAffinity;
|
||||
// b/35954083: Limit task affinity to uid to avoid various issues associated with sharing
|
||||
// affinity across uids.
|
||||
final String uid = Integer.toString(info.applicationInfo.uid);
|
||||
if (info.taskAffinity != null && !info.taskAffinity.startsWith(uid)) {
|
||||
info.taskAffinity = uid + ":" + info.taskAffinity;
|
||||
}
|
||||
taskAffinity = info.taskAffinity;
|
||||
stateNotNeeded = (aInfo.flags & FLAG_STATE_NOT_NEEDED) != 0;
|
||||
nonLocalizedLabel = aInfo.nonLocalizedLabel;
|
||||
labelRes = aInfo.labelRes;
|
||||
|
||||
Reference in New Issue
Block a user