yashsingh1/xdaforums huggingface dataset:
[NFC Hacking] madfish73:
use UltraEdit search in nfc.odex, I believe these files are needed for decompiling stock GN 4.2.1:

/system/framework/core.odex

/system/framework/core-junit.odex

/system/framework/bouncycastle.odex

/system/framework/ext.odex

/system/framework/framework.odex

/system/framework/telephony-common.odex

/system/framework/mms-common.odex

/system/framework/android.policy.odex

/system/framework/services.odex

/system/framework/apache-xml.odex

Exactly same as Nexus4 4.2.2
[NFC Hacking] madfish73:
Try these and tell me the result:

delete Nfc.odex(GN), NfcNci.odex(Nexus4), and overwrite the apk

GN stock 4.2.1 Nfc.apk: View attachment Nfc-mod-combine-GN4.2.1.apk

Nexus4 stock 4.2.2 NfcNci.apk: View attachment NfcNci-mod-combine-N4-4.2.2.apk
[NFC Hacking] LoveNFC:
Great, seems to be working on both! But there are some minor issues, and a problem in just the Nexus 4.

-Could you provide a version that still plays the default notification when a tag is discovered, but plays no sound when the tag is removed?

-In stock Android, there's no way to set AnyTag as the default application to handle etection of a NFC tag. Every time I place either Nexus on a tag, I have to manually tap AnyTag in the 'select action' popup, but there's no option for 'always' or 'just once'.

-This problem is only present in the Nexus 4: Once the phone is placed on a tag and the action is completed, if the screen times out or is turned off, the tag will be lost. On the Galaxy Nexus, the tag remains detected after the screen times out or is turned off, and it just works perfectly.

Thanks!
[NFC Hacking] klau1:
Re: Detecting NFC Tag removal hacking [add video demo & apk !!!]

That's very weird. Have you tried a completely blank NFC tag? Just to make sure there are no preexisting instructions in the tag.

Have you tried uninstalling the other apps on the list so that Anytag becomes the default?
[NFC Hacking] LoveNFC:
Yep, removing other NFC applications works. This is a pretty big compromise, but I suppose it's worth it.

It also seems that removing other NFC applications fixes the issue that I had with the Nexus 4. Everything now seems to work perfectly.

Just need a mod without the tag lost sound, and this will become a permanent mod for me. Thanks!
[NFC Hacking] madfish73:
you can change the taglost.ogg sound file in the Nfc APKs with a mute "taglost.ogg" file, or just download these:

GN421 TaglostMute Nfc Mod: View attachment 1774927

Nexus4 TaglostMute Nfc Mod: View attachment 1774926

enjoy it!
[NFC Hacking] madfish73:
you may also interest with this post:

http://xdaforums.com/showthread.php?t=2169601
[NFC Hacking] klau1:
Re: Detecting NFC Tag removal hacking [add video demo & apk !!!]

Has anyone noticed that the TAG LOST doesn't trigger after the phone has been on standby for a night?

For example, I put my phone on the Night Stand NFC Tag.

TAG FOUND = MUTE

TAG LOST = NORMAL

but in the morning, when I remove the phone from the NFC tag, the phone does not unmute.

Could it be due to deep sleep?

I will try TAG FOUND, by placing the phone on the tag before I turn on the phone tomorrow morning to see if it's just TAG LOST OR BOTH Functions that stops working after a long standby.
[NFC Hacking] madfish73:
My Galaxy Nexus(4.1.2 aokp) is fine. Maybe, there's difference between GS3 and GN. Try not turn to mute, let your phone standby for a night, and test if you can hear the "tag lost sound" or not when you take the phone off the tag next morning.
[NFC Hacking] madfish73:
klau1,try this:

1. install a terminal app, put your phone on the tag at night

2. next morning, take the phone off the tag, run Terminal app

3. type the following cmds and look for if there's a string like "Tag lost, restarting polling loop":

su ---->let you get the super user power

cd /sdcard

logcat -f log.txt ----->log message into a file named log.txt

