Przeglądaj źródła

Harden privacy permission compliance for calendar and location flows.

Add explicit macOS privacy usage keys for EventKit full access and location, and deny blanket web geolocation grants so location access remains tied to the user-initiated Maps action.

Made-with: Cursor
Hussain Afzal 3 miesięcy temu
rodzic
commit
081faba79a

+ 6 - 2
google_apps.xcodeproj/project.pbxproj

@@ -259,8 +259,10 @@
 				INFOPLIST_KEY_CFBundleName = "Easy Access for Google Apps";
 				INFOPLIST_KEY_CFBundleDisplayName = "Easy Access for Google Apps";
 				INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
-				INFOPLIST_KEY_NSCalendarsUsageDescription = "The Calendar widget shows upcoming events from Apple Calendar (including calendars synced with Google) and opens Google Calendar for scheduling.";
+				INFOPLIST_KEY_NSCalendarsFullAccessUsageDescription = "Calendar access is used to show your upcoming events and Meet links in the Calendar and Meet widgets. Event data stays on-device and is only used to populate widget content.";
+				INFOPLIST_KEY_NSCalendarsUsageDescription = "Calendar access is used to show your upcoming events and Meet links in the Calendar and Meet widgets. Event data stays on-device and is only used to populate widget content.";
 				INFOPLIST_KEY_NSHumanReadableCopyright = "";
+				INFOPLIST_KEY_NSLocationUsageDescription = "Location is used only when you tap 'My location' in the Maps widget to center the map near you.";
 				INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "Google Maps uses your location to center the map and suggest nearby places.";
 				INFOPLIST_KEY_NSMainStoryboardFile = Main;
 				INFOPLIST_KEY_NSPrincipalClass = NSApplication;
@@ -297,8 +299,10 @@
 				INFOPLIST_KEY_CFBundleName = "Easy Access for Google Apps";
 				INFOPLIST_KEY_CFBundleDisplayName = "Easy Access for Google Apps";
 				INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
-				INFOPLIST_KEY_NSCalendarsUsageDescription = "The Calendar widget shows upcoming events from Apple Calendar (including calendars synced with Google) and opens Google Calendar for scheduling.";
+				INFOPLIST_KEY_NSCalendarsFullAccessUsageDescription = "Calendar access is used to show your upcoming events and Meet links in the Calendar and Meet widgets. Event data stays on-device and is only used to populate widget content.";
+				INFOPLIST_KEY_NSCalendarsUsageDescription = "Calendar access is used to show your upcoming events and Meet links in the Calendar and Meet widgets. Event data stays on-device and is only used to populate widget content.";
 				INFOPLIST_KEY_NSHumanReadableCopyright = "";
+				INFOPLIST_KEY_NSLocationUsageDescription = "Location is used only when you tap 'My location' in the Maps widget to center the map near you.";
 				INFOPLIST_KEY_NSLocationWhenInUseUsageDescription = "Google Maps uses your location to center the map and suggest nearby places.";
 				INFOPLIST_KEY_NSMainStoryboardFile = Main;
 				INFOPLIST_KEY_NSPrincipalClass = NSApplication;

+ 3 - 1
google_apps/Widgets/MapsInteractiveWidgetView.swift

@@ -541,7 +541,9 @@ private struct MapsWebWidgetView: NSViewRepresentable {
             initiatedByFrame frame: WKFrameInfo,
             decisionHandler: @escaping (WKPermissionDecision) -> Void
         ) {
-            decisionHandler(.grant)
+            // Keep geolocation scoped to the explicit "My location" control flow.
+            // Avoid silently granting all webpage geolocation requests in the embedded web view.
+            decisionHandler(.deny)
         }
     }
 }