Merge the 2021-08-05 SPL branch from AOSP-Partner

* security-aosp-pi-release:
  Add permission for the broadcast intent with SIP profiles for security purpose.

Change-Id: Ie10f50d080c106212e0c69e296d48edc9359d2b2
diff --git a/src/java/com/android/server/sip/SipService.java b/src/java/com/android/server/sip/SipService.java
index 6573258..2c1f6ee 100644
--- a/src/java/com/android/server/sip/SipService.java
+++ b/src/java/com/android/server/sip/SipService.java
@@ -345,7 +345,7 @@
         if (DBG) log("notify: profile added: " + localProfile);
         Intent intent = new Intent(SipManager.ACTION_SIP_ADD_PHONE);
         intent.putExtra(SipManager.EXTRA_LOCAL_URI, localProfile.getUriString());
-        mContext.sendBroadcast(intent);
+        mContext.sendBroadcast(intent, android.Manifest.permission.USE_SIP);
         if (mSipGroups.size() == 1) {
             registerReceivers();
         }
@@ -355,7 +355,7 @@
         if (DBG) log("notify: profile removed: " + localProfile);
         Intent intent = new Intent(SipManager.ACTION_SIP_REMOVE_PHONE);
         intent.putExtra(SipManager.EXTRA_LOCAL_URI, localProfile.getUriString());
-        mContext.sendBroadcast(intent);
+        mContext.sendBroadcast(intent, android.Manifest.permission.USE_SIP);
         if (mSipGroups.size() == 0) {
             unregisterReceivers();
         }