Research scientist here, not a sysadmin. I am setting up a server running the rsync daemon. Various user machines (that I do not control, other than to install a scheduled script) will periodically automatically connect to submit files for it to back up. They will mostly be Windows machines, using cygwin to run rsync only at times when they are expected to be idle, so I can't have the server try to pull the files, they have to be pushed from the user's machine. I would like to ensure that all operations take place with -b flag set (backup mode). This is because users generally don't modify these files and I can live with the inefficiency or set exceptions for those rare cases - we are mostly backing up new data in entirely new files. My assumption is that if a bunch of files are suddenly modified, it's either because someone has been infected with ransomware that has encrypted them, or some black hat (or a$$hat) is messing with the user's machine, and either way I don't want any overwriting going on.
I will set the -b flag on the scheduled cygwin-rsync operation, however this means that control of this behaviour resides on the Windows machine that I don't fully trust not to be hacked or virus ridden. Is there any way to set the rsync daemon on the server that is receiving the files to operate with the -b flag set no matter what the user machine tries to do? I.e. if my user's machine gets hacked by some script kiddie who decides to mess up all their files, and then remove the -b flag from my script so the backups are overwritten, I want my server to ignore that and operate in backup mode anyway.
We subsequently have "proper" offsite backup of the server with snaphsots and restore points etc, so please don't tell me to do that instead - it's happening, but again it's being done by other people on machines I don't control. I would like to harden *my* link in the chain as much as possible in case everyone else drops the ball, because I'm the one who needs that data to stay intact.
Is there any way to force this behaviour?