Signal-Android icon indicating copy to clipboard operation
Signal-Android copied to clipboard

Image Meta Data Removal

Open okiyani opened this issue 9 years ago • 14 comments

This feature request is for an option to remove meta data from a picture being shared in a conversation to prevent location, device and other key data being shared.

okiyani avatar Dec 17 '16 16:12 okiyani

Isn't this how it already is? I just tested this with three images: a picture taken with the direct camera, another one with the attachment drawer camera and the last one by attaching a picture taken with the system camera. None of them had any metadata.

2-4601 avatar Dec 18 '16 00:12 2-4601

I think it happens incidentally at the moment because of image scaling, but if an image were small enough to be sent without scaling or compression, I'm not sure the metadata would be removed.

moxie0 avatar Dec 18 '16 02:12 moxie0

Can confirm, after exporting an image, there is no metadata except for the megapixels and the time it was saved to the device (not capture time).

sweeper3000 avatar Dec 18 '16 05:12 sweeper3000

I took a small picture and sent it to another phone. I exported the picture on the same phone from which I sent it and the metadata were still there. So this issue seems valid to me.

EDIT: The small picture's metadata are also present on the receiving phone.

FeuRenard avatar Dec 19 '16 20:12 FeuRenard

I can confirm that on Android EXIF data is not removed in many cases. Including the simplest one of "I'll attach a photo to a group chat."

Bug description

I sent a photo from my camera to a group chat. I then thought to myself "Does Signal strip EXIF data?" So I asked someone in the group chat to check. They extracted my phone's model, date/time information, and the GPS coordinates from the EXIF data.

Steps to reproduce

  • Send a photo
  • Extract EXIF Data

Actual result: EXIF Data is maintained when I send a photo Expected result: I would expect Signal to do the 'safe' thing by default which would be at a minimum to strip geolocation data.

Obviously geolocation data is extremely sensitive (it's extremely common to take photos in your own home) and in many or most cases one does not want to share their home address with all the individuals one may wish to send a picture to.

Device info

Signal version: 4.8.1

tomrittervg avatar Jul 25 '17 13:07 tomrittervg

The code here could be helpful: https://github.com/openssf/exif-remover-android/blob/master/app/src/main/java/org/openssf/exifremover/MainActivity.java#L119

FeuRenard avatar Aug 11 '17 08:08 FeuRenard

@FeuRenard is this a coincidence? :thinking: The last committer in that repo is @zanedb. Seems like he/she is ready to contribute here (commented here today, see https://github.com/WhisperSystems/Signal-Android/issues/6520#issuecomment-321734476)

ghost avatar Aug 11 '17 09:08 ghost

No coincidence. I read his comment, browsed his Github page and discovered the repository. Thanks for mentioning @zanedb, I didn't think of it but should have done 😇

FeuRenard avatar Aug 11 '17 09:08 FeuRenard

Well, I hope the code can be useful. A few pointers though:

  • When I was working on that, I was (and still am, but less so) a pretty inexperienced Android programmer
  • The code didn't always work on certain file formats and in certain environments (worked particularily well on JPEG files, but not JPG, which, if I understand correctly, are the same thing (see lines 83-105
  • The code is not particularly well done (see point 1), so if you have any issues/don't understand what I was trying to do please let me know
  • If you review the commit history on that file, I tried it with multiple different libraries, such as Sephiroth74's ExifInterface and now, the default Android ExifInterface

Also, at some point I plan on turning that (bad) app into a library for simple Exif data removal. I could try and work on that soon if wanted in Signal.

zanedb avatar Aug 11 '17 14:08 zanedb

Can any Signal contributors confirm whether or not this idea has the support of the project? This issue is about a year old, and I'm wondering if a PR would even be considered at this time. The corresponding Signal-iOS issue contains even more chatter and support for stripping metadata, yet it doesn't look like anyone has made the call to move forward there either.

BHSPitMonkey avatar Nov 30 '17 06:11 BHSPitMonkey

I'd accept a PR for something that strips out non-orientation exif metadata by default with an option to leave it in.

moxie0 avatar Nov 30 '17 17:11 moxie0

Has this issues been assigned to anyone or can anyone work on it? I'd like to work on this.

tinkuge avatar Dec 09 '17 01:12 tinkuge

I'm also experiencing this on Android 7.1.2 with Signal 4.14.10

Lvl4Sword avatar Jan 24 '18 20:01 Lvl4Sword

GitHub Issue Cleanup: See #7598 for more information.

automated-signal avatar Apr 03 '18 00:04 automated-signal