Tested on Nexus 6 (shamu) and Nexus 5 (hammerhead) with Android 6.0. Should work on all Android versions >=5.0 and also on other devices than Nexus but wasn't tested.
I am not affiliated with the SIM Alliance or Giesecke & Devrient GmbH in any way. I am just an interested Android user who wanted to get NFC payment apps working on the Nexus phones. This is a fork of the SEEK Project with minimal modifications to get it working without patching the Android base framework. Feel free to use this release, but: No warranty, no liability! Use at your own risk!
This release is also available in the form of a Magisk module (tested with Magisk 12.0): https://github.com/johnzweng/magisk-module-omapi-2.05/releases/tag/v1.0
This prebuilt package contains the SmartcardService from this repository in the version 3.2.1 which implements Open Mobile API (OMAPI) version 2.05 (in contrast to this release here which implements OMAPI v3.0). Also it only supports UICC (SIM card), support for other types of Secure Elements (SE) was removed.
OMAPI Version notes:
One word about Open Mobile API (OMAPI) versions:
It depends on the app which you are using (the payment app which you get from your bank) which OMAPI version you will need on your device. The newest one is 3.0 but a lot of apps dont't work with 3.0 yet.
- As speaking of December 2015 all the banking apps in Austria need OMAPI version 2.05: 3Geldbörse, Bank Austria BankCard Mobil, BankCard mobil, HYPO ELBA-pay, Raiffeisen ELBA-pay, Oberbank Bankomatkarte Mobil, ...)
TL;DR: Currently (Dec 2015) most people will need the 2.05 version (this one here)!
getAtr()is not supported (will always return
- this implemtents version 2.05 of OpenMobile API. Apps which rely on other versions will not work with this.
Note: this is NOT a flashable zip (NOT to be flashed by recovery!!) (but feel free to make a flashable zip from this)
You would need to unpack this file manually and copy the content on the system partition of your device. You need to have root permissions and system partition mounted writable (the easiest way is to do this while booted into a custom recovery)
This is how I installed this on my unrooted Nexus 6 running Stock Android 6.0.0:
download TWRP custom recovery image for your device from here: https://twrp.me/devices/
for example I downloaded
twrp-126.96.36.199-shamu.imgfor my Nexus 6
reboot your device into bootloader mode:
adb reboot bootloader
temporarily boot this recovery image (no need to permanently install it):
fastboot boot twrp-188.8.131.52-shamu.img(make sure you use the correct recovery for YOUR device)
in TWRP go to "Mount" and mount "System" (check the checkbox "System")
then unzip this release zip on your computer file and copy the files over to your device like this:
# copy the permissions XML file and set correct file permissions adb push system/etc/permissions/org.simalliance.openmobileapi.xml /system/etc/permissions/ adb shell chmod 644 /system/etc/permissions/org.simalliance.openmobileapi.xml # copy the library jar file and set correct file permissions adb push system/framework/org.simalliance.openmobileapi.jar /system/framework/ adb shell chmod 644 /system/framework/org.simalliance.openmobileapi.jar # copy the SmartcardService APK adb shell mkdir /system/priv-app/SmartcardService adb shell chmod 755 /system/priv-app/SmartcardService adb push system/priv-app/SmartcardService/SmartcardService.apk /system/priv-app/SmartcardService/ adb shell chmod 644 /system/priv-app/SmartcardService/SmartcardService.apk
OPTIONAL: If you are updating from a previous version you must also wipe the dalvik cache, or remove the specific dex files manually:
adb shell rm /data/dalvik-cache/profiles/org.simalliance.openmobileapi.service adb shell rm /data/dalvik-cache/arm/system@email@example.com@classes.dex adb shell rm /data/dalvik-cache/arm/system@priv-app@SmartcardService@SmartcardService.firstname.lastname@example.org
Important: you must reinstall all apps which want to use the OpenMobile API (they won't work if not re-installed)
To make the NFC offhost routing to the UICC (SIM card) working, you might also need to modify the config files for the bcm2079x NFC chipset in your phone. See my other repository for working examples for Nexus 5 and Nexus 6.