https://github.com/pp3345/ykdroid
YubiKey challenge-response USB and NFC driver for Android
https://github.com/pp3345/ykdroid
android challenge-response keepass keepass2android nfc usb yubikey
Last synced: 2 months ago
JSON representation
YubiKey challenge-response USB and NFC driver for Android
- Host: GitHub
- URL: https://github.com/pp3345/ykdroid
- Owner: pp3345
- License: gpl-3.0
- Created: 2017-09-30T14:20:49.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2023-06-04T11:32:14.000Z (about 2 years ago)
- Last Synced: 2025-03-09T22:26:31.436Z (3 months ago)
- Topics: android, challenge-response, keepass, keepass2android, nfc, usb, yubikey
- Language: Java
- Homepage:
- Size: 236 KB
- Stars: 99
- Watchers: 8
- Forks: 15
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ykDroid
ykDroid is an Android app that provides an interface for integrating the challenge-response functionality
of YubiKeys into other apps. Both USB and NFC (YubiKey NEO required for NFC) are supported on compatible devices.[
](https://play.google.com/store/apps/details?id=net.pp3345.ykdroid)
[](https://f-droid.org/packages/net.pp3345.ykdroid/)
## Integration
ykDroid provides an [Intent](https://developer.android.com/reference/android/content/Intent.html) called
`net.pp3345.ykdroid.intent.action.CHALLENGE_RESPONSE`, which accepts an extra `byte[] challenge` and returns an extra
`byte[] response`. Optionally, an extra `String purpose` may be passed additionally in the intent to identify the purpose
of the challenge. ykDroid will use this identifier to remember and pre-select the slot used for each purpose.Upon invocation, ykDroid will automatically detect which connection methods (USB and/or NFC) are available and show a dialog
overlay with instructions to the user.Example code:
```java
private static final int CHALLENGE_RESPONSE_REQUEST_CODE = 12345;private void startChallengeResponse(final byte[] challenge) {
final Intent intent = new Intent("net.pp3345.ykdroid.intent.action.CHALLENGE_RESPONSE");
intent.putExtra("challenge", challenge);
intent.putExtra("purpose", "some-unique-purpose-identifier"); // optionalstartActivityForResult(intent, CHALLENGE_RESPONSE_REQUEST_CODE);
}public void onActivityResult(final int requestCode, final int resultCode, final Intent data) {
if(requestCode == CHALLENGE_RESPONSE_REQUEST_CODE && resultCode == RESULT_OK) {
final byte[] response = data.getByteArrayExtra("response");
// ...
}
}
```## Apps that integrate ykDroid
* [Keepass2Android](https://play.google.com/store/apps/details?id=keepass2android.keepass2android) - Password manager
app compatible with KeePass
* [ykpass](https://github.com/noliran/ykpass) - Password app that derives passwords directly from the YubiKey's response value## Contributing
PRs welcome! I am open for adding more YubiKey functionality, but bugfixes and additional translations are also very
appreciated :-)## Bugs & issues
Please use the GitHub issue tracker for reporting bugs and feature requests.## Notice
Yubico and YubiKey are registered trademarks of Yubico. Google Play and the Google Play logo are trademarks of Google LLC.