-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Port MASTG-TEST-0052 (by @guardsquare) #3045
base: master
Are you sure you want to change the base?
Conversation
|
||
## Steps | ||
|
||
1. Run a static analysis (e.g. @MASTG-TOOL-0073) on the app binary, or use @MASTG-TOOL-0038 to dynamically verify the properties of the keychain items during the app runtime. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test needs to be split into static and dynamic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test still has something fundamental that we need to capture in a new test (or two): the app uses the Keychain API in 2 ways
- to store data in the Keychain itself (the keychain wasn't designed for this but developers do it)
- to encrypt data using keys from the Keychain and store it in private storage (envelope encryption)
|
||
1. Run a static analysis tool such as @MASTG-TOOL-0073 on the app binary. | ||
|
||
2. Search for APIs that indicates a use of Private Storage. This API includes: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should add the use of encryption APIs for envelope encryption or the explicit use of insecure data protection classes (?)
@@ -0,0 +1,31 @@ | |||
--- | |||
platform: ios | |||
title: Data Stored in Private Storage - Content Comparison Test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Android test is called "Data Stored in the App Sandbox at Runtime" but we can discuss the naming. This test doesn't match the pattern we defined for dynamic tests: "Runtime Use …", It could be "Runtime Storage of ..." but let me know what you think please.
- [UserDefaults](https://developer.apple.com/documentation/foundation/userdefaults) | ||
- [documentDirectory](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/documentdirectory) | ||
- [applicationSupportDirectory](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/applicationsupportdirectory) | ||
- [userDomainMask](https://developer.apple.com/documentation/foundation/filemanager/searchpathdomainmask/1408037-userdomainmask) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- [UserDefaults](https://developer.apple.com/documentation/foundation/userdefaults) | |
- [documentDirectory](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/documentdirectory) | |
- [applicationSupportDirectory](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/applicationsupportdirectory) | |
- [userDomainMask](https://developer.apple.com/documentation/foundation/filemanager/searchpathdomainmask/1408037-userdomainmask) | |
- [`UserDefaults`](https://developer.apple.com/documentation/foundation/userdefaults) | |
- [`documentDirectory`](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/documentdirectory) | |
- [`applicationSupportDirectory`](https://developer.apple.com/documentation/foundation/filemanager/searchpathdirectory/applicationsupportdirectory) | |
- [`userDomainMask`](https://developer.apple.com/documentation/foundation/filemanager/searchpathdomainmask/1408037-userdomainmask) |
title: Data Stored in Private Storage - Content Comparison Test | ||
id: MASTG-TEST-0x52-1 | ||
type: [dynamic] | ||
weakness: MASWE-0006 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add best-practices:
for all these tests, they will be similar if not the same I guess
This PR closes #2929.
I split this test into 3: