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

Folder permissions are inconsistent when using {u} #79

Closed
Sirmentio opened this issue Mar 20, 2024 · 3 comments
Closed

Folder permissions are inconsistent when using {u} #79

Sirmentio opened this issue Mar 20, 2024 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@Sirmentio
Copy link

Sirmentio commented Mar 20, 2024

Describe the bug
Running a local (not docker) copyparty-sfx. In my configuration folder, I have the following:

[/${u}]
	./${u}
	accs:
		g: *
		rwmd: ${u}, @su
	flags:
		vmaxb: 1g

However, no one outside of the user who owns the folder can see/get anything from it. Not even su members, which telling form above should have the same permissions as the user.

Expected behavior
Everyone should be able to get, guests/strangers, other users alike, what's inside of the volumes. su group members should be able to access these files as well.

Server details
if the issue is possibly on the server-side, then mention some of the following:

  • server OS / version: 6.1.0-1-amd64 pypy3 bug #1 SMP PREEMPT_DYNAMIC Debian 6.1.4-1 (2023-01-07) x86_64 GNU/Linux
  • python version: Python 3.11.2
  • copyparty arguments: --no-robots -c /opt/copyparty/copyparty.conf
  • filesystem (lsblk -f on linux): ext4

Additional context
I've been trying to get this to work for a bit. Irritatingly, permissions works as expected if I manually make the volumes in the config, by hand. This can be a workaround for now, but I would prefer to have less work in the long run (And even less so if I bother with Oauth 😉)

@Sirmentio Sirmentio added the bug Something isn't working label Mar 20, 2024
@9001
Copy link
Owner

9001 commented Mar 20, 2024

Hey! thanks for the heads-up, and for trying copyparty :>

I'll take a look this weekend, just gotta finish up something else first 👍

@9001 9001 closed this as completed in d30ae84 Mar 21, 2024
@9001
Copy link
Owner

9001 commented Mar 21, 2024

alright, should be good now -- there's a new build here if you'd like to give it a go: https://ocv.me/copyparty/beta/copyparty-sfx.py

but! I should mention that you're bumping into a design limitation with a config like that --

every time copyparty is restarted, none of the volumes will be accessible to anybody until each volume's owner sends their first request to the server, since they're all forgotten on shutdown -- unless the volumes are inside a parent volume which does allow the intended access, in which case all the user volumes will inherit that permission until the user shows up again... yep, I know...

unfortunately, this limitation is not likely to go away anytime soon, since trying to think of a safe and reliable way to remember+restore the volumes just gives me a headache every time heh

so, one workaround for your particular config could be to make the toplevel volume something like:

[/]
  ./
  accs:
    g: *

if you're planning to continue playing with this over the weekend then I'll wait until sunday to post the new release, since there might be more edge-cases to weed out still -- otherwise I'll do it tomorrow eve 👍

also, just curious since you're using the sfx -- how are you running the idp service? does debian package something that's convenient enough to use without docker, or is that running on a remote box / in docker? just fishing for more ideas / suggestions to add to the docs :>

@Sirmentio
Copy link
Author

Sirmentio commented Mar 22, 2024

I'm running just it on the base system with the systemd service. I have trouble using docker a lot of the time, mostly with getting HTTPS to work.

Either way, thank you! This works perfectly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants