Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MSTG-STORAGE-12] Add Privacy Labels and Rework Privacy Chapter #1988

Merged
merged 36 commits into from
Dec 22, 2021
Merged
Changes from 2 commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
55d3704
add nutrition and data safety labels, references and first steps on t…
cpholguera Nov 24, 2021
8201839
add privacy report, data access audit and privacy dashboard.
cpholguera Nov 24, 2021
8eacbc5
Update Document/0x04i-Testing-user-interaction.md
cpholguera Nov 26, 2021
0057c88
remove unreferenced requirements
cpholguera Dec 2, 2021
3df7fc2
rewrite User Interaction since it's actually about User Provacy Prote…
cpholguera Dec 2, 2021
bd2d1ff
Merge branch 'enhance-storage-2' of github.com:OWASP/owasp-mstg into …
cpholguera Dec 2, 2021
7053d94
rename chapter file to be consistent
cpholguera Dec 2, 2021
761e348
change name also in the README
cpholguera Dec 2, 2021
7c35ccc
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
dbbb5dd
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
66c7879
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
2b7bda3
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
80d1518
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
0d5b88b
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
fe8d977
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
c91535f
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
0d5c2dc
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
ec27148
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
b8e43c6
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
622bd5f
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
4c0cce8
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
fddccfc
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
89db17f
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
b808850
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
7d5ad6e
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
7569113
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
463ebef
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
04bb15f
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
13fea44
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
9f36097
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
9298da0
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
0ba1b66
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
305e0c7
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 14, 2021
f29cfec
Update Document/0x04i-Testing-User-Privacy-Protection.md
cpholguera Dec 18, 2021
296ba05
fix to reduce the scope of the test
cpholguera Dec 22, 2021
17479d1
update common violations to express the relationship with other categ…
cpholguera Dec 22, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 37 additions & 1 deletion Document/0x04i-Testing-user-interaction.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,46 @@ When you need personal information from a user for your business process, the us
- **The right to correct data**: Users should be able to correct their personal information at any time, and be explained how to do so.
- **The right to access user data**: Users should be able to request all information that the application has on them, and be explained how to request this information.

Most of this can be covered in a privacy policy, but make sure that it is understandable by the user.
Most of this is traditionally being covered in a privacy policy. However, this approach is not always optimal for users who would be require to read usually long and wordly policies. In order to address this and help users easily understand how their data is being collected, handled and shared, Google and Apple introduced new privacy labeling systems (very much along the lines of NIST's proposal for [Consumer Software Cybersecurity Labeling](https://www.nist.gov/system/files/documents/2021/11/01/Draft%20Consumer%20Software%20Labeling.pdf)):
cpholguera marked this conversation as resolved.
Show resolved Hide resolved
- the App Store [Nutrition Labels](https://www.apple.com/privacy/labels/) (since 2020).
- the Google Play [Data Safety Labels](https://android-developers.googleblog.com/2021/05/new-safety-section-in-google-play-will.html) (since 2021).

As a new requirement on both platforms, it's vital that these labels are accurate in order to provide user assurance and mitigate developer abuse.


When additional data needs to be processed, you should ask the user for consent again. During that consent request it needs to be made clear how the user can revert from sharing the additional data. Similarly, when existing datasets of a user need to be linked, you should ask the user's consent about it.

You can learn more about this and other privacy related topics here:

- [iOS App Privacy Policy](https://developer.apple.com/documentation/healthkit/protecting_user_privacy#3705073)
- [iOS Privacy Details Section on the App Store](https://developer.apple.com/app-store/app-privacy-details/)
- [iOS Privacy Best Practices](https://developer.apple.com/documentation/uikit/protecting_the_user_s_privacy)
- [Android App Privacy Policy](https://support.google.com/googleplay/android-developer/answer/9859455#privacy_policy)
- [Android Data Safety Section on Google Play](https://support.google.com/googleplay/android-developer/answer/10787469)
- [Android Privacy Best Practices](https://developer.android.com/privacy/best-practices)

#### Testing Data Privacy

You can use the following resources as a starting point for your analysis.

**Android:**
- [Review how the app collects and shares user data](https://developer.android.com/guide/topics/data/collect-share).
- Verify if the app performs [Data Access Auditing](https://developer.android.com/guide/topics/data/audit-access) (available for Android 11 (API level 30) and higher) and list all the used attribution tags. You can use the [DataAccessAuditingKotlin sample app](https://github.com/android/permissions-samples/tree/master/DataAccessAuditingKotlin) as a reference.
- Use the [Privacy Dashboard](https://developer.android.com/training/permissions/explaining-access#privacy-dashboard) from the Android settings (Android 12 (API level 31) and higher) to monitor app access to sensitive information.

**iOS:**

- Verify which [iOS Privacy Details](https://developer.apple.com/app-store/app-privacy-details/) does the app include on the App Store.
- Verify if and how the app is using the [App Tracking Transparency Framework](https://developer.apple.com/documentation/apptrackingtransparency).
- [Enable the App Privacy Report](https://developer.apple.com/documentation/network/privacy_management/inspecting_app_activity_data) from the iOS settings (iOS 15.2 and higher) to monitor app activity data. After using the app extensively, you can save the report as JSON file containing a collection of dictionaries of different types. Parse for the `type: "access"` to inspect all data access by category (camera, contacts, etc.) and the `type: "networkActivity"` to examine all network accesses.


These are some examples of common violations that you should report:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How would this work in real-life for the user and for us during verification?
Would we verify that a one-time pop-up is explaining this (which will be anyway coming when accessing camera, contacts etc due to approving the permission), so the additional information is needed? Or would we simply verify the nutrition / data safety labels?
Where would it be defined that something is sensitive data, like An app that records a user’s screen and doesn't treat this data as personal or sensitive data subject to this policy. This is defined by the developer in the app? What would be the testing process, the tester would run app activity https://developer.apple.com/documentation/network/privacy_management/inspecting_app_activity_data and then we check it against the privacy policy?

I think it's quite a few options we are listing above, so we might want to clarify a bit further and give some more guidance, otherwise it might be a bit overwhelming what to do now exactly.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we're testing MSTG-STORAGE-12:

The app educates the user about the types of personally identifiable information processed, as well as security best practices the user should follow in using the app.

I think the testing strategy for now should be:

  • look at if and what the app declares it collects/shares (in the App Store iOS Privacy Details and in Google Play Safety Section).
  • check if the app is at least doing everything it could be doing to inform the user:
    • using prominent in-app disclosure of data access, collection, use, and sharing.
    • using the "App Tracking Transparency Framework" / "Data Access Auditing".

I'm going to reflect this on this sub-section (now there's more info than required). We should address that but as part of other test cases / requirements.

- An app collects device location but does not have a prominent disclosure explaining which feature uses this data and/or indicates the app's usage in the background.
- An app has a runtime permission requesting access to data before the prominent disclosure which specifies what the data is used for.
- An app that accesses a user's phone or contact book data and doesn't treat this data as personal or sensitive data subject to the above Privacy Policy, data handling, and Prominent Disclosure and Consent requirements.
- An app that records a user’s screen and doesn't treat this data as personal or sensitive data subject to this policy.

### Informing the user on the best security practices

Here is a list of best practices where a user could be informed of:
Expand Down