Hi guys,
Just found out the hard way that uploaded photos will retain any location (ie. GPS Lat/Lon) data stored in the image’s EXIF (in fact, the whole EXIF is retained, including device, f-stop, white balance, ISO etc data). While I understand there’d be a bit of work involved in stripping any EXIF data out, the removal of at least the location data would be a privacy concern of many users (both current and potential), especially if it’s expected they may be uploading from a mobile device (which they more than likely took said photo on) - while someone might feel comfortable having their home town in their profile, having the GPS coordinates of their house publicly available is likely another story.
That’s a sensible idea, but at the same time I think Discourse shouldn’t be modifying users’ uploaded files unless the user explicitly told it to do so.
This could be an option in the “Add image or file” dialog, however; a “strip private metadata” checkbox, for instance. When images are uploaded via drag&drop and contain problematic EXIF headers, a warning message in the composer should be enough.
I know twitter strips the EXIF headers. And I’m not totally sure how Wordpress does it, but I think if the image is resized the EXIF headers are stripped. I doubt 500px strips any of the headers, but they are more of a photo centric application.
I personally think the private information should be removed but I think we should also look and see what other apps are doing and learn from them.
Would definitely accept a community PR in this area!
Add a checkbox, checked by default, labelled “remove EXIF data”.
You mean you’d put this in as a standard option? I think this is definately plugin territory. Or at least have the ability to turn it off.
Safe by default is what we try to deliver and I think stripping exif data is safer by default. Helps with rotated by metadata images as well, which @zogstrip already completed, right @zogstrip?
Since EXIF data also contains copyright information which can be used to help fight copyright violations, I think it’s a really, really bad idea to strip it - regardless of the fact that Twitter and Pinterest do it.
Removing copyright information might even be illegal in some countries.
(b) Removal or Alteration of Copyright Management Information. — No person shall, without the authority of the copyright owner or the law —
(1) intentionally remove or alter any copyright management information,
I don’t see anything bad about stripping EXIF location, you don’t need to touch copyright
Yes I did.
Looks like the action is here?
def self.fix_image_orientation(path)
`convert #{path} -auto-orient #{path}`
end
Maybe someone can extend that into a PR to remove EXIF location information.
Unfortunately, after a quick lookup, Image Magick only support stripping all the EXIF information. We’ll need either a new gem or a new tool to deal with that issue properly.
Personally I think that’s fine. If it’s good enough for Pinterest and Twitter, it’s certainly good enough for us.
我认为 Discourse 不应移除任何 EXIF 数据,至少默认情况下不应如此。无论如何,应提供全局选项或用户选项(可能是插件?)来移除这些数据。
如果用户不希望将某些 EXIF 数据发布到任何社交网络,他们应在导出为 JPEG 时自行移除 EXIF 数据。
作为摄影论坛的管理员,图像的 EXIF 数据对我们的用户来说非常重要。
也许对你来说,更好的办法是链接到 Flickr 上的照片,而不是直接上传?
完全不是……我们希望上传到我们网站的照片遵守许可协议。我们创建这个论坛是因为我们不喜欢 Flickr 或 Facebook 那样的平台,在那里你只能收到点赞,却收不到评论。
我们创建这个社区是为了获得大家对我们照片的意见,因此照片应保留在社区内。
如果您在意隐私或照片中的敏感数据,只需在导出时不要在图片中保存这些信息即可。
有意思。我曾以为 Flickr 是网络上最尊重用户隐私的照片存储和分享平台,与 Facebook 截然不同。不过我也有一段时间没使用这两个平台了。就我个人而言,我将照片离线存储,并保存在 Nextcloud 服务器上,偶尔才会在 Discourse 论坛上分享一张照片。
听起来,您需要的是一款插件,用于将移除 EXIF 数据设为可选功能。您可以在 Marketplace 中提出相关需求。
最尊重的做法可能是 1x,500 像素也是尊重的,但 Flickr 同样尊重,不过它不是免费的,而且我们不能依赖 Flickr、500px 或其他平台对我们需求的看法。
您可能误解了我们的观点(也许是我没有解释清楚,抱歉我的英语不好):我们是一个摄影师社区,大家分享照片是为了获得他人的意见。
我们并不把 Discourse 当作存放全部或大部分照片的地方。
EXIF 信息有时对提供意见很有用。
不,我不需要插件,需要它的是那些要求改变 Discourse 行为的人。
Discourse 目前会提供 EXIF 数据,并不会从文件中剥离它。
提供一个选项,让用户可以选择是否全局剥离或作为个人偏好设置,是一个很好的解决方案。
这当然可以通过插件来实现。
你也可以在上传时添加一个简单的复选框来扩展该功能,这将是一个非常棒的功能。
我经常用手机拍摄待售零件或物品的照片,然后上传到我们的论坛,结果却暴露了我的家庭位置::man_facepalming:
我们的论坛图片很多,所以同意保留 EXIF 信息对我们来说确实很有用。
大多数时候都是这样::blush:
是的,增加删除部分 EXIF 数据的功能会非常棒。
但为此需要在系统中添加完整的 EXIF 管理功能。
我认为最佳方案是:
建立一个包含三个选项的全局参数:
- 保留所有 EXIF 数据(默认开启,以免破坏当前安装的功能)。
- 从上传的图像中剥离 EXIF 数据。
- 允许用户选择是否剥离 EXIF 数据。
如果在_global_级别选择了第三个选项,用户应拥有以下偏好设置可供选择:
- 保留所有 EXIF 数据(默认开启,以免破坏当前安装的功能)。
- 从上传的图像中剥离 EXIF 数据。
上传图像时,系统仍应提供按单张图像剥离图像数据的选项(即使您已选择保留它们)。
您可以在上传图像的对话框中添加该选项。
理想情况下,如果有人选择剥离数据,他们应能够选择:
- 仅剥离 GPS 和位置数据。
- 仅保留基本数据(相机和镜头型号及拍摄参数)。
- 剥离所有图像数据。