-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Sharing images from other apps removes EXIF location on Android > 10 #6248
Comments
How are you uploading the picture? Auto Upload? The "Upload files" button? The "Upload content from other apps" button?
Does this mean you have a stock system? (I.e. the version of Android that came with your phone)
I believe this question is asking what web server you access Nextcloud through. |
@strugee updated the issue. Trying several other uploads, I found out that the issue may not be related to the Nextcloud app itself. I've uploaded pictures through the share menu from both apps:
Both uploads resulted in setting the GPS data to zero. Upload through a file browser like "Amaze" or through the Nextcloud app itself didn't change the GPS data. Tricky one! I will contact the app maintainers and reference to this issue here. |
I have to reopen it again since I'm not quite sure how to debug this issue without brainstorming/information from here. The "simple gallery" app provider said that they don't change the image beforehand. What could be the problem? |
I think it is usual for sharing application to remove metadata, it used to be a huge privacy leak sending images over IMs that turned out to contain user's exact coordinates. |
Also to reference a comment which describes exactly the same thing: nextcloud/maps#361 (comment) |
How exactly did you upload in all of these apps? Did you use the "Share" button in Amaze? In Simple Gallery? In the stock gallery? In general the more information and specifics contained in a bug report, the better. |
@strugee as I said in point 3: |
NC is not changing any metadata. |
@tobiasKaminsky can we reopen this issue please? It prevents me from uploading images through gallery apps which is way more convenient than doing it through the Nextcloud app. |
Stripping EXIF data is part of the android Q privacy feature set. Starting with Android 10 (or 11?), apps need to explicitly specify that they want to receive Metadata. So it's indeed a bug in the nextcloud client, and not the fault of speciffic gallery apps. You can read more about it here: |
@AlvaroBrey any chance we get feedback on this issue since @fm-sys thankfully added more information? |
Hopefully a resolution soon on this |
I found a solution, not sure it works everywhere, but it fixed every upload done with the Nexcloud app (notably instant upload). Go to your phone Settings -> Privacy -> Permission Manager -> Files and Media. Find Nexcloud in the list and make sure to "Allow management of all file". This works for me Previously this setting was on "Allow access to media only". |
I get gps data on my Samsung S21 + with auto uploads on. It started to work. I have no idea what changed. |
Tested some more. Funny thing is only instant upload and "Upload files" from the "all app" menu is working. |
Uploading within the Nextcloud app already worked before in my case, it is cropping GPS data when you use the share functionality of other apps like gallery and files apps. |
The problem also occurs under Android 13 on a Pixel 4. |
Clearly, this is a case of data loss! If I wouldn't have found out and would just have all my photos in the nextcloud instance I would never be able to get back my GPS data in the photos. How is this issue not getting more attention? How many users may be already affected by this? |
Nobody seems to care about these issues. And the amount of them is vast. |
Can i just clarify these responses because as I see it my logic HAS to be incorrect or this would be an absolutely horrendous critical bug that has been open for potentially 2+ years. If it was Edit: I have now determined that as well as images videos have had GPS tags stripped as well. |
I think a recent update may have fixed the issue. |
I also just found that the location does auto-uploading on my Galaxy phone after discovering there is a location tag option in the camera app that was toggled off. Turned it on and sure enough, the location was in Nextcloud in the next picture I took. |
Still happening on the latest non-beta from Play Store (3.26.0) on Pixel 7 with Android 13 (September update). When testing it's worth sharing the following:
|
Thanks @vitis586, your fix worked for me! Is there any way to resync all the data now to upload the information to nextcloud? |
You could create a new folder on your phone with the problematic media files. You could also do this on you normal camera folder, if you want reupload everything. |
You can do what @Cebrain suggested. That is the most straightforward way how to do it. I my case I had already done some changes to the EXIF before I noticed that it is missing location data. I then used exiftool to extract the position data to csv and then used this to update the already uploaded files. |
@Cebrain I want to reupload all from my camera folder, but do not understand how, sorry :( |
This is no problem, you only need to disable the auto upload for the Camera folder. Save the setting. |
Manual activation of "allow access to all files" in android settings for the nextcloud app solves the issue. |
Signed-off-by: tobiasKaminsky <[email protected]>
@mrcg It already is. Well, it's requested at install time. The user can choose the other option on the pop-up though, which will obviously result in us not getting this permission: |
I just moved to a new phone, had to freshly set up next cloud client. I did not receive this prompt. I would also suggest the app should monitor to ensure it still has this permission before uploading corrupt data. |
@brilthor Are you by chance on Android OS <11? |
Nope, Android 14 build UQ1A.231205.015 |
I think I mentioned it earlier, if the API that gives NextCloud zeroed out files has any return code that indicates it does that NextCloud should pay attention to it and notify quite prominently. If there is no indication about that NextCloud could still detect this from the content of the files (these files don't just have no GPS data, they have zeroed out GPS data). Or, easier, instead of trying to do something fancy just read the GPS via some standard library and if nothing sane is returned just warn on the transfer notification (with the option to disable the extra text somewhere in settings). This could help also if the location permission gets removed from the Camera app (because of inactivity) or some other shenanigans happen in the next flavor of Android and the user starts generating pictures without location, while actually wanting this data to be saved. For the users that want no GPS tags it shouldn't be too bad if they get this spelled out in the transfer notification (with the option to have the text removed and basically revert to what we (don't) do now), might actually be a welcome confirmation that they still have the desired configuration. |
To "fix" (er work around) this on a Pixel 8 Pro running Android 14 do the following: |
Steps to reproduce
Expected behaviour
Actual behaviour
Can you reproduce this problem on https://try.nextcloud.com?
Environment data
Android version: 10 (OxygenOS 10.3.3)
Device model: OnePlus 6T
Stock or customized system: Stock
Nextcloud app version: 3.11.1
Nextcloud server version: 18.0.5
Reverse proxy: Nginx
Logs
Web server error log
Nextcloud log (data/nextcloud.log)
Only related to "Maps" app while trying to analyze the image since the GPS data is wrong.
I faced this issue since I saw that the pictures weren't showing up in the Maps app of Nextcloud. So this is not a new issue. Also I can surely say that the problem started before 20th of April, so also with a prior version. I can share pictures in a PM.
Appreciate any ideas for solving this issue.
Thank you for your great work!
The text was updated successfully, but these errors were encountered: