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

rsyncd running by non-super-user tries to change gid #621

Open
schwitin opened this issue Jun 18, 2024 · 0 comments
Open

rsyncd running by non-super-user tries to change gid #621

schwitin opened this issue Jun 18, 2024 · 0 comments

Comments

@schwitin
Copy link

schwitin commented Jun 18, 2024

rsync version 3.1.3 protocol version 31

Steps to reproduce

rsyncd.conf:

use chroot = false strict modes = false hosts allow = * log file = /var/log/rsync/rsyncd.log pid file = /run/rsyncd.pid uid = root gid = root ...

Run rsyncd as not privileged user

Copy a file to remote server:
/usr/bin/rsync /path/to/myfile.zip rsync://myhost/my-module/new-folder/

Actual behavior

On The clinet side

@ERROR: setgroups failed rsync error: error starting client-server protocol (code 5) at main.c(1675) [sender=3.1.3]

On the server side (rsyncd.log)
2024/06/13 14:15:03 [42616] rsync: setgroups failed: Operation not permitted (1)

Expected behavior

https://download.samba.org/pub/rsync/rsyncd.conf.5#gid

gid The default for a non-super-user is to not change any group attributes (and indeed, your OS may not allow a non-super-user to try to change their group settings).

Workaround: remove uid and gid from rsyncd.conf

@schwitin schwitin changed the title rsyncd running in user mode tries to change gid rsyncd running by non-super-user tries to change gid Jun 18, 2024
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

1 participant