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

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

Merge "Check calling package before send sms text." into sc-dev am: 6d9e3c92

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

Change-Id: I46edbb5759b1924a15597ecdf445cb3ca7204387
parents 4d6e1d1c 6d9e3c92
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -529,6 +529,10 @@ public class SmsController extends ISmsImplBase {
            Uri messageUri, String scAddress, List<PendingIntent> sentIntents,
            List<PendingIntent> deliveryIntents) {
        IccSmsInterfaceManager iccSmsIntMgr = getIccSmsInterfaceManager(subId);
        if (!getCallingPackage().equals(callingPkg)) {
            throw new SecurityException("sendStoredMultipartText: Package " + callingPkg
                    + " does not belong to " + Binder.getCallingUid());
        }
        if (iccSmsIntMgr != null) {
            iccSmsIntMgr.sendStoredMultipartText(callingPkg, callingAttributionTag, messageUri,
                    scAddress, sentIntents, deliveryIntents);