Skip to content

Check image coordinates for direct Nearby uploads in locations that the user is not currently in #945

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
misaochan opened this issue Nov 9, 2017 · 10 comments

Comments

@misaochan
Copy link
Member

misaochan commented Nov 9, 2017

After #591 and #252 are both implemented, there is concern that #591 could potentially increase the risk of vandalism via direct uploads, since the user would not need to be in a location (or to even spoof their location) in order to upload a picture for that Nearby item. When P18 edits are implemented, the consequences of this could be even more severe, as the Wikidata items will actually be edited and removed from Nearby.

If we allow direct Nearby uploads for items in locations that the user is not currently in, we should check the geolocation of the image (via EXIF data) and disallow the direct upload if it is not within a close radius of the Wikidata item location.

Not sure what we should do if the user simply did not enable geotagging on their camera, though...

@neslihanturan
Copy link
Collaborator

Hmm, how does site handles this problem? I think, I am able to upload a photo of a place without EXIF.

@misaochan
Copy link
Member Author

misaochan commented Nov 9, 2017

The site doesn't have the 'Nearby places that need photos' feature or direct uploads for Nearby items. :) This only refers to direct uploads for a specific Nearby item, aka #252

@neslihanturan
Copy link
Collaborator

I mean uploading a nearby item is almost same with uploading a place explicitly. If vandalism is under control for "uploading photo of a place" case, it should be fine four our case too.

@misaochan
Copy link
Member Author

The difference is with the P18 edits. Once a direct upload is done with Nearby, the P18 property of that Wikidata item will be edited and the item will be removed from the 'nearby places that need photos', because it already has a photo.

@nicolas-raoul
Copy link
Member

It is right that a vandal that wants to vandalize already has many venues to perform their deed.
But as Josephine said, Nearby vandalism would be harmful to 2 projects instead of 1.
Also, we are looking for ways to reduce vandalism everywhere, and each solution is welcome even if it does not cover all of our scope. We can not detect vandalism with EXIF coordinates for normal uploads (not activating GPS for a picture taken in my garden is legitimate), but in Nearby we have the chance of being able to do it so, so doing so is a good idea in my opinion.
I believe this is very low-priority compared to other user education measures such as #7, though.

@misaochan
Copy link
Member Author

My thoughts on implementation: If a user uploads a photo via Nearby with a geotag that is not close to the location of the Nearby item (within a radius of 100m perhaps?), notify user of this and ask if they want to upload anyway. If they confirm that they want to perform the upload, allow the upload but do not edit the Wikidata item.

@nicolas-raoul
Copy link
Member

Great idea!
I would say radius of 1 kilometer, because GPS is often way off.

@misaochan
Copy link
Member Author

@nicolas-raoul Good point! 1km it is then.

@maskaravivek
Copy link
Member

I understand the vandalism concerns but I was under the impression that Nearby uploads would enable to upload the photos at a later point of time.

For example, I recently visited a few historical places on my trip to Pune, India and i was hoping to upload the phots after returning. Limiting the uploads to 1km radius might defeat the purpose.

To mitigate the risk of vandalism we could introduce some sort of consent checkbox making him aware that his direct upload will edit the Wikidata entity. Moreover, we are already logging to keep track of the edits made.

I am not not aware of any review policy for Wikidata edits but we could check with them about their opinion on this concern.

@misaochan
Copy link
Member Author

misaochan commented Jun 21, 2018

@maskaravivek Yes, if you take a photo of a landmark in Pune, and then return to your home, you should be able to upload them to Nearby after #591 is complete. This enhancement would check the EXIF data of the image for the image's coordinates, not your current coordinates. So where you upload the photos from would be irrelevant in this context.

misaochan pushed a commit that referenced this issue Dec 16, 2018
…ions that the user is not currently in (#2099)

* Add getGeolocation method to geolocation from file path

* Add geolocation check to receiveDirect method checks, means it will be checked durimg nearby direct uploads

* Create method body for geolocation and nearby place coordinate comparaison, this method will be filled on consequent commits

* Add a method to find location missmatch

* app/src/main/java/fr/free/nrw/commons/utils/ImageUtils.java

* Add if check to upload activity to detect pictures with wrong location, and save it to shared prefs

* Do not edit wikidata item if picture has wrong location info

* Add one more bitwise operand to possible warning reasons for wrong location case

* Add a bitwise variable for wrong locatio case

* Share nearby place location just like wikidataEntityId, so that we can compare

* Implement check image geolocation is different method by comparing nearby location and file EXIF geolocation

* Add Javadocs

* Remove logs

* Fix all taken on wrong phrases as taken at

* Fix typo on logs

* Simplify if logic

* Fix string issues
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants