PaymentDefaultDialog Could be Overlaid

Settings#PaymentDefaultDialog Could be Overlaid to Trick User into
Updating Default Payment App

Bug: 180104327
Test: build ok
Change-Id: Ia7786d05aae8e38a11bd73d02200640cb614e88a
This commit is contained in:
Alisher Alikhodjaev
2021-09-13 17:00:30 -07:00
parent 46902bd366
commit b2c03474c4

View File

@@ -30,6 +30,8 @@ import com.android.settings.nfc.PaymentBackend.PaymentAppInfo;
import java.util.List;
import static android.view.WindowManager.LayoutParams.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS;
public final class PaymentDefaultDialog extends AlertActivity implements
DialogInterface.OnClickListener {
@@ -42,6 +44,9 @@ public final class PaymentDefaultDialog extends AlertActivity implements
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getWindow().addPrivateFlags(SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS);
try {
mBackend = new PaymentBackend(this);
} catch (NullPointerException e) {