Skip to content
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

Uploaded file timestamp is different #289

Open
dave0003 opened this issue Dec 13, 2022 · 3 comments
Open

Uploaded file timestamp is different #289

dave0003 opened this issue Dec 13, 2022 · 3 comments
Milestone

Comments

@dave0003
Copy link

dave0003 commented Dec 13, 2022

I'm using primitive ftpd v6.15 with the super user storage type. My phone is running Android 12, xiaomi.eu v13.0.15, rooted.

I'm using sftp to upload a file to the phone. The transfer appears to work fine and the file size is the same, but the timestamp is different on the phone. I noticed another issue where the timestamp was the created time instead of the modified time, but in this case, it is neither.

The original file created time is 12/3/2022 1:37:01 AM and the modified time is 12/13/2022 11:05:30 PM.

When I look at the file on the phone from a usb connection, it shows the timestamp as 2/8/2020 at 8:52 PM.
When I look at the file on the phone from sftp, it shows the timestamp as 2/9/2020.

Windows 10 vs. sftp (psftp/putty)
12/13/2022 11:05 PM 179,746 backup.daily
-rwxrwx--- 0 root everybod 179746 Feb 9 2020 backup.daily

Any ideas?

UPDATE: It's odd. I noticed after I rebooted the phone, it has the correct timestamp on the file. So I tried uploading it again. This time the timestamp had a future date, 2/16/2023 4:04 PM. Then I rebooted the phone, and it's correct, 12/15/2022 1:35 AM. If I copy the file using the usb connection, this doesn't happen. It only happens via sftp, and the timestamp is incorrect viewed from sftp or usb. Until I reboot the phone.

@wolpi
Copy link
Owner

wolpi commented Dec 14, 2022

There have been reports regarding wrong timestamps before. Behavior depends heavily on used storage type. I'm not sure if client software may send different timestamps.
For storage type "root" there is timestamp handling implemented. I'll check it when I find time.

wolpi added a commit that referenced this issue Mar 25, 2023
@wolpi wolpi added this to the 6.16 milestone Apr 8, 2023
@wolpi
Copy link
Owner

wolpi commented Apr 8, 2023

Well, as you can see in linked commits, there will be improvements in next version but it still does not work perfectly

@dave0003
Copy link
Author

dave0003 commented Apr 8, 2023

Thank you!

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

No branches or pull requests

2 participants