From af6fd9b346fe4b9c6f52b3ab75288cf454e64122 Mon Sep 17 00:00:00 2001 From: M57 <41645758+Hy4ri@users.noreply.github.com> Date: Tue, 4 Aug 2026 18:17:25 +0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=92=20Secure=20RemoteInput=20PendingIn?= =?UTF-8?q?tent=20boundaries=20(#800)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Added `setPackage(packageName)` to the explicitly defined reply intent before wrapping it in the mutable PendingIntent for remote input. RemoteInput intents strictly require `FLAG_MUTABLE` so the Android OS can append the user's text reply. To use `FLAG_MUTABLE` securely and prevent unintentional component delivery, explicit component boundaries (like `setPackage`) must be defined. --- .../m57/hermescontrol/notification/ChatNotificationService.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/app/src/main/java/com/m57/hermescontrol/notification/ChatNotificationService.kt b/app/src/main/java/com/m57/hermescontrol/notification/ChatNotificationService.kt index a90b8081..e5fb59f9 100644 --- a/app/src/main/java/com/m57/hermescontrol/notification/ChatNotificationService.kt +++ b/app/src/main/java/com/m57/hermescontrol/notification/ChatNotificationService.kt @@ -150,6 +150,7 @@ class ChatNotificationService : Service() { val replyIntent = Intent(this, NotificationReplyReceiver::class.java).apply { action = "$packageName.ACTION_NOTIFICATION_REPLY" + setPackage(packageName) putExtra(NotificationReplyReceiver.EXTRA_SESSION_ID, sessionId) }