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

Interface with the Android KeyStore #35

Open
1 of 3 tasks
puddly opened this issue Jun 1, 2020 · 0 comments
Open
1 of 3 tasks

Interface with the Android KeyStore #35

puddly opened this issue Jun 1, 2020 · 0 comments

Comments

@puddly
Copy link
Owner

puddly commented Jun 1, 2020

Apps are slowly beginning to use the Android KeyStore to encrypt database entries or the entire database itself, making it impossible to extract information without interfacing with the Android KeyStore. Thankfully we don't really care about the encryption keys themselves and just want to ask the KeyStore to decrypt data, which is just what the KeyStore is for.

Using some of the setup code from scrcpy's Android server, I've written a small Java tool that can be pushed to the device and run as an app's user to provide an interactive KeyStore interface for the Python code.

Checklist:

  • Successfully interact with the Android KeyStore as an app user via su.
  • Interact with the Android KeyStore without having to call setenforce 0.
  • The current ADB wrapper is a little fragile due to the various quirks exhibited by old ADB servers and BusyBox versions (or lack of thereof) installed on old devices. The major issue right now is the inability to interactively send and receive commands during a shell session and instead being forced to run commands one-by-one via adb shell. This is more a performance optimization than anything else but it taking a minute to read and decrypt a few files is annoying.
    • One possible solution to both problems is to integrate file reading and related commands into the KeyStore proxy, which would remove the BusyBox dependency. This would require the KeyStore proxy to have the ability to execute commands as other users (including itself).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant