yashsingh1/xdaforums huggingface dataset:
[One (M7) Themes and Apps] Aleksandras:
I used the one from this link - http://xdaforums.com/showpost.php?p=51370122&postcount=230. Just check version of it - it should be 8.xxx. You can check version by trying to install apk from your file manager - it won't install, but you can see version here.

The correct location for Mail.apk is - /system/priv-app. I installed it manually, without any flashable zips. To do it - you just need file manager, which can work with root (ES File Explorer should work well).

Go to mentioned folder, remove existing Mail.apk (you can copy it somewhere for backup as well), then copy downloaded Mail.apk, check permissions on it - they should be rw-r--r--. Reboot your device after that.

What ROM are you on? The ROM which works for me with that approach - is ARHD 70.0, so I cannot gurantee it will work with any other ROM.
[One (M7) Themes and Apps] dinoc:
Yes I did that too, used Root Explorer to copy it there, removed the .odex file, reboot the phone but it keeps asking for security.

I'm using the stock rom + root
[One (M7) Themes and Apps] Aleksandras:
Did you try to delete the existing one before copying new one? Overwriting may not work.

If it's not the case - then probably it might be because of different ROM. As I remember there were cases, when Mail.apk was named differently in different ROMs.
[One (M7) Themes and Apps] dinoc:
I've tried that too, the Mail.apk I'm copying there has like 5 Mb and the original one like 3.5 Mb and after each reboot the original with 3.5 Mb and the odex file are restored in /system /priv-app/

Maybe the apk file I have is not good.

After copy and before reboot

After reboot
[One (M7) Themes and Apps] Aleksandras:
Sorry, I'm not fully aware about all the background how ROMs are working and what could restore the original apk file. Maybe there is something because of odexed/deodexed ROMs. Perhaps someone else can explain that.

One more point - did you delete all existing Exchange accounts? Since it can prevent completely deleting the app, because it will be running in background. Try delete Mail.apk file and before copying the new one - recheck if it was really deleted, you can try even reboot the phone before copying the new one.

Another suggestion - you can try replacing the file in a recovery. It's more reliable, because you will be sure no apps are running.
[One (M7) Themes and Apps] dinoc:
Has anyone a working apk for the latest stock rom?
[One (M7) Themes and Apps] sephstyler:
Please excuse my ignorance, but does this work on the M8? or just the M7?

thanks in advance
[One (M7) Themes and Apps] Wotta:
W00dstock, the file (http://w00dstock.alex.pl.ua/mail_exchange_off.zip ) seems to have been taken down. Is there a current one? Thanks.

(I'm running a rooted AT&T M8.)
[One (M7) Themes and Apps] w00dstock:
I've reuploaded the latest apk from 4.4.3 base.

Try it.
[One (M7) Themes and Apps] furious78:
Hey w00dstock, any chance you have the older version from 4.4.2? I'm on Verizon with no 4.4.3 love. I had your old file saved to my phone but lost it with a warranty replacement. This new version is not working for me. Thanks!
[One (M7) Themes and Apps] ankanb:
This one doesn't work for me either - account adding fails at the last step. Any chance you can re-upload the one from 4.4.2?
[One (M7) Themes and Apps] worm9110:
w00dstock, thanks this worked great when I updated to Venon ViperOne 2.5.0.

http://xdaforums.com/showpost.php?p=55674225&postcount=12677
[One (M7) Themes and Apps] w00dstock:
Try this one.

http://xdaforums.com/showpost.php?p=54945498&postcount=373

Hope it helps, because I can't seem to find it on my hard drive.
[One (M7) Themes and Apps] felix2000:
I've just tried it and got the pin enforced. Running HTC One M8 / Stock 4.4.3 / Sense 6 / Rooted / S-ON

Did a factory reset.

I downloaded the lasted mail_exchange_off.zip (MD5: eb9a70fcf6210bc8bbd52c8e242e37bf)

Copied to device, rebooting into recovery TWRP and INSTALL the mail_exchange_off.zip file.

When the system boots I check the mail.apk in /system/priv-app/ to make sure it matches what was in the zip file (MD5: 685d879ef98c0d6bf8a61dc57f1cbe8a)

When I added my exchange account I still get prompted to add the PIN lock.

Is there something I missed?

Thanks for the help
[One (M7) Themes and Apps] Paitor:
Hi, can someone give me the original mail apk and odex file for 4.4.2. I am trying to install an OTA that gives error on mail.odex. My backup got deleted by accident. :(

Edit: No need I extracted it from this TWRP backup http://xdaforums.com/showpost.php?p=53380257&postcount=784
[One (M7) Themes and Apps] evanl81:
I understand how this mod works on the device side, but still unclear what kind of visibility there is from the server side. I work remotely, a few thousand miles away from my employer, on my own device with no security software and no vpn. Is there any way for them to detect this modification? And what happens if they do go to try to wipe my device remotely?
[One (M7) Themes and Apps] EnDeD24:
Lollipop sense 6 Mail version

Is there a new version of the mail app in the Lollipop Sense 6 update? Does the 4.4 version w/o Exchange Security work still?

Thanks
[One (M7) Themes and Apps] w00dstock:
Here's the one for M7/M8 Lollipop Roms

http://w00dstock.alex.pl.ua/mail_exchange_off_L.zip
[One (M7) Themes and Apps] Wotta:
The Lyapota mod gets you there.
[One (M7) Themes and Apps] chreguh:
Does not work for me on M7 Lollipop, I still have to use pin code with exchange.
[One (M7) Themes and Apps] w00dstock:
Did you flash it over set up mail account? If so, you have to delete one, flash zip and add account again.
[One (M7) Themes and Apps] chreguh:
That's how i did it. I am on ARHD 91.1, Lollipop 5.0.2. Sense 6. Is this mod for the Google Edition or for Sense?
[One (M7) Themes and Apps] chreguh:
Deleted
[One (M7) Themes and Apps] chrishull85:
Hello, any update on a lolipop version of this? ive got ARHD 91 installed but cant get any of these working.
[One (M7) Themes and Apps] haran_rulez:
[MENTION=4343792]w00dstock[/MENTION]

I just tried the MOD with Viper 8, unfortunately the Exchange is still asking me for Pin and moreover the device has to be encrypted per my corporate rules... Hate doing that.. Is there a way that this Mod can work in Viper 8? Cheers!!!
[One (M7) Themes and Apps] Paitor:
Worked like a charm.
[One (M7) Themes and Apps] Syquel:
The problem on ARHD 91.1 is, that the path in the ZIP file is "/sytem/priv-app/mail/Mail.apk", but actually the right path would be "/system/priv-app/Mail/Mail.apk".

I attached the flashable ZIP with fixed path.

Flash ZIP in Recovery

Reboot (No wiping necessary)

Delete existing Exchange Accounts

Add your Exchange Accounts again
[One (M7) Themes and Apps] drjat:
MD5

What is the md5 for this zip please? (I am still on 4.4.4)
[One (M7) Themes and Apps] drjat:
[MENTION=4343792]w00dstock[/MENTION] md5 for this file please.

I am looking for a flashable zip which would work on lollipop with sense 7......is this the correct file?
[One (M7) Themes and Apps] Paitor:
Any fix for this?
[One (M7) Themes and Apps] dushyant87:
Can I flash this on the AT&T HTC One?
[One (M7) Themes and Apps] 3bs11:
Can I use this on CM?
[One (M7) Themes and Apps] cschmitt:
Yes

No
[One (M7) Themes and Apps] 3bs11:
Sorry to ask you this but are you aware if there's a version compatible with the One on CM yet? Can I use the one I use for my Nexus 4?
[One (M7) Themes and Apps] cschmitt:
The version in this thread only works on stock (or stock based) HTC One ROMs.

There are a number of threads / apks that will work on any CM 10.1 ROMs, I'd suggest using the script in this thread to modify the Email.apk on CM.
[One (M7) Themes and Apps] madcap24:
Hey man - download links appear to be dead?
[One (M7) Themes and Apps] rocketpaul:
would be great if we could get this updated to 4.2.2
[One (M7) Themes and Apps] Tweezydak1d:
Def need this on new 4.2.2
[One (M7) Themes and Apps] cschmitt:
Will update it when 4.2.2 stock is released.
[One (M7) Themes and Apps] paalkr:
Thanks. Isn't this the stock WWE edition?

http://xdaforums.com/showthread.php?t=2224752
[One (M7) Themes and Apps] trant01:
What's new in the 4.2.2 compared to this one?
[One (M7) Themes and Apps] Syn Ack:
Yes. And please update!

If you guys want to while we're waiting, this 4.2.2 email works perfectly on my TrickDroid 4.2.2. It's inverted themed stock 4.2.2 email app without the exchange security. So far so good on my phone.

http://xdaforums.com/showthread.php?t=2291151
[One (M7) Themes and Apps] cschmitt:
Here's an updated flashable zip of the HTC Mail client from the 4.2.2 (2.17.401.1) leak with exchange security disabled.

HTCOne-Mail-4.2.2-nosec-flashable.zip

I need a guinea pig to flash and test, as I'm currently on CM. If all is well I'll update the OP. Remember to delete the exchange account and remove any existing Email device administrator, then reboot recovery, flash, boot, and setup exchange account again.
[One (M7) Themes and Apps] miisterlim:
Just flashed on ARHD v10 and all seems to be working so far.
[One (M7) Themes and Apps] h9290:
If this can be done on CM, i'd worship you!

The only thing i miss from Sense is the email client, no way to have it running on CM 10.1?
[One (M7) Themes and Apps] bugsy:
This is great. Now if HTC would just enable an option to download pictures by default it would be perfect. Drives me nuts having to hit that link all the time.
[One (M7) Themes and Apps] trant01:
What's the version number on the mail app?
[One (M7) Themes and Apps] old_benj:
Flashed over ARHD 10.1

Failed to create account etc :(

Please suggest.
[One (M7) Themes and Apps] cschmitt:
Need to see a logcat.
[One (M7) Themes and Apps] old_benj:
How to get it? I will post then.
[One (M7) Themes and Apps] cschmitt:
http://xdaforums.com/showthread.php?t=1726238
[One (M7) Themes and Apps] old_benj:
Here it is...
[One (M7) Themes and Apps] cschmitt:
Says unauthorized, bad password, etc.?

06-10 18:08:27.680 W/System.err(10065): com.htc.android.mail.eassvc.core.SyncException: Unauthorized
[One (M7) Themes and Apps] old_benj:
All the checks were passed by, just at the very end it is happened, strange.

Google account. m.google.com

e-mail as a username, password is right, as it works with Play Market and Gmail client... I am lost...
[One (M7) Themes and Apps] denisesballs:
tiobot note

Does this remove remote wipe ability too?
[One (M7) Themes and Apps] sbihue:
Perfect :good:... Works fine on buds TMOUS HTC One (M7 Stock Rooted 1.27.531.7 GSM Odex & DeOdex)
[One (M7) Themes and Apps] nottsuke:
It's not worked with my phone since I changed to Luna ROM.

Could you please advise me to solve my fault?
[One (M7) Themes and Apps] sephstyler:
Hey guys

Not working on my ARHD v11.

Flashed the zip right after installing ARHD (clean install), and policy still got activated. rebooted into recovery again and re-installed again, reboot, no change.

ideas?

thanks
[One (M7) Themes and Apps] cschmitt:
By active do you mean that email is enforcing the policy or simply that it appears in the Device Administrators?
[One (M7) Themes and Apps] sephstyler:
Both.

It is enforcing the policy.
[One (M7) Themes and Apps] kungpu:
Yep, same for me.
[One (M7) Themes and Apps] cschmitt:
It's not working with ARHD because the rom dev renamed the original Mail+nonprime.apk to Mail.apk, and this flashable zip isn't overwriting it. You'll need to go in and manually delete /system/app/Mail.apk then reboot so that only Mail+nonprime.apk remains.
[One (M7) Themes and Apps] dellsuperman:
Hi, I did all the steps as shown but I am still required to activate the security pin after setting up the account.

If I try to skip that step, they will not download my mails.

Thank you!

-JonK

**Edit: I just saw the earlier mail about the ARHD & I managed to get mine to work.

Thanks a bunch!

---------- Post added at 09:43 PM ---------- Previous post was at 09:28 PM ----------

Sorry for asking another noob-ish question.

I restarted my phone & the security came back.

Any one experienced this issue?
[One (M7) Themes and Apps] kungpu:
So I deleted the other mail.apk and got rid of the security, bit now I can't receive pish notifications.. Is that normal with this mod?
[One (M7) Themes and Apps] hsclater:
Can't get this to work using Google play edition 4.2.2 ROM. Says fails to create account. Any ideas?
[One (M7) Themes and Apps] Huey85:
Yeah, would be great if we could get this working with the GE ROMs released. Dashclock widget extension would be awesome. Can't use it when we're enforced to provide a PIN/Password to unlock the lockscreen.
[One (M7) Themes and Apps] hsclater:
Got the inverted one working on GE http://xdaforums.com/showthread.php?t=2291151

Same problem initially but set up using email app instead of settings/accounts/active sync and it works perfectly. I suspect this one would have worked too if I had done it that way.
[One (M7) Themes and Apps] ranova:
you cant add exchange gmail anymore on any new devices you didnt register with google prior to google shutting it down.

You have to use imap now if you are not using the gmail app.
[One (M7) Themes and Apps] old_benj:
I have been registered with gmail long ago and my Desire still allow me to sync with exchange, but One is.not.
[One (M7) Themes and Apps] ranova:
yeah exactly, new devices will not work if they were not registered initially when it wasnt restricted. It sucks, I want to use the Mail app more than the Gmail app also
[One (M7) Themes and Apps] old_benj:
Really? How do you know that? Is there any link? Could you please provide me with, please...
[One (M7) Themes and Apps] ranova:
http://www.imore.com/google-droppin...nnection-go-through-their-shoddy-imap-service
[One (M7) Themes and Apps] subhumanderelict:
I assume the 4.1.2 version would also work for the Sprint model?

I would like to know this for sure as well since it wasn't explicitly stated.
[One (M7) Themes and Apps] cschmitt:
It removes all security policies, such as device encryption, pin requirement, lock screen timeout, etc., but it does not remove the ability to remotely wipe the device.
[One (M7) Themes and Apps] subhumanderelict:
Thanks for the reply. Do you have any plans to release an .apk with remote wipe disabled? Can the Exchange account be removed from the device without wiping the device in the current version of your modded file?
[One (M7) Themes and Apps] cschmitt:
Yes, the exchange account can be deleted without causing the device to be wiped.

No plans to release a version with remote wipe disabled, but probably isn't difficult to remove.
[One (M7) Themes and Apps] subhumanderelict:
Glad to hear about the account being able to be deleted.

Haha... Shouldn't be too difficult for someone who's adept at writing code, but for someone like me... Ehh...
[One (M7) Themes and Apps] cschmitt:
Here's a version for 4.2.2 with the SyncManager.wipeDeviceData() method rendered inoperative. You'll need to test it by attempting to remotely wipe your device from Outlook Web App, so make a nandroid and copy it off the device so you can restore just in case the mod doesn't work.

Also, once you initiate a remote wipe in Outlook it renders the current device registration invalid, so you'll have to delete the device from Mobile Phones in OWA, then delete the exchange account from the device, and then re-add the exchange account back to the device, which will register an new instance with a different Mobile Device ID with the exchange server.
[One (M7) Themes and Apps] subhumanderelict:
Damn! How'd you manage that so quickly? Would this .apk work with my device since I'm running stock, rooted 4.1.2?
[One (M7) Themes and Apps] cschmitt:
You'll need this one for 4.1.2.
[One (M7) Themes and Apps] subhumanderelict:
If ever you're in Chicago, I owe you a drink!
[One (M7) Themes and Apps] dellsuperman:
This is a repost...

Sorry for asking another noob-ish question.

I restarted my phone & the security came back.

Any one experienced this issue?
[One (M7) Themes and Apps] double_ofour:
FYI: Confirmed working in 2.24 (4.2.2) official update.
[One (M7) Themes and Apps] kirdroid:
Doesn't work with android revolution 11.5...after flashing the mail app keeps force closing and causes the phone to restart. Anyone got it working on android revolution 11.5? Worked perfectly on 11.0.
[One (M7) Themes and Apps] double_ofour:
It's working fine in my end. Just try to Clear Data of the Mail app in Apps settings.
[One (M7) Themes and Apps] kirdroid:
Thanks will try that.
[One (M7) Themes and Apps] zapford:
Quick question, is it possible to have this fake the Device ID (or User Agent) from an Android device to an iPhone? i really need this feature now that Touchdown no longer supports this... :angel:
[One (M7) Themes and Apps] pogo1975:
Hi

Can you make this for Cyanogenmod 10.1 ?
[One (M7) Themes and Apps] cschmitt:
No, because this is the Sense based email app. There are options out there for CM though.

http://xdaforums.com/showthread.php?p=14577188
[One (M7) Themes and Apps] JHK1984:
I flashed this with no issues but I'm still not bypassing the security (have to lock phone with pin etc).

Anyone know possible cause?

---------- Post added at 05:31 PM ---------- Previous post was at 05:29 PM ----------

I'm on 11.5 as well and the mail app works, no issues with restarts, but I'm not bypassing the security though.
[One (M7) Themes and Apps] cschmitt:
Doesn't work because you're not actually running the new apk.

This post explains the issue: here

OP updated with this info, hope that will help others.
[One (M7) Themes and Apps] JHK1984:
Thanks for the kind reply.

Edit: Ok.. I followed the instruction and removed Mail.apk using a root explorer, then rebooted, and it's just causing FC of mail app. So I reflashed this zip to make sure and it's still FC-ing. I had to freeze the app in TiBu...
[One (M7) Themes and Apps] Grooby97:
sames here...ended up reflashing ARHD 11.5 again.
[One (M7) Themes and Apps] JHK1984:
I am wayyy too lazy to reflash the rom... if someone can zip the Mail.apk app and pm me... that'd be greatly appreciated...
[One (M7) Themes and Apps] cschmitt:
This mail apk is from the older 2.17.401.1 base, which is probably the issue.
[One (M7) Themes and Apps] ranova:
I flashed this mod right after installing ARHD 12.0, used the recovery file manager, deleted the 12.0 mail.apk and renamed the one installed here to mail.apk, it works great. (im using the apk from 4.1.2)

Any plans to edit the latest mail in the latest base?
[One (M7) Themes and Apps] dinoc:
I installed the Mail.apk for 4.2.2 but is not working, is FC.

I'm using the stock 4.2.2 (2.24.401.1)

Can someone please send me the Mail.apk from stock 4.2.2?

[LE] I've managed to extract the original Mail apk files from my CWM backup.

I'm attaching it just in case someone needs it .

If is possible to make from these a custom Mail apk without Exchange policy (like in the OP) please do! :)
[One (M7) Themes and Apps] nuts77:
is there any plan to make a mail.apk without security for 2.24 base? It would be awesome!
[One (M7) Themes and Apps] aerodan:
Are the devs decompiling the original apk and using assembler to make these mods? I have the whole HTC platform along with extracted libs but if there's actual java code extracted from the jars and jdktool/dex2jar it'll save a lot of time.
[One (M7) Themes and Apps] ranova:
while we wait for a modded apk for the 2.24 base, use the 4.1 mail modded apk, it works fine
[One (M7) Themes and Apps] aerodan:
The mail app works, but the exchange permission fix unfortunately doesn't - at least, not for me.

AD
[One (M7) Themes and Apps] cschmitt:
I've used apktool to decompiled/edit/recompiled the apk.

I won't have access to my dev computer for the next week, but if someone else wants to take a crack at it, here's the mod instructions that I followed:

[MOD][APP]Exchange Security Disabled - JB, ICS AOSP, Sense 3.6, 4.0 & 4.5 -WITH HOWTO

The edited smali files (ProvisionUtil.smali and SyncManager.smali) from the 4.1.2 version are attached. There are a total of 8 edits in all, just search for the comment '# hack' to locate my edits in the smali.
[One (M7) Themes and Apps] aerodan:
Fantastic, thanks cschmitt.

AD
[One (M7) Themes and Apps] Sherry Peng:
I can't use my google account

Hello,friends

I have got trouble.I have bought one HTC One 802t IN China. Everything is fine. But my google account doesn't working. When i log in,it always stop me. You can see the pictures.I am going to travel. I don't know how to do that.Could you please help me?
[One (M7) Themes and Apps] dinoc:
Guys if you manged to hack this please post it here.
[One (M7) Themes and Apps] dexmix:
Thanks for posting this! Has anyone had any luck with this and ARHD 12?

Wish i would have done this before I decided to encrypt my device. Non-stock recovery + encrypted memory = completely locked down device. I can't even flash a backup because the custom recovery doesn't know how to decrypt the memory. Now I have to 1) re-lock my boot loader 2) revert to stock via RUU, 3) re-unlock bootloader 4) reflash custom recovery 5) re-root and reflash ARHD, and then flash this. What a drag...
[One (M7) Themes and Apps] nuts77:
Been trying but haven't managed to make the mod work so far. Think I'm gonna give up and leave it to someone more experienced!

