yashsingh1/xdaforums huggingface dataset:
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
Anyone get Android Pay and Custom ROM working on their rooted and customized Nexus 5 ?

Here are the steps I took in order to add cards and get Android Pay functioning on my phone:

- Get the Google Pay APK from here: http://www.apkmirror.com/apk/google-inc/android-pay/android-pay-1-0-102576552-android-apk-download/

- You'll also need an upgrade for Google Play Services, I was not able to get it through Apple Pay, I had to get it from here:

http://www.apkmirror.com/apk/google-inc/google-play-services/google-play-services-8-1-14-2244331-238-android-apk-download/

NOTE: have to install Google Play Services that ends in 238 for the N5

Then do the following steps:

- Install Android Pay

- Install Google Play Services

- Clear Data for Android Pay

- Go into SuperSU and unroot

- setup Android Pay

- re-root using SuperSU

So this allowed me to add/manage cards in Android Pay - but some users are getting an error such as:

"MASTERCARD-XXXX can't be used with Android Pay right now " when trying to pay with their phone.

The other item I noted is that after verifying my credit card with the issuing bank - it took several hours (>8) before I received official confirmation that the card was made available for mobile payment.

I'm guessing that it may take a while before the cards are 'activated for mobile payment?

Anyone able to use Android Pay to make a payment on their N5 (rooted, Custom ROM) ?

Note: I'm running on Cataclysm and HellsCore Kernel.
[Nexus 5 Q&A, Help & Troubleshooting] WillJitsu:
I just received email confirmation from my bank that my card had been added. I did receive verbal confirmation the day I added it, but maybe it takes a few days. The problem now is that I had removed my card and re-added it this morning, before that initial email confirmation came through. Now I don't know if I need to wait for another email confirmation before trying again.
[Nexus 5 Q&A, Help & Troubleshooting] Empty Hand:
The process worked for me, but I haven't yet tried to make a payment. One note on the steps (although this is probably understood by most who would be going through the process): For re-rooting SuperSU, you may want to clarify this is done by re-installing SuperSU in recovery.
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
All I did was turn back on "Enable Superuser" in SuperSU Free - I did not re-install SuperSu in recovery...
[Nexus 5 Q&A, Help & Troubleshooting] Joshmccullough:
I'm getting that those links are broken/don't work.......

EDIT: I've had the 'Unfortunately, Google Play services has stopped' constantly with any iteration of the Google Play Services update I've downloaded. I just dl'd the 'universal' version 240 from the XDA Developers posting , everything else has worked fine but I'm still getting the service stop error. Anyone have any suggestions on how to get this message to stop? When I go to Manage Apps, there's no option to clear data/uninstall updates, only clear cache and disable (and I don't want to disable it, for sure.)
[Nexus 5 Q&A, Help & Troubleshooting] silvertrain78:
What device?

Nexus 5 requires either Play services -230 or -238, not -240
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
I fixed the links - but if they fail again - just goto http://www.apkmirror.com/ and find the latest android pay and latest google play services (ending in 238) apks - and use those.
[Nexus 5 Q&A, Help & Troubleshooting] Citizen_Snips:
Pure Nexus Project, tried the steps in OP as well as trying exposed modules to hide root. I also tried using bootunlocker to lock the BL and change the tamper flag to stock. Still no luck.
[Nexus 5 Q&A, Help & Troubleshooting] silvertrain78:
Supposedly this Xposed module goes the extra mile, and addresses the real obstacle to Android Pay activation: the new SafetyNet API

http://repo.xposed.info/module/com.pyler.nodevicecheck
[Nexus 5 Q&A, Help & Troubleshooting] Joshmccullough:
Yeah, Nexus 5. I'll have to try 230, nothing else has worked so far. 240 was supposed to be a 'universal' GPServices.....I see a commenter above posted something about a new Xposed module, maybe have to give that a shot, too.

EDIT: Looks like v.238 was the trick, no Google Play Services errors so far. Now I just have to test out Android Pay somewhere.

Does anyone know if you have to somehow choose between Android Pay and Google Wallet when using NFC payment at a terminal?
[Nexus 5 Q&A, Help & Troubleshooting] silvertrain78:
Glad you got it set. FYI, for Nexus 5 the -230 Play services is universal DPI.

I'm pretty sure at the pos terminal you'll only be able to use Android Pay. It has completely assumed all duties of the old Wallet. If you have a Google Wallet physical card you can add it as an option for Pay, but otherwise Wallet is now just for p2p transactions (like PayPal).
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
Has any one been able to get Android pay to work at a pos?
[Nexus 5 Q&A, Help & Troubleshooting] Citizen_Snips:
Sadly, this still doesn't work.
[Nexus 5 Q&A, Help & Troubleshooting] Joshmccullough:
Yeah, Nexus 5. Got it fixed and working as noted above, just needed the right Google Play Services update and then the instructions in the OP worked like a charm.

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

I just noticed that the old Google Wallet app was auto-removed at some point from my phone (I had both for a while), now I've just got Android Pay and Google Wallet, so that makes complete sense.

FWIW, when I tried adding my Google Wallet card to Android Pay, I initially got the 'you can't use this on your phone'/root error; just unrooted through SU, added the card, re-rooted, no message. I just have to test it out on a POS terminal somewhere and see how it flies.
[Nexus 5 Q&A, Help & Troubleshooting] silvertrain78:
What ROM are you using?
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
Not working at POS

Finally had an opportunity to use Android Pay at a Whole Foods POS.

Touched my phone to the card reader - and Android Pay popped up - with my default credit card.

Then - I got the dreaded: "Visa-xxxx can't work with Android Pay right now" message.

Seems this is a common issue - so it looks like we'll have to wait a bit for this to work.

I'll continue to try it at places that accept Android Pay - and will update accordingly.

NOTE: one thing was apparent... for me the experience of using my phone to pay - is no better an experience (probably more clunky) - than merely swiping my credit card - which I can probably get out of my pocket and swipe, faster than getting out my phone, unlocking it and positioning it on the reader.

Perhaps the security promises with Android Pay will trump a mag stripe card... but from a user experience standpoint... not that great.
[Nexus 5 Q&A, Help & Troubleshooting] Joshmccullough:
Cataclysm ROM, most recent version.

---------- Post added at 04:40 PM ---------- Previous post was at 04:37 PM ----------

Are you rooted, hence the 'didn't work' problem, or it's just plain not working right now?

Yeah, I've putzed around with the original Google Wallet/NFC payment a few times and I found the same thing was true: it's about as much hassle, maybe even more, as using a regular credit or debit card. At least with the cards you know they're going to work, barring some major snafu; with Google Wallet/Android Pay, maybe the place you're at doesn't accept it as payment, maybe the card vendor isn't on-board with Android Pay yet, maybe your phone's rooted and it doesn't work to begin with, etc. I like the idea of having multiple cards available to use with Google Pay, so I can choose which one I want to use at any given time, but I think there's also a lot of barriers to making phone-based payment the default method of payment for people.

EDIT: Well, initial swing and a miss; I had my Google Wallet card set as the default card to use with Android Pay, and got a message saying that the Google Wallet card wasn't able to be used with Android Pay at this time. I was at McDonald's for lunch and if there wasn't a big line behind me I'd have taken time to switch cards and try again, but as it was I froze up and just went with a physical card. I didn't get a 'you're using a rooted phone, you hAxx0rZ!!!! Stop trying to overthrow capitalism and steal Bitcoins, anarchist!!!' error message, at least, so that's a good thing.
[Nexus 5 Q&A, Help & Troubleshooting] luigidk:
Doing more research on this - there seems to be strong evidence that Android Pay won't work on a rooted/custom rom phone.

Lots of speculation as to whether it is related to an unlocked bootloader, root, custom rom, or some combination...

Has anyone tried this on vanilla N5 ?
[Nexus 5 Q&A, Help & Troubleshooting] johnwarda3:
I'm using stock and I have play services 238 the latest one and Android pay still says "Google play services have stopped" what do I do?
[Nexus 5 Q&A, Help & Troubleshooting] silvertrain78:
Here's a thought: maybe it's a server-side activation, and that's why it doesn't work for rooted users who temporarily disable superuser when attempting to add a card?