vi log.txt ----->open the file with vi (or you can use other GUI text editor, and search string "Tag lost")

searching if there's a string like "Tag lost ....."

in vi:

press /

type: Tag lost

press enter

if you can find the string "Tag lost" in the log mesages, that means Nfc tag lost detecting works fine.

further more, you can search the string "action.tag_lost". If you can find that, it means the "tag lost message" has been sent out from the Nfc.apk.
[NFC Hacking] zygmalian:
Not working on Note 2 LTE

Hi

Tried your NFC mod for the Note 2 N7000 4.1.2, but it did not work. Think this is becuase I have the N7105 - the Note 2 LTE version - UK based - not sure why it would be different for NFC.....

I have attached the stock nfc.apk file from my build. Happy to test if you wish to apply your modification.

Thanks

Zyg
[NFC Hacking] madfish73:
Well, we need Nfc.odex too.
[NFC Hacking] zygmalian:
N7105 nfc.apk

Attached:

Renamed .odex to .txt o upload..

Zyg
[NFC Hacking] m3meems:
Hi, I was looking for a nfc mod that lets the note 2 read nfc tags with the screen off. Is the nfc mod in the first post what I need? How do I install it?

Thanks!
[NFC Hacking] klau1:
Something weird is going on,

I checked logcat with CatLog and could not find any instances of the term "tag lost" even the term "lost"

I checked terminal after saving the log file, again, no instances of the term "tag lost" even the term "lost".

I will double check tomorrow.

---------- Post added at 12:51 AM ---------- Previous post was at 12:35 AM ----------

The installation instruction is right on the first post.

Also check http://xdaforums.com/showthread.php?t=2171952 step 2 for more detail
[NFC Hacking] madfish73:
hi klau1, have you checked the TAG FOUND function? some guy has the similar "sleep" problem with stock rom without nfc mod:

http://xdaforums.com/showthread.php?t=2178170
[NFC Hacking] madfish73:
sorry , need more files, copy out /system/framework and upload here
[NFC Hacking] zygmalian:
Hi

The size of the /system/framework folder when zipped is 36MB - the largest file is 29MB, and only zips to 24MB, so I cannot attach, as there is a 11MB limit.

Any other suggestions?

Zyg
[NFC Hacking] m3meems:
Would it be possible to make a mod for the Sprint Galaxy note 2 running 4.1.2? I attached the Nfc.apk and put a link for the framework files. I'm on a deodexed rom so I don't have the nfc.odex. Would it be possible to make the mod only for deodexed roms? Thanks for all the help and let me know if you need anything else!

Link to framework files: https://www.dropbox.com/s/v0gozjauxm6ypj4/framework.zip
[NFC Hacking] madfish73:
upload it to some kind file share site and give me the link :)
[NFC Hacking] hOrnizuka:
Thanks for the tip! Are there any other side effects by disabling "Tags"? Will it render any other functions useless? I gave it a try and it did remove the annoying popup. I like it better than the Xposed module because it didn't have that black box closing animation.
[NFC Hacking] mulderfbi:
Glad i could help ! I never notice any side effects, besides the missing and annoying "Tags" popup :))) Everything is working normal for me.
[NFC Hacking] Cavalier Condorelli:
tasker profile for TAG_EVENT doesn't work

Hi I cannot get NFC NFCLockScreenOffEnabler work with tasker.

I have an LG G2 with stock 4.2.2 rom, Xposed framework installed and NFCLockScreenOffEnabler ver1.9.7.4 enabled.

Tags are correcly recognized even in lock screen with screen off.

I've add them to the Authorized list.

I've created this tasker profile:

Tasker->profiles->add->Event->System->Intent Received->Action=pk.qwerty12.nfclockscreenoffenabler.TAG_EVENT

with the following connected task:

If %uid ~ 04A291DA853280 (my tag id as I found when I have authorized it)

Flash Discovered if %state ~ discovered

Flash Lost if %state ~ lost

Nothing happened, is there somenting wrong?

I'd like to use the ability of lost tag event.

I also try to log cat and I see that lost tag is working: NativeNfcTag Tag lost, restarting polling loop

Thank you.
[NFC Hacking] XlAfbk:
Again someone using the wrong intents, read http://xdaforums.com/showpost.php?p=47213074&postcount=351
[NFC Hacking] Cavalier Condorelli:
I've already read it! And I first tried this intents before the one that I have post.

Probably if AGAIN someone uses the wrong intent is because it isn't very clear what is still valid and what it is not.

These are my first 2 test profiles:

1) Tasker->profiles->add->Event->System->Intent Received->Action=android.nfc.action.TAG_CHANGED

with the following connected task:

If %tag_uuid ~ 04A291DA853280

Flash Discovered if %tag_present ~ true

Flash Lost if %tag_present ~ false

2) Tasker->profiles->add->Event->System->Intent Received->Action=android.nfc.action.TAG_LOST

with the following connected task:

If %tag_uuid ~ 04A291DA853280

Flash Lost

Are these correct?

If they are not could you please give me an exemple?

Thank you
[NFC Hacking] XlAfbk:
I'm using this with Tasker:

Intent Received, Action=android.nfc.action.TAG_CHANGED

Variable Set: %NFCTAGID to %tag_uuid if %tag_present ~ true

Variable Clear: %NFCTAGID if %tag_present ~ false

And then in my tasks I just listen for %NFCTAGID set/cleared
[NFC Hacking] Cavalier Condorelli:
Hi, unfortunately I can't get android.nfc.action.TAG_CHANGED to run, it seems that tasker is unable to recognise this intent at all.

I have made for testing purpose a profile exactly the same of yours (Intent Received, Action=android.nfc.action.TAG_CHANGED) and then I associate to it a task that only make a single vibrate alert (no variable condition). Nothing happened!

I also have Locale NFC tasker plugin installed that works perfectly, but I have also tried to freeze it supposing it was interfering with NFC LockScreenOff Enabler.

(I have an LG G2 with stock 4.2.2 rom, Xposed framework installed and NFCLockScreenOffEnabler ver1.9.7.4 enabled.)

Please I need your help.
[NFC Hacking] XlAfbk:
you are using the one from xposed repo as opposed to the one from this thread? the one from this thread is using different intents.

also try debug setting in the modules options and have a look at the logcat
[NFC Hacking] ascsa:
OK, maybe I´m a little bit biased :p, but why don´t you try NFC ReTag with tag_lost support and Tasker integration... simply put the tag on your phone ... name the tag and add a Tasker task activity ....then release the tag (tag_lost!) name the tag_lost tag and add an other Tasker task activity ...(you can even try the tasker task advanced activity to send the uid to tasker) ...Don´t forget to enable Allow external access in Tasker settings and you should be fine ...
[NFC Hacking] Cavalier Condorelli:
Hi, thank you for your reply, this is the steps I've made:

1) I've installed NFC ReTag, enabled tag lost support inside it's settings

2) Put a tag on the phone and leaving it, after discover insert it's name

3) Add Tasker activity

