nfc - Is it possible to send APDUs to an HCE service from Android userland? -


i apologize in advance if question sounds stupid, i'm not developer , answer might obvious (but not me @ least…).

i'm interested in possibilities of relatively new host card emulation introduced in android kit-kat.

with former secure-element-based nfc applications, possible exchange apdus applet hosted in se either through nfc controller or "contact" interface (the socket between chip , phone).

the latter enables communication between se , application running in android userland (which can act proxy remote server). authorization application communicate applet granted based on kind of hash of application had "injected" beforehand in se — far know security mechanism part of global platform specifications.

i have doubt regarding similar possibility hce since read this section in google documentation:

the hce architecture provides 1 core piece of security: because service protected bind_nfc_service system permission, os can bind , communicate service.

it makes me think it's not possible userland application exchange apdus hce service — can occurs "the outside" via nfc controller. in case i'm wrong, how , there security mechanism control userland application can communicate hce service ?

i'm asking theses questions because want know whether it's possible develop android application capable of showing content of card emulated via hce , initiating transactions between remote server (which acts nfc reader) , hce service.

thanks time!

it makes me think it's not possible userland application exchange apdus hce service — can occurs "the outside" via nfc controller.

this in general true. there no mechanism allows application talk hce service. however, because there no mechanism doesn't mean impossible build one, assumed have control on hce service , application.

in case i'm wrong, how , there security mechanism control userland application can communicate hce service?

there multiple options. pick simple one, take @ unix domain sockets android.net.localsocket. can use mechanism build communication channel between applications , hce service. works more or less socket communication between applications , internet, communication restricted local device. getpeercredentials member function of localsocket allows check tries connect based on group, process , user-id.


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

android - Associate same looper with different threads -

visual studio 2010 - Connect to informix database windows form application -