That's the only thing I can think to explain why some users are able to unroot and flip the switch, while others can't
[Nexus 5 Q&A, Help & Troubleshooting] devadvance:
You're spot on. There's a huge regulatory, risk mitigation, and liability conversation that was started literally decades before smartphones came about. For example, fraudulent activity is monitored and covered by the bank issuing the card. However, with EMV in place, if the merchant hasn't done what's required to secure the transaction(s), then they must cover the fraud. There's a whole issue with that coming up in the United States (see: liability shift). I don't know the particulars of Google or Apple's negotiations with the large financial institutions, but I imagine they were subject to the same constraint: make the transactions secure, and the bank holds the risk; leave it insecure, and Google/Apple must take on the risk.

Thus, it seems logical that a rooted devices has been deemed insecure from a financial transaction standpoint by the financial institutions that make them possible in the first place. Again, no way we can know for sure, but your point is very sound.

You've touched on the relationship that people seem to be missing: root access to all but a select few devices is a result of an exploit or other lack of device security. On an Android device, it is a symptom that the device has been compromised. Now, the user may have intentionally compromised the device to gain root specifically to customize it to their specifications, but how the Google's apps and services know that? Since there's no official channel for root to be obtained, that all happened out-of-band, so root may either been a symptom of the user compromising device security, OR it may be a symptom of some other type of compromise.

Our rooted devices do not follow the same model as servers that process the bulk of the world's financial transactions. There are a handful of people that can (typically) access those servers at all, and standard practice is that once they are "turned over to production", no one other than one or two sysadmins has higher level privilege, and those instances are logged and scrutinized. I mentioned this above, but an average user having root access on a production server is treated the same as a rooted device: a symptom of security being compromised, be it intentionally by the user, or not.

If you're comparing development servers and rooted Android devices, that's a fair comparison. But Google and the financial institutions aren't looking at Android devices as development devices; they consider them to be be production-level. I mentioned it a few paragraphs up, but if the devices aren't treated that way, then either Google or you would be liable for fraud. Perhaps that's the wrong risk and liability management approach? 100% agreed! However, that's how it's currently done in the financial sector.

I also agree that it might be a flawed permission model. Again, I like the idea of more fine-grained privilege to, say, remove a preinstalled app.
[Nexus 5 Q&A, Help & Troubleshooting] blunden:
No, you misunderstood me. Even when you get that popup and allow the root request only once, that app can perform whatever it wants (all covered within that one tap on Allow), including remounting /system writable and modify your OS without your knowledge. The only protection against that is currently to only install apps from developers you trust, there is no technical protection against it.

The "allow apps from unknow sources" still limit the apps to whatever permissions Android provides unless they bundle a root exploit and use that to gain more privileges. That would not trigger the root prompt as it would not use the built-in su binary.
[Nexus 5 Q&A, Help & Troubleshooting] crl775m:
I'll throw my thanks in with the others that you're willing to engage everyone here in dialog. I'm just an Android end-user that finds the discussions going on at this site enlightening for the most part. In another life I was an x86 C/assembly systems programmer so the concepts do not escape me.

Do you know, off-hand, how often fraudulent charges and/or information breaches occurred on rooted devices for people using google wallet for tap-and-pay for the past couple of years?

---------- Post added at 09:15 PM ---------- Previous post was at 08:52 PM ----------

#3 - I think you're right, and I'm content to forego the use of AP on my wife's Jiayu S3. However, why can't Google throw us a bone and restore the virtualized card tap and pay functionality to wallet and let us choose which tap and pay app we'd like to use. It worked fine for years for rooted people, and it would keep a small but vocal group of Android users happy.
[Nexus 5 Q&A, Help & Troubleshooting] AndroidDeveloperLB:
Well, there is a very simple solution for this: make rooting legit, and put the extra security measures even on a rooted device, so that everything that's related to money will be more protected than everything else on the OS, and that root access won't help there.

I've requested to make rooting legit in the past (yet for different reasons):

https://code.google.com/p/android-developer-preview/issues/detail?id=1514

