Skip to content

Commit bc773e7

Browse files
committed
feat(ios): Add bundled resources for privacy manifest
1 parent 09e3d89 commit bc773e7

File tree

3 files changed

+69
-0
lines changed

3 files changed

+69
-0
lines changed

Diff for: README.md

+13
Original file line numberDiff line numberDiff line change
@@ -776,3 +776,16 @@ function watchPicturePosition() {
776776
}
777777

778778
```
779+
780+
---
781+
782+
## iOS Privacy Manifest
783+
784+
As of May 1, 2024, Apple requires a privacy manifest file to be created for apps and third-party SDKs. The purpose of the privacy manifest file is to explain the data being collected and the reasons for the required APIs it uses. Starting with `[email protected]`, APIs are available for configuring the privacy manifest file from `config.xml`.
785+
786+
This plugin comes pre-bundled with a `PrivacyInfo.xcprivacy` file that contains the list of APIs it uses and the reasons for using them.
787+
788+
However, as an app developer, it will be your responsibility to identify additional information explaining what your app does with that data.
789+
In this case, you will need to review the "[Describing data use in privacy manifests](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests)" to understand the list of known `NSPrivacyCollectedDataTypes` and `NSPrivacyCollectedDataTypePurposes`.
790+
791+
Also, ensure all four keys—`NSPrivacyTracking`, `NSPrivacyTrackingDomains`, `NSPrivacyAccessedAPITypes`, and `NSPrivacyCollectedDataTypes`—are defined, even if you are not making an addition to the other items. Apple requires all to be defined.

Diff for: plugin.xml

+1
Original file line numberDiff line numberDiff line change
@@ -93,5 +93,6 @@ xmlns:android="http://schemas.android.com/apk/res/android"
9393
<source-file src="src/ios/CDVLocation.m" />
9494
<framework src="CoreLocation.framework" />
9595

96+
<resource-file src="src/ios/CDVGeolocation.bundle" target="CDVGeolocation.bundle" />
9697
</platform>
9798
</plugin>

Diff for: src/ios/CDVGeolocation.bundle/PrivacyInfo.xcprivacy

+55
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
Licensed to the Apache Software Foundation (ASF) under one
4+
or more contributor license agreements. See the NOTICE file
5+
distributed with this work for additional information
6+
regarding copyright ownership. The ASF licenses this file
7+
to you under the Apache License, Version 2.0 (the
8+
"License"); you may not use this file except in compliance
9+
with the License. You may obtain a copy of the License at
10+
http://www.apache.org/licenses/LICENSE-2.0
11+
Unless required by applicable law or agreed to in writing,
12+
software distributed under the License is distributed on an
13+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
KIND, either express or implied. See the License for the
15+
specific language governing permissions and limitations
16+
under the License.
17+
-->
18+
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
19+
<plist version="1.0">
20+
<dict>
21+
<key>NSPrivacyTracking</key>
22+
<false/>
23+
<key>NSPrivacyTrackingDomains</key>
24+
<array/>
25+
<key>NSPrivacyAccessedAPITypes</key>
26+
<array/>
27+
<key>NSPrivacyCollectedDataTypes</key>
28+
<array>
29+
<dict>
30+
<key>NSPrivacyCollectedDataType</key>
31+
<string>NSPrivacyCollectedDataTypePreciseLocation</string>
32+
<key>NSPrivacyCollectedDataTypeLinked</key>
33+
<false/>
34+
<key>NSPrivacyCollectedDataTypeTracking</key>
35+
<false/>
36+
<key>NSPrivacyCollectedDataTypePurposes</key>
37+
<array>
38+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
39+
</array>
40+
</dict>
41+
<dict>
42+
<key>NSPrivacyCollectedDataType</key>
43+
<string>NSPrivacyCollectedDataTypeCoarseLocation</string>
44+
<key>NSPrivacyCollectedDataTypeLinked</key>
45+
<false/>
46+
<key>NSPrivacyCollectedDataTypeTracking</key>
47+
<false/>
48+
<key>NSPrivacyCollectedDataTypePurposes</key>
49+
<array>
50+
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
51+
</array>
52+
</dict>
53+
</array>
54+
</dict>
55+
</plist>

0 commit comments

Comments
 (0)