4) Release the tag.... Nothing happened!! :(

When I put again the tag on the phone tag_discover Tasker activity works well, as before with the other method, but how can I save tag_lost activity to run a different task?
[NFC Hacking] ascsa:
Hmm ReTag tag lost support is active by default, no need for your point 1 .... so, make sure first checkbox in ReTag Tag lost settings is checked (Tag lost support!) and second Checkbox (Don´t add tag lost tags!) is UNCHECKED (you can check it AFTER you have saved your tag_lost activity)....

Releasing a tag should give you a new tag found pop_up with the same id, but "_lost" added ...simply add your activities to this tag ... in the end you should have 2 tag in Retag ---> id: 12345678 and id: 12345678_lost, if the "_lost" id doesn´t fire you have the wrong settings in Retag (see above) OR the NFCLockscreenOff Enabler module is not working correct (--> check within the module settings , if "enabled tag lost message" is checked and make sure you have rebooted your device!)
[NFC Hacking] Cavalier Condorelli:
The following screenshot is NFCLockscreenOff settings, (in ReTag Tag lost settings is checked (Tag lost support!) and second Checkbox is UNCHECKED)

I have rebooted hundreds of times.

I continue to think that NFCLockscreenOff Enabler module is not working correct on my LG G2 :crying:

Does the catlogs I have posted before helps you to understand what is going wrong?

May I give you further information?

Thank you very much for your help!
[NFC Hacking] XlAfbk:
Do you even get the tag lost sound? (make sure it's enabled in the modules settings)
[NFC Hacking] Cavalier Condorelli:
No! I have tried also to check only the tag lost sound in the modules settings but never hear it...
[NFC Hacking] XlAfbk:
then it seems to be incompatible with your phone i'd say (given that the module and xposed are both active)
[NFC Hacking] Cavalier Condorelli:
But what does this logcat meens? Are they generated by this module right?

.................................

02-13 19:47:14.676 D/NativeNfcTag( 1433): Tag lost, restarting polling loop

02-13 19:47:14.676 D/NativeNfcTag( 1433): Stopping background presence check
[NFC Hacking] XlAfbk:
i don't think they're from the xposed module but from the OS
[NFC Hacking] ascsa:
Nope, these logcat messages are generated by standard android ... nothing to do with the module or xposed.
[NFC Hacking] Cavalier Condorelli:
Is there anyone with an LG G2 that can confirm that tag_lost functionality isn't working?

---------- Post added at 06:22 PM ---------- Previous post was at 06:03 PM ----------

Is there a way to detect this OS event in tasker, maybe through logcat?
[NFC Hacking] InfamusOne:
Nfc is incompatible with the LG G2 And the S4 software. There may be others but I have not done much research into it but I know those for sure.
[NFC Hacking] lachyzee:
I've got NFC ReTag Pro, XPosed and NFC LockScreenOff Enabler.

The general purpose of installing all these things was to create a Car Mode that would be activated/deactivated by putting the phone on an NFC tag on my Car Dock.

Just wondering - is there anyway to activate "NFC Lost" detection only selectively rather than having it on all the time (which, I understand, drains some battery). Also having it on all the time means that any time I have my phone near a credit card, and then move it away, the NFC Lost pop up and sound plays...

E.g. Only activate it once an NFC tag is "found", then deactive once it is "lost".

E.g. Only activate it while charging

etc.

Or have I misunderstood things...

Thanks
[NFC Hacking] ascsa:
Hmm, yep perhaps you have misunderstood a few things. I will try to clarify a few points ;)

- Using the "nfc on when screen on" or the "nfc always on feature" in the module will definitely drain more battery, because on stock the nfc service is disable when the screen is off and locked... Personally I prefer the "nfc on when screen on" option because this should minimize the additional battery drain and is from my point of view the most user friendly solution (and btw. this is how nfc worked on stock Gingerbread)

- Putting the phone on a tag (with NFC enabled) will cause additional battery drain while the phone is on the tag, because the phone powers/ polls the tag all the time ...BUT this is the way NFC is designed, nothing to do with the module or ReTag ... your phone (or any other NFC reader) do this even with stock firmware

-The tag lost feature within the module only sends an additional trigger when the tag is lost (+sound), the polling is not related to this. Additional battery drain for sending this message is insignificant.

- NFC ReTag does NOT need a running background service (unlike e.g. Tasker !) to catch this message so no additional battery drain for this.

- Have a look at the ReTag "Tag lost support" settings and check the "don´t add tag lost tags" setting ... this will deactivate the " new tag found" ID 12345678_lost message for unknown tags
[NFC Hacking] soroush12375:
excuse me for ask this question here

i bought a nfc tag but it doesnt work with my nexus7..what i must do?(nexus7 nfc is allright(i test it)and the nfc tag too is work with other devices!)

thank you and sorry for my english
[NFC Hacking] croldan72:
I'm trying to get this to work with Tasker and the NFCLockscreenoffenabler Xposed mode. It sounds like I don't need anything else other than that to get this to work. One thing that I seem to be missing is how to get the Hex string of the tag ID. Would this be the same as the UID for the tag?My UID is 14 characters long, but the sample Hex string you mentioned is on 8.
[NFC Hacking] sap323:
Problem

Hi !

I've trying to solve this in the past few days, but i dont know why i cant do it !

I have already done it, but when i tried something new, i could do it...

I want to do this:

When my Nexus 7, touch a NFC play a trailer, when the tag is lost, go to home screen.

I have done:

In tasker: no profiles

2 tasks:

Open trailer (works perfect when i press play)

Go homescreen (works perfect when i press play)

Also, in NFC retag PRO:

I have added to my tag 123 to order to run the task1 in tasker

and, to the tag 123_LOST, the order to run the task2 in tasker also

but when i try it, it doesnt work... it seems like a problem of external access from tasker, but i have already tried everything:

-unistall tasker, yes it has priviliges, yes im root, yes its on in external access. "Permitir acceso externo está prendido"

-unistall nfc retag after tasker

tick and untick everything in retag

I dont know what else to do !!!

The problem says:

"Error de llamada externa

Fallo al ejecutar tarea de difusión"

Error outcalling

Failed to execute task of dissemination

What should i do ?

Please help :)

Sorry for my bad english

---------- Post added at 01:52 AM ---------- Previous post was at 01:30 AM ----------

OMG !

It was because the name of the task has spaces:

it was: some thing

now: something

and works perfectly !!!

lol, sorry
[NFC Hacking] CZ Eddie:
Folks, I'm kind of confused here.

Note 3 running a rooted TouchWiz.

Is the NFCLockScreenOffEnabler19.apk found in this thread, a modified version of the NFCLockScreenOffEnabler19.apk found in the Xposed respository? Or are they both the exact same file??

And to get NFC 'proximity' working, this is the ONLY file I need to install?

Other than NFC related apps of course?
[NFC Hacking] Magissia:
They should be the same

Regards
[NFC Hacking] nictec:
Razr I + Android 4.1.2

Xposed 2.6.1 Module: NFC LockScreenOffEnabler 1.9.7.7 from repo in relation with tasker

android.nfc.action.TAG_CHANGED works

android.nfc.action.TAG_LOST works

android.nfc.action.TAG_DISCOVERED doesnt work -> is this correct?

Have now the "changed" event working. But this was hard to find out. Everytime we will be forwarded to #341?

Without screenshoot in #388 i would still searching for a solution (Thanks Xalies).

With TAG_DISCOVERED i get never an action triggered in tasker.
[NFC Hacking] abuttino:
Anyone done the NFC.apk mods for the MotoX? I'd like to use this but want ART too.
[NFC Hacking] Ironman1965:
I have a Note 3 N900W8. I'm not familiar with modifying apk's. Would anybody be willing to modify my .apk? These are my files. Not sure if the res file will be needed or not so added it too. Thanks in advance.

View attachment Nfc.apk

View attachment twframework-res.apk
[NFC Hacking] Breathh:
Hi, i know this is probably a long shot but, any chance you can modify a nfc.apk for lg g3?

If you can't I should try to do that but i 'd need some info:

where can i find the nfc.apk and why there are smiles in the code you posted?
[NFC Hacking] OldHairyOne:
Can't get this to work...

I'm running a nexus 5 on CM11. Got the xposed nfclockscreen module, and tried following the instructions with the tasker intent to turn Bluetooth on and off. But it doesn't work. Can anyone help?
[NFC Hacking] theredspecial:
I'd also really like this for my G3, or if someone can explain how I can mod this myself.
[NFC Hacking] elmerohueso:
I've tried this on my N4 (stock 4.4.4), both with modding it myself and using the ones already posted in the OP. All give me the same result; NFC doesn't work and Settings FCs whenever I try to open it. I'm doing the following: remove original APK and ODEX from /system/app, copy new APK to /system/app, chmod to 644 (rw-r--r--), reboot.