Hope something comes soon cause I'm too lazy to flash ARHD 11.0 back :)
[One (M7) Themes and Apps] dinoc:
It seem that my attempt to restore the default Mail.apk did not work.

I've opened a new topic here maybe you can help, please.

http://xdaforums.com/showthread.php?t=2357188
[One (M7) Themes and Apps] lucent6408d:
How do i delete the mail.apk file

Hi,

My phone is rooted and its running trickdroid 8.0. I am able to navigate to the /system/app location and see the mail.apk but it wont let me delete it. how can i delete it so i can then rename the other one as you recommend?
[One (M7) Themes and Apps] nuts77:
have you mounted the /system folder with read/write/write access ?

You need to do that in your root explorer before you can edit/rename/delete files.
[One (M7) Themes and Apps] weibskreuz:
I decided to make my own apk from stock Mail, and managed to have it work on ARHD 12 on my HTC One M7 AT&T.

See attached for the flashable zip... updater-script modified to prevent UID mismatch issue I experienced with the original zip.

Let me know how it goes :)
[One (M7) Themes and Apps] dinoc:
Can someone make one for the stock 4.2.2 , 2.24.401.1, please?
[One (M7) Themes and Apps] nuts77:
Downloading and testing :)
[One (M7) Themes and Apps] je.aruachan:
Working for me!!! Thank you!!! :good:
[One (M7) Themes and Apps] ickedmel:
Just out of curiosity do you think this would work on the DNA sense 5 Rom ?
[One (M7) Themes and Apps] ranova:
Awesome, Thanks! 4.1.2 mail is version 6.0.565089, this one is 6.2.618969; is it based off 2.24's mail?
[One (M7) Themes and Apps] lucent6408d:
Exchange app & Hi-Pri notifications

