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

Port MASTG-TEST-0012: Testing the Device-Access-Security Policy (android) (by @guardsquare) #3113

Merged
merged 117 commits into from
Mar 7, 2025

Conversation

serek8
Copy link
Collaborator

@serek8 serek8 commented Jan 14, 2025

This PR closes #2937

  • I removed USB Debugging and Root detection from this test. It should be considered as a part or MASVS-RESILIENCE
  • MASVSv1 used Settings.Secure and Device Administration APIs to verify Device-Access-Security. These APIs seem to be either deprecated or unrelated. Therefore, MASVSv2 introduces the use of KeyguardManager to provide an easy way to verify passcode presence.

@serek8 serek8 marked this pull request as ready for review February 6, 2025 08:49
@serek8 serek8 requested a review from cpholguera February 6, 2025 08:49
@cpholguera
Copy link
Collaborator

Using the new .kt file:

Emulator

image

Physical Pixel

image


## Overview

This test verifies that an application is running on a device with a set passcode. A set passcode ensures that data on the device is encrypted and access to the device is restricted.
Copy link
Collaborator

@cpholguera cpholguera Feb 7, 2025

Choose a reason for hiding this comment

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

Should we also include this?

From the weakness draft:

to make sure that biometrics can be used, verify that the kSecAttrAccessibleWhenPasscodeSetThisDeviceOnly or the kSecAttrAccessibleWhenPasscodeSet protection class is set when the SecAccessControlCreateWithFlags method is called

To use Optic ID, Face ID, or Touch ID, the user must set up their device so that a passcode or password is required to unlock it.

https://support.apple.com/en-ph/guide/security/sec9479035f1/web

@cpholguera cpholguera changed the title Port MASTG-TEST-0012 (by @guardsquare) Port MASTG-TEST-0012: Testing the Device-Access-Security Policy (android) (by @guardsquare) Feb 24, 2025
@cpholguera cpholguera merged commit fd7ccc3 into OWASP:master Mar 7, 2025
34 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MASTG v1->v2 MASTG-TEST-0012: Testing the Device-Access-Security Policy (android)