Any ideas?
[NFC Hacking] tonysunshine:
anyone try this on a lollipop rom?
[NFC Hacking] Neurom707:
There is no xposed for 5.0 doesnt work with art and will probably never work
[NFC Hacking] elmerohueso:
Which why I'd bet they were referring to modding the actual NFC.apk for a Lollipop ROM (the original discussion in this thread, prior to Xposed). I, too, would like to know if anyone has had success with the NFC mod on Lollipop.
[NFC Hacking] manite:
Seems the LG Volt doesn't work with this either. Set it all up and enabled the module but at lockscreen it is unresponsive to nfc tags.
[NFC Hacking] superflyman:
Hello, do you know how used this trigger with Automagic? I use only Automagic (very simply application), tasker is not intuitive.

I try use trigger "Activity Started", but nothing doing with this.
[NFC Hacking] Etnoy:
Okay, good news. I am running a SM-G900F (Galaxy S5) on Cyanogenmod 12 and am using Xposed alpha2 for Lollipop. I have installed NfcLockScreenEnabler in xposed, and when using the plugin's sound effects I hear the system detecting the presence and removal of the tag. However, I am unable to do anything else. I get an error message similar to the following:

java.lang.NoSuchMethodError: com.android.nfc.VNfcService#checkScreenState()#bestmatch
at de.robv.android.xposed.XposedHelpers.findMethodBestMatch(XposedHelpers.java:233)
at de.robv.android.xposed.XposedHelpers.findMethodBestMatch(XposedHelpers.java:284)
at de.robv.android.xposed.XposedHelpers.callMethod(XposedHelpers.java:947)
at pk.qwerty12.nfclockscreenoffenabler.NFCLockScreenOffEnabler$PresenceCheckWatchdogRunHook.beforeHookedMethod(NFCLockScreenOffEnabler.java:397)
at de.robv.android.xposed.XposedBridge.handleHookedMethod(XposedBridge.java:636)
at com.android.nfc.dhimpl.NativeNfcTag$PresenceCheckWatchdog.run(Native Method)

It all worked great in CM11 (KitKat), here's to hoping there is a quick and easy fix for my problem above :)
[NFC Hacking] XlAfbk:
the fix - as discussed on the last 2-3 pages that you chose to ignore - is to update this module for lollipop
[NFC Hacking] noraef:
Well, it'd sure be nice if this could work on Lollipop. I haven't installed Xposed yet, but Etnoy, you say NFC removal is detected, so what is it that doesn't work? Can't intercept the intent in Tasker?
[NFC Hacking] XlAfbk:
In 5.0 the module didn't enable screenoff-reading. That was fixed by my .apk mod so using mod+xposed you get the full functionality.

In 5.1 the module doesn't work at all, so you only get screenoff-reading from my .apk

See this thread for more up-to-date information: http://xdaforums.com/xposed/modules/mod-nfc-unlocking-based-t2478163
[NFC Hacking] noraef:
[MENTION=2832063]XlAfbk[/MENTION] Thanks a lot: will have to look into that, as I'm still on 5.0.1.
[NFC Hacking] vnwo:
Is it possible to make the NFC mod work in LG G Pro 2?
[NFC Hacking] XlAfbk:
That looks like from Kitkat, for that you shouldn't need any modded apk but just the Xposed module.
[NFC Hacking] MaXi32:
Thanks

Scrolling through #300+ posts and you are the want who provide this solution.. I'm wondering, what happen to the OP? The first post is outdated. Documentation is suck.
[NFC Hacking] jazic:
I can't seem to get this working with my Nex 6. I'm on 5.1.1 (LMY48I).

I have Xposed and other modules working perfectly but this one doesn't want to work...

Any ideas?

Thanks in advance!
[NFC Hacking] XlAfbk:
Just the module doesn't work anymore, you also need a modded nfc.apk. e.g. from http://xdaforums.com/showpost.php?p=59941326&postcount=497 (and related posts)
[NFC Hacking] jazic:
Thanks for the link! I'm giving it a whirl now but I seem to be stuck on step 5. I can't find "classes.dex" in the NfcNci.apk that I pulled off of my Nexus 6.