which moved to :

http://code.google.com/p/android/issues/detail?id=174221

Please re-consider this.

It will be so great to have rooting built in. Of course, activating it shouldn't be that easy for every simple user...

This will be a huge step for openness , and actually better security .

Another possible thing is to let Google control the transactions, just as done by buying stuff from the Play Store (which is available even for rooted devices). So, here somehow Google will be the one to handle the money, and not the bank. Somehow Google overcame this when taking money from credit cards when using a rooted device, but here the banks don't trust such devices.

If this is possible, I hope it will be free for all (banks, customers and shop owners).

BTW, do bank apps work on rooted devices? If so, this means something is really weird...
[Nexus 5 Q&A, Help & Troubleshooting] blunden:
Root access by definition isn't secure in this context. Making it officially supported doesn't change that. In essence, it defeats the whole security model.

Banking apps are completely unrelated to this. They do not need to store any sensitive data, unlike Android Pay (apparently).
[Nexus 5 Q&A, Help & Troubleshooting] uudruid74:
Are you saying that the signature check is done every time an APK is opened and not just when it's installed? That would be horribly slow and a custom ROM would STILL bypass that since the OS does it, not the application code.

Once you subvert the API, you don't bother asking the server anything at all, just return PASSED. I don't know the particulars, but unless the APK downloads signed code from Google EVERY time you use it (not likely or even possible) then you can get around it.

Taglines suck. https://eddon.systems

---------- Post added at 05:35 PM ---------- Previous post was at 05:22 PM ----------

I don't agree. With great power comes great responsibility. Normal people allow apps to do whatever they want and allow stupid kinds of permissions. I use Privacy Guard so I tune the permissions anyway, but its incredibly frequent that the first thing a program does when I start it is access the Internet ... when it doesn't need to, or try to access my Contact database! DEINSTALL! Most people will never know. With root they can change out system libraries and do all sorts of evil.

*I* should have root, but my mom should NOT.

Taglines suck. https://eddon.systems
[Nexus 5 Q&A, Help & Troubleshooting] Robalboa:
got the pay app modded to work on rooted devices . it was a image checking system.

gonna test for a couple days before we release it. MODERATOR EDIT - CONTENT REMOVED lol

you cant stop us we are legion

---------- Post added at 07:03 PM ---------- Previous post was at 06:56 PM ----------

thanks for explaining why it was so important for the security of the new pay and how it blocked all rooted users (half of the android community use a modded or rooted device)

android pay is now modded to disable image checking .MODERATOR EDIT - CONTENT REMOVED

ill post the apk after a few more days of testing but i will confirm works on 13 rooted device perfectly so far.

thanks for your hard work it keeps us on our toes.
[Nexus 5 Q&A, Help & Troubleshooting] Joshmccullough:
The chipped cards aren't ubiquitous in America, at least not yet. I just got a new credit card with one, and there sure aren't credit card readers/machines all over the place that take the chipped cards yet. Well, I can only speak for the lower Southeast Michigan area I live in, but I'd assume we're a good 'slice' of general America when it comes to stuff like that. My dad had to request one special from his bank for an overseas trip he took last month; I guess they're the standard in Europe, but American banks and the like probably figure it's too much money to put out to get it going here, until they're forced to do so.
[Nexus 5 Q&A, Help & Troubleshooting] trickinit:
Nice job! I can't wait to try it out. If you need an additional tester, let me know. I'm not afraid to go to the store and hold the line up ;)
[Nexus 5 Q&A, Help & Troubleshooting] Robalboa:
will be keeping this thread posted.

getting all good reports on the modded pay apk. we are going to remove the market link so it will take away the update notification from the play store and i think we are done.

MODERATOR EDIT - CONTENT REMOVED
[Nexus 5 Q&A, Help & Troubleshooting] Stryke_the_Orc:
Thread has been cleaned, keep it respectful and on topic or this will end as quickly as your ability to use Android Pay did...
[Nexus 5 Q&A, Help & Troubleshooting] steve_w:
So your moderations are entirely to remove disrespectful and off topic content and not to remove anything that might tell the community how to bypass this Google security theatre?
[Nexus 5 Q&A, Help & Troubleshooting] crl775m:
Theatre? Nothing particularly useful was removed from the first post. Just some 12 year old chest thumping.
[Nexus 5 Q&A, Help & Troubleshooting] steve_w:
Security theater is where you pretend you are doing something that makes things more secure but its easily bypassed and doesn't really help. The sort of thing people experience all the time when travelling by air in the USA.

