Email or username:

Password:

Forgot your password?
Pierre Bourdon

CVE-2023-21036 / acropalypse is absolutely bonkers.

Apparently for 5+ years the cropping / editing tools for screenshots on Google Pixel phones was only overwriting the start of the screenshot PNG file, but not truncating.

All screenshots shared for the past 5+ years might have data recoverable from them. Demo available at acropalypse.app/

Google still hasn't communicated anything on this.

(h/t ItsSimonTime on Musk's site)

102 comments
Pierre Bourdon

I tried it on a screenshot from just a week ago. This is absolutely scary.

First image is the screenshot I saved after cropping. Second is what the demo app managed to recover.

Pierre Bourdon

Another one showing how a smaller crop can end up revealing even more of the original screenshot image.

marnanel

@delroth the people who run that site are going to be receiving an awful lot of other people's sensitive information

Pierre Bourdon

@marnanel it's all client side, nothing gets uploaded. At least in its current version I was using.

:jan:‍:abreath:‍‍🌬:dandelion:

@delroth I've noticed something that might be related. this may explain how they can have the "save vs save as" option when making small changes like a crop or "enhance" photo edits. If you pick save, it doesn't make a new file but must save the image adjustment data in a similar manner. I'm sure digging into a larger data sample size could turn up some more info

Pierre Bourdon

@Crazypedia that's the Google Photos crop tool which I'm pretty sure is different from the screenshot crop tool (and not vulnerable).

Pierre Bourdon

PoC author @retr0id published his writeup about how the bug was found, I strongly encourage you to give it a read and a follow: da.vidbuchanan.co.uk/blog/expl

Émilie Fecteau

@delroth If iOS has a similar bug, I am screwed, lol. But I’ve always thought something like this *might* be possible, so maybe it’s fine.

gudenau

@delroth @retr0id For some reason all of the screenshots I've tried just do this. Any idea why that might be the case? I'm on a Pixel 4 XL.

David Buchanan
@gudenau @delroth Good question, I don't have an easy way to debug, but what happens if you use my python script? (it's linked in the blog post)
Erik Haugen

@delroth Yeah, without being a zlib expert, I think the smaller the crop the more likely the original is recoverable.

S Nielsen

@delroth Wow... that's incredible level of bad.

I'm now sitting here wondering if it's really Pixel specific or not... and if other screenshot solutions suffer from a similar problem, or Google did something very silly...

At least it seems like it has been fixed in the 2023 March update.... for future screenshots (presumably)...

Pierre Bourdon

@simonlbn "future" indeed, since the 2023 March update isn't available publicly for Pixel 6 / 6 Pro at this point.

Yes, despite the fact that Project Zero dropped 5 remotely exploitable vulns for those devices yesterday.

Diego Elio Pettenò

@delroth @simonlbn you know things are bad when I trust my Huawei better than Google's flagship phones.

Pierre Bourdon

@flameeyes @simonlbn at least your data mostly gets leaked to various companies and gov orgs in China, not your stalkers and random people online :-)

(But really, having worked on projects close to Android security in the past - Huawei devices have had some absolutely bonkers backdoors.)

Diego Elio Pettenò

@delroth @simonlbn oh I can believe that, but it's a matter of threat model, as you just noted 😉

S Nielsen

@delroth Ah, I hadn't even considered that might be the case :-(.

The only Android phone I use regularly is my corp phone so I have no idea about the normal release schedules are.

Tom

@delroth I just tried this on some recent things I deliberately cropped to hide certain details and yup, it's certainly leaking information.

The Skeptic's Book of Lists

@delroth So if I crop "thesebooksImselling.png" because I want to get rid of my nasty bare feet in the photo I put on ebay, the cropped version just gets written to the top of the PNG file and but the original data is still present but not normally readable. Interesting!

Tom

@skepticsbookoflists @delroth this exploit is a goldmine for the feet guys.

user of nyomnyom~! :trans:​ (nyomming)

@delroth (to boost)

Karl

@delroth It seems to not work on my pixel 4a. The power of the 3.5mm jack, baby!

Neko May

@delroth Is this specifically Pixel devices only? Or are other devices possibly affected?

Pierre Bourdon

@NekoEd no idea -- another reason why it would be great if Google actually released information...

I've only seen confirmation for Pixel screenshots. However the root cause of the vulnerability is a behavior change in AOSP which could potentially have similar effects for other apps (issuetracker.google.com/issues).

Patrick
@delroth @NekoEd OxygenOS 13's Photos app (OnePlus) does not seem to be vulnerable (even if it was, screenshots on Oxygen are jpg).
ʟ·ɪɴᴀᴅꪮᴩᴛé 🌴

@delroth
I'm not sure to understand. This happens when native Pixel image app is used for cropping/editing?

pcyx

@delroth when you take a screenshot and click the pencil icon on the pop-up that appears.

augmented jungle

@delroth
Does this also apply for custom ROMs with a similar feature (the screenshot pops up with a crop button next to it)

Pierre Bourdon

@instereo256 no clue, sorry -- I would ask the security contacts for your distro.

augmented jungle

@delroth I tried uploading some crops to the site and it didn't return anything, on PC it says the file is not a PNG. It turns out my crops were saved as a separate JPEG and with a different name (IMG_* instead of Screenshot_*)

I'm using CrDroid, which I just realized is LineageOS based, so that might be it.

Simon Müller :sparkles_trans:

@instereo256 note this only happens with Google's markup screenshot editor, not what crDroid ships (I am ALSO using crDroid, if that matters)

Nicolás Alvarez

@instereo256 @delroth it applies to the Markup app normally only available on Pixel phones, if the custom ROM is sideloading that app then it's vulnerable too

Simon Müller :sparkles_trans:

@delroth this apparently works even when sideloading their Markup screenshot editor on Non-Pixel devices.

Scary stuff.

Hector Martin

@delroth This is where I'm lucky I've been using LineageOS without that tool...

Seriously though, WTF. That's completely ridiculous *and* implies not just a security snafu but also violating standard POSIX safe overwrite hygiene (write out a new file and replace).

re:fi.64 :bisexual:

@marcan
POSIX operations basically don't exist in the SAF world: it's all entirely sandboxed, relies on giving access to individual files, and may not even be backed by physical storage (cloud services can be SAF providers)

