Skip to content

Commit

Permalink
Add xcprivacy manifest info. (#372)
Browse files Browse the repository at this point in the history
Core -
  If using the NSURLSession background fetch support, the data to restore
  download information across app launches is recorded in NSUserDefaults.

Full -
  No api's called by these sources.

LogView -
  DDA9.1 isn't correct because the data isn't displayed, the data is just used
  to sort the log names within the LogView UX so they are properly ordered.

  The data is *not* sent off the device, C617.1 doesn't state that, but nothing
  else seems to be a match since the data isn't directly displayed.

Fixes #360
  • Loading branch information
thomasvl committed Jan 26, 2024
1 parent 4a83c0b commit aac6380
Show file tree
Hide file tree
Showing 5 changed files with 84 additions and 6 deletions.
9 changes: 9 additions & 0 deletions GTMSessionFetcher.podspec
Expand Up @@ -35,19 +35,28 @@ Pod::Spec.new do |s|
sp.source_files = 'Sources/Core/**/*.{h,m}'
sp.public_header_files = 'Sources/Core/Public/GTMSessionFetcher/*.h'
sp.framework = 'Security'
sp.resource_bundle = {
"GTMSessionFetcher_Core_Privacy" => "Sources/Core/Resources/PrivacyInfo.xcprivacy"
}
end

s.subspec 'Full' do |sp|
sp.source_files = 'Sources/Full/**/*.{h,m}'
sp.public_header_files = 'Sources/Full/Public/GTMSessionFetcher/*.h'
sp.dependency 'GTMSessionFetcher/Core'
sp.resource_bundle = {
"GTMSessionFetcher_Full_Privacy" => "Sources/Full/Resources/PrivacyInfo.xcprivacy"
}
end

s.subspec 'LogView' do |sp|
# Only relevant for iOS, files compile away on others.
sp.source_files = 'Sources/LogView/**/*.{h,m}'
sp.public_header_files = 'Sources/LogView/Public/GTMSessionFetcher/*.h'
sp.dependency 'GTMSessionFetcher/Core'
sp.resource_bundle = {
"GTMSessionFetcher_LogView_Privacy" => "Sources/LogView/Resources/PrivacyInfo.xcprivacy"
}
end

s.test_spec 'Tests' do |sp|
Expand Down
21 changes: 15 additions & 6 deletions Package.swift
@@ -1,4 +1,4 @@
// swift-tools-version:5.1
// swift-tools-version:5.3
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription

Expand Down Expand Up @@ -32,35 +32,44 @@ let package = Package(
.target(
name: "GTMSessionFetcherCore",
path: "Sources/Core",
resources: [
.process("Resources/PrivacyInfo.xcprivacy")
],
publicHeadersPath: "Public"
),
.target(
name: "GTMSessionFetcherFull",
dependencies: ["GTMSessionFetcherCore"],
path: "Sources/Full",
resources: [
.process("Resources/PrivacyInfo.xcprivacy")
],
publicHeadersPath: "Public"
),
.target(
name: "GTMSessionFetcherLogView",
dependencies: ["GTMSessionFetcherCore"],
path: "Sources/LogView",
resources: [
.process("Resources/PrivacyInfo.xcprivacy")
],
publicHeadersPath: "Public"
),
.testTarget(
name: "GTMSessionFetcherCoreTests",
dependencies: ["GTMSessionFetcherFull", "GTMSessionFetcherCore"],
path: "UnitTests",
exclude: ["GTMSessionFetcherUserAgentTest.m"],
exclude: ["GTMSessionFetcherUserAgentTest.m"],
cSettings: [
.headerSearchPath("../Sources/Core")
]
),
// This runs in its own target since it exercises global variable initialization.
.testTarget(
name: "GTMSessionFetcherUserAgentTests",
dependencies: ["GTMSessionFetcherCore"],
.testTarget(
name: "GTMSessionFetcherUserAgentTests",
dependencies: ["GTMSessionFetcherCore"],
path: "UnitTests",
sources: ["GTMSessionFetcherUserAgentTest.m"],
sources: ["GTMSessionFetcherUserAgentTest.m"],
cSettings: [
.headerSearchPath("../Sources/Core")
]
Expand Down
23 changes: 23 additions & 0 deletions Sources/Core/Resources/PrivacyInfo.xcprivacy
@@ -0,0 +1,23 @@
<?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>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>CA92.1</string>
</array>
</dict>
</array>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyTrackingDomains</key>
<array/>
</dict>
</plist>
14 changes: 14 additions & 0 deletions Sources/Full/Resources/PrivacyInfo.xcprivacy
@@ -0,0 +1,14 @@
<?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>NSPrivacyAccessedAPITypes</key>
<array/>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyTrackingDomains</key>
<array/>
</dict>
</plist>
23 changes: 23 additions & 0 deletions Sources/LogView/Resources/PrivacyInfo.xcprivacy
@@ -0,0 +1,23 @@
<?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>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
</array>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyTracking</key>
<false/>
<key>NSPrivacyTrackingDomains</key>
<array/>
</dict>
</plist>

0 comments on commit aac6380

Please sign in to comment.