The thing with moderation and removing content is that the audience never really know what was removed, it could easily be something like removing a link to the software that would work around this limitation. I just don't know. So thats why I mention it.
[Nexus 5 Q&A, Help & Troubleshooting] psu90:
Let not forget that Google had to stop using the secure element build into most phones because the carriers blocked apps from using it because they wanted to push their own payment service. That was why we had the Dev hacked version of Wallet prior to the one released for KitKat. If Google could use the secure element of the phones for Android Pay we may not be in this situation.

Somebody will eventually find a work around or Google will realize that rooted phone and custom ROMS are more normal than most people think. Why have an open source OS and publish an ASOP version if you don't expect to have custom ROMS and your new Android Pay won't even work on your own ASOP ROM?
[Nexus 5 Q&A, Help & Troubleshooting] Stryke_the_Orc:
Well, considering I left the post, and in that post the author says he'll release it in a few days, after further testing, I'd assume it's a safe bet I didn't remove links to anything. Next time, try reading the edited posts prior to going gung-ho about any moderation. For future reference,

any questions about moderator actions are best handled via PM.
[Nexus 5 Q&A, Help & Troubleshooting] bobwegle:
One option for a work around could be to install an un-rooted version of the stock rom as a secondary in multi-rom. I was able to add cards, but have not tried to pay using this method yet. Will report back. A pain to have to switch roms to use pay, but maybe better than nothing.
[Nexus 5 Q&A, Help & Troubleshooting] brianK2:
As a security professional of 24 years, I have been frustrated with Google's inability to directly push security updates to all android devices. I can no longer wait for carriers who take months (if ever) to update and I remain vulnerable with a device directly connected to the Internet. I have had to take security into my own hands, and that means root access. For me to even consider an Android phone without root to run Android Pay, it would have to have these system-level security applications/functions built into the OS or downloadable play store applications with functionality enabled through Device Administrator settings:

- Regular and direct (from Google to my device) security patching of vulnerabilities for the real life of a device, which is several years. Most OS's are supported for years to fix security issues. Why is the Android OS unique? Stopping OS support in 18 months is a model for selling more hardware in short cycles, and Google is not in the business of primarily selling hardware. They should focus on software and services. Can you imagine if your laptop OS ran out of support in 18 months and you had to replace the laptop to get security updates and/or a new OS version?

- Titanium-like backup and restore - many app updates break, change, or reduce functionality where backing up and restoring older versions is absolutely required. I have had to revert to an older version so many times that I cringe every time I manually update an app to get a security fix. I also restore just data for an app because some app glitch corrupts or wipes its data. And like many others, I freeze apps/bloatware to stop background tasks from leaking data, killing my battery, and taking up space.

- True firewall management - user configurable inbound and outbound traffic filtering for power users. You would not believe the amount of traffic my phone's firewall blocks from apps that I would have never suspected as needing a network connection (and one's I'm not even using, but are apparently running in the background anyway calling home all the time when I haven't used the app in days/weeks). Privacy and data leaks are prolific in Android apps, and users just have no clue!

- Content filtering/blocking. Something with more control than Lookout and other security software. Reasonable ad blocking (some sites are 80% ads, 20% content).

If I can't keep root to get tokenized payment options (desperately needed with all the cc breaches), then I have to rethink IOS vs Android, and which one provides better security out of the box without root. That's too bad considering I have 7 Android devices. Root access was a major advantage.
[Nexus 5 Q&A, Help & Troubleshooting] Stryke_the_Orc:
Thread cleaned once again. Keep the discussion on topic and keep it respectful.
[Nexus 5 Q&A, Help & Troubleshooting] GatoL0c0:
Come on people... Please don't let your egos get in the way and ruin it for everyone.