I have a linux SFTP server which I use to share files with other people.
There is a script that automatically find and delete files uploaded more than 10 days ago:
find . -not -path . -mtime +10 -exec rm -frv {} \;
I've noticed that some SFTP clients preserve last modified date, causing the script to delete the files sooner than expected.
For instance, if Today is 15th of December, and a client upload a file that he modified on his computer on the 1st of December, the file gets deleted immediately, instead of the 25th of December.
So, how can I deny the clients to change last modified attribute after the upload?