mirror of
https://github.com/jonasbark/swiftcontrol.git
synced 2026-11-29 09:11:17 +01:00
Denial of Apple's Local Network privacy permission is the most common cause of "BikeControl can't see my trainer app" on iOS and macOS, and it fails completely silently: Bonjour browses return nothing forever, advertisements never leave the device, nothing throws. An app watching only for errors cannot tell "permission is off" from "there is nothing out there". Apple ships no authorization-status API for it (not iOS 14...26, not macOS 15...26), so the new local_network_permission plugin measures it: an NWListener and an NWBrowser on _bikecontrol-preflight._tcp, then browser discovers the listener -> granted kDNSServiceErr_PolicyDenied (-65570) -> denied neither, before the deadline -> unknown unknown is a real outcome, not an error — a device with no usable network never completes the round trip even when the permission is fine — so everything fails open on it and only a positive denial blocks the user. The probe *is* the request: the system prompt fires on the first Bonjour operation, so there is no separate request step, and after the user answers, System Settings is the only way back. - LocalNetworkAccess caches the result (probes cost a real round trip while getStatus() runs on every tile mount, tap and resume) and collapses concurrent probes into one, since two listeners on the same service type would resolve each other. - LocalNetworkRequirement gates the three LAN tiles: MyWhoosh Link, Zwift mDNS and OpenBikeControl mDNS. Suppressed in screenshot/demo mode like the rest. - Diagnostics drop the old guess (inferred from whether a discovery scan returned anything, which could not tell denied from an empty LAN) for the measured local-network=granted|denied|unknown. - _bikecontrol-preflight._tcp added to NSBonjourServices on both platforms; without it the browse fails for a reason unrelated to the permission. The Xcode project deployment-target bumps (ios 13.0->15.0, macos 10.15->12.0) are Flutter's own migration aligning project defaults with the Podfiles; they happen on any first build. Verified with real builds on both platforms, not just analysis: flutter build macos --debug and flutter build ios --no-codesign both succeed, the framework is linked in, and the preflight service type is present in both built Info.plists. 35 tests cover the mapping, cache, concurrency and fail-open behaviour. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
122 lines
3.9 KiB
Plaintext
122 lines
3.9 KiB
Plaintext
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
|
<plist version="1.0">
|
|
<dict>
|
|
<key>CADisableMinimumFrameDurationOnPhone</key>
|
|
<true/>
|
|
<key>CFBundleDevelopmentRegion</key>
|
|
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
|
<key>CFBundleDisplayName</key>
|
|
<string>BikeControl</string>
|
|
<key>CFBundleExecutable</key>
|
|
<string>$(EXECUTABLE_NAME)</string>
|
|
<key>CFBundleIdentifier</key>
|
|
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
|
<key>CFBundleInfoDictionaryVersion</key>
|
|
<string>6.0</string>
|
|
<key>CFBundleName</key>
|
|
<string>swift_play</string>
|
|
<key>CFBundlePackageType</key>
|
|
<string>APPL</string>
|
|
<key>CFBundleShortVersionString</key>
|
|
<string>$(FLUTTER_BUILD_NAME)</string>
|
|
<key>CFBundleSignature</key>
|
|
<string>????</string>
|
|
<key>CFBundleURLTypes</key>
|
|
<array>
|
|
<dict>
|
|
<key>CFBundleURLName</key>
|
|
<string>app.bikecontrol</string>
|
|
<key>CFBundleTypeRole</key>
|
|
<string>Editor</string>
|
|
<key>CFBundleURLSchemes</key>
|
|
<array>
|
|
<string>bikecontrol</string>
|
|
</array>
|
|
</dict>
|
|
<dict>
|
|
<key>CFBundleTypeRole</key>
|
|
<string>Editor</string>
|
|
<key>CFBundleURLSchemes</key>
|
|
<array>
|
|
<string>com.googleusercontent.apps.709945926587-0iierajthibf4vhqf85fc7bbpgbdgua2</string>
|
|
</array>
|
|
</dict>
|
|
</array>
|
|
<key>CFBundleVersion</key>
|
|
<string>$(FLUTTER_BUILD_NUMBER)</string>
|
|
<key>GIDClientID</key>
|
|
<string>709945926587-0iierajthibf4vhqf85fc7bbpgbdgua2.apps.googleusercontent.com</string>
|
|
<key>ITSAppUsesNonExemptEncryption</key>
|
|
<false/>
|
|
<key>LSRequiresIPhoneOS</key>
|
|
<true/>
|
|
<key>NSBluetoothAlwaysUsageDescription</key>
|
|
<string>BikeControl uses Bluetooth to connect to accessories.</string>
|
|
<key>NSBonjourServices</key>
|
|
<array>
|
|
<string>_wahoo-fitness-tnp._tcp</string>
|
|
<string>_openbikecontrol._tcp</string>
|
|
<string>_bikecontrol-preflight._tcp</string>
|
|
</array>
|
|
<key>NSLocalNetworkUsageDescription</key>
|
|
<string>This app connects to your trainer app on your local network.</string>
|
|
<key>NSMotionUsageDescription</key>
|
|
<string>Access your accelerometer and gyroscope for steering support via your phone.</string>
|
|
<key>NSCameraUsageDescription</key>
|
|
<string>BikeControl does not use the camera. This entry is required because the image picker plugin links camera APIs.</string>
|
|
<key>NSPhotoLibraryUsageDescription</key>
|
|
<string>Access your photo library to store screenshots.</string>
|
|
<key>NSPhotoLibraryAddUsageDescription</key>
|
|
<string>BikeControl saves your screen recordings to your photo library.</string>
|
|
<key>NSSupportsLiveActivities</key>
|
|
<true/>
|
|
<key>UIApplicationSceneManifest</key>
|
|
<dict>
|
|
<key>UIApplicationSupportsMultipleScenes</key>
|
|
<false/>
|
|
<key>UISceneConfigurations</key>
|
|
<dict>
|
|
<key>UIWindowSceneSessionRoleApplication</key>
|
|
<array>
|
|
<dict>
|
|
<key>UISceneClassName</key>
|
|
<string>UIWindowScene</string>
|
|
<key>UISceneConfigurationName</key>
|
|
<string>flutter</string>
|
|
<key>UISceneDelegateClassName</key>
|
|
<string>FlutterSceneDelegate</string>
|
|
<key>UISceneStoryboardFile</key>
|
|
<string>Main</string>
|
|
</dict>
|
|
</array>
|
|
</dict>
|
|
</dict>
|
|
<key>UIApplicationSupportsIndirectInputEvents</key>
|
|
<true/>
|
|
<key>UIBackgroundModes</key>
|
|
<array>
|
|
<string>bluetooth-peripheral</string>
|
|
<string>bluetooth-central</string>
|
|
<string>audio</string>
|
|
</array>
|
|
<key>UILaunchStoryboardName</key>
|
|
<string>LaunchScreen</string>
|
|
<key>UIMainStoryboardFile</key>
|
|
<string>Main</string>
|
|
<key>UISupportedInterfaceOrientations</key>
|
|
<array>
|
|
<string>UIInterfaceOrientationPortrait</string>
|
|
<string>UIInterfaceOrientationLandscapeLeft</string>
|
|
<string>UIInterfaceOrientationLandscapeRight</string>
|
|
</array>
|
|
<key>UISupportedInterfaceOrientations~ipad</key>
|
|
<array>
|
|
<string>UIInterfaceOrientationPortrait</string>
|
|
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
|
<string>UIInterfaceOrientationLandscapeLeft</string>
|
|
<string>UIInterfaceOrientationLandscapeRight</string>
|
|
</array>
|
|
</dict>
|
|
</plist>
|