Guys,

is there a way to add hi-pri notification to the exchange app? I thing that is the main thing that is missing for me specially since I really need to use it for my corp email that usually comes with a lot of hi-pri emails
[One (M7) Themes and Apps] weibskreuz:
Yes it is. Sorry for not disclosing that.
[One (M7) Themes and Apps] dinoc:
Is this compatible with the stock 4.2.2 or only with ARHD?
[One (M7) Themes and Apps] trant01:
Worked perfectly on ARHD 12.0 on 2.24 base!! Thanks for the mod. Rock on!
[One (M7) Themes and Apps] aerodan:
FC's on stock GE after setting up any service for me (Gmail etc...)
[One (M7) Themes and Apps] weibskreuz:
I don't think so as it uses some sense stuff
[One (M7) Themes and Apps] ppdd:
This worked for me for a week on the GE stock ROM: http://xdaforums.com/showthread.php?t=2244337

Then on Saturday it suddenly stopped working. Not sure why. Reverting to an older nandroid backup didn't make it magically start working.

Frustrating.
[One (M7) Themes and Apps] hkalltheway:
Hi guys,

Is there a way that an IT administrator can find out if I am bypassing the security policy, other than someone ratting out in me?
[One (M7) Themes and Apps] hkalltheway:
No one?
[One (M7) Themes and Apps] dinoc:
I think you are safe they won't know, unless you work for NSA or something similar, in this case they already know your intentions :)