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

Commit 529cfa60 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 am: 24d0241b

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

Change-Id: I1153c558a9cbd2b51f3fbc19b04a111177dce261
parents db977160 24d0241b
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);