(It's not clear to me if the local storage implementation *does* do write-to-file-copy-and-rename tricks or similar, but this is basically entirely outside the hands of the application)

Barney Laurance

@delroth The most surprising thing to me is that it apparently took 5 years for anyone willing to publish to go looking for these pixels.

Do we know what code module has the bug and whether it could be used anywhere else that isn't a Pixel phone?

Ondřej Pokorný

@bdsl @delroth The most surprising thing to me is that for 5+ years nobody noticed a cropped Android screenshot takes up exactly the same space as the original.
I guess that's due to the tendency to hide the file system paradigm from users on the two dominant mobile operating systems.

sporksmith :unicycle: :rust:

@delroth
Woah. Original and recovered from a screenshot I took yesterday on my pixel 6a and cropped in the screenshot tool.

sporksmith :unicycle: :rust:

@delroth
I had sent it to a friend over Google Chat. Nothing recovered from that copy - looks like Chat reencodes.

Mylan

@delroth I wonder if Google patched this for the Pixel 7 since I can't get it to work. Weird stuff.

Pierre Bourdon

@mylan it should be part of the March security update which got rolled out to Pixel 7 earlier this week. Still no update for Pixel 6 though...

Mylan

@delroth ah that explains it. Sorry if this was explained earlier I tried to read it all. Definitely don't mean to downplay the severity of it, this is kinda wild. I've certainly cropped screenshots because of sensitive info and nowhere we are. Hopefully those screenshots aren't floating around somewhere anymore 🙄

Nicolás Alvarez

@mylan @delroth try it on a screenshot you took and cropped before March...

pcyx

@mylan @delroth For me it worked on my pixel 7 with a screenshot I took a minute ago. Revealed the deleted portion of the screen. Phone is fully up to date according to settings app.

I have not received the march security update yet, though, so it seems they haven't rolled it out to everyone.

Thankfully I have only had a Pixel for a week, and have never used that tool to crop. But I imagine there are millions, if not billions of screenshots in the wild suffering from this. Yikes...

EricLaw

Fiddler's "Show Image Bloat" extension already flags CVE-2023-21036 / acropalypse untruncated images, as the untruncated bytes at the end are bloat!

telerik.com/blogs/identifying-

Hazelnoot

@delroth Just tested - this is working for at least some of my screenshots. Very bad.

ollibaba

@delroth That sounds a bit like the challenge from Underhanded C Contest 2008 (underhanded-c.org/_page_id_17.):

> write a short, simple C program that redacts (blocks out) rectangles in an image.
> The challenge: write the code so that the redacted data is not really gone.

Pierre Bourdon

@ollibaba should retroactively give the crown to the Pixel team

Cysio :verified_gay:​

@delroth my phone outsmarted the PoC tool because it takes .jpg screenshots

Eddie Coldrick 💻

@delroth Ah! Disaster. What about editing with the pen tool? I imagine that must overwrite? Just thinking of all the screenshots I have made on my Pixel. And I hope bird site, Mastodon, WhatsApp, etc. don't use the og files, so this can't be done?

Nicolás Alvarez

@eddie @delroth you're affected if your edit makes the compressed file size smaller than the original (such as redacting a large rectangle), not only cropping.

Simon Kowalewski

@delroth How can people not notice for 5 years that cropping a tiny bit out of a 1 meg PNG yields a 1 meg PNG? Or is just nobody using Pixel phones?

AT-AT Assault :verifiedtrans:

@deBaer @delroth

Most people aren't checking the file sizes of their phone based files. Especially since that's not data that is presented to you by default. Unlike, say, if I were to open an explorer window in Windows, go to a file, edit it drastically, and instantly see the file size info change in explorer.

PrivateGER :owo:

@delroth@mastodon.delroth.net AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA ​:nekothisisfine:​

Christoph Thiede :verified:

@delroth Unable to reproduce for screenshots from last year taken on my Pixel 5.

Rainer Müller

@LinqLover @delroth It depends on which tool you used to crop them. As I understand it, only the screenshot editor of the Pixel phones did it wrong. If you used anything else like Google Photos to crop the screenshot, there should be no problem.

Christoph Thiede :verified:

@raimue @delroth No, just swiped from the bottom bar of the screen to the center, pressed screenshot, pen and crop.

aetios ▶️ kwsp
@delroth Oh what in the fuck, this is really dangerous.
Frosty ❄️🌨️ Whiskateers =OωO=
@delroth decided to give it a try myself. First two images are before and after with an old screenshot. Tried a newer screenshot from yesterday and got this message instead.
rpigab 🦀

@delroth This is awfully dangerous. People are gonna know that sometimes my battery level falls way below 20%, and call me out with proof.
Might have to sue Google.

the clownward spiral

@delroth >
We cannot make any changes to Android 10 and Android 11 anymore, so the behavior cannot change on these versions. We recommend using mode "rwt" as a workaround.

lol. lmao

mcc

@delroth Excuse me for a moment while I scream into a pillow

Pixel *only*? Alternate vendors probably safe?

Pierre Bourdon

@mcc from what we know so far, I think that's accurate.

doll!

@delroth @mcc tested on my OnePlus 6t running Lineage, the demo failed saying "no extra image data"

Pierre Bourdon

@protofoxriley heh, at least you don't have 5 years of potential leaks to think about...

Super Riley RPG Remastered

@delroth very true, which is lucky for me, unless iOS devices start having this issue 😳

http :verified:

@delroth Don't forget that on iOS you can simply click "Revert" to undo any cropping, even years later, unless you transferred the image without full image data.

Nicolás Alvarez

@http @delroth I don't think that's even stored inside the same file?

http :verified:

@nicolas17 @delroth It is. Apple uses the HEIC format for images. That also contains the video for "Live" photos and tons of more stuff.

Kevan

@delroth @Femtoduino But this seems serious and preventable. I figured they had better security/privacy implementation. Good to know.

r0bobox

@delroth welp my screenshots of memes might get me doxxed

Christian Hagenest

@delroth Well, I'm certainly happy to have used the Pixel Experience custom rom. Serves me right for installing even more spyware on my phone, I guess

Matt Cengia

@delroth Google has communicated this, for some value of "communicate": source.android.com/docs/securi mentions CVE-2023-21036. My device isn't currently offering me this update, however.

Pierre Bourdon

@mattcen the only reason we know what CVE-2023-21036 even is is thanks to the researchers releasing info... this does not count as communicating anything.

Mx. Toffer D Brutechild HSD-SC

@delroth did we not all learn how dangerous this was from Catherine Schwartz?

Kneebiter

@delroth @suricrasia For what it's worth, this is also an issue with the way Microsoft Word 'crops' images. Word just changes the dimensions of the display area. The uncropped image is easy to view by unzipping the docx.

Slips

@delroth@mastodon.delroth.net i wonder if this applies to just Pixels or any cropping done with Android tools.

Sojourn :coffefiedyellow:

@delroth yay, using a custom ROM based off of AOSP and using the stock cropping tool, I'm immune to security issues :)

Thanks @grapheneos

Mr.UNIX

@delroth How was this left unnoticed for 5 years?!?

Go Up