Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d885c2a3 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Check calling package before send stored text." into sc-dev am: f2b93622

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/opt/telephony/+/15339924

Change-Id: I8d6f9b83c03a49b261f071284432957cc7d5de17
parents 263bd770 f2b93622
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -515,6 +515,10 @@ public class SmsController extends ISmsImplBase {
            Uri messageUri, String scAddress, PendingIntent sentIntent,
            PendingIntent deliveryIntent) {
        IccSmsInterfaceManager iccSmsIntMgr = getIccSmsInterfaceManager(subId);
        if (!getCallingPackage().equals(callingPkg)) {
            throw new SecurityException("sendStoredText: Package " + callingPkg
                    + "does not belong to " + Binder.getCallingUid());
        }
        if (iccSmsIntMgr != null) {
            iccSmsIntMgr.sendStoredText(callingPkg, callingAttributionTag, messageUri, scAddress,
                    sentIntent, deliveryIntent);