-
Notifications
You must be signed in to change notification settings - Fork 27
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
umask affects permissions in zkg bundles #196
Comments
There seem to be two issues here:
|
I think the problem is that Looking at the code, A possible solution would be to set the umask to 022 and then use |
Nice.
So initially it's a usability issue where the user Zeek runs under can't read unbundled scripts?
Ignoring the user/group and suid bits from the tarfile seems reasonable and allowlisting certain file types. I'm a bit uncertain about x flags, we may want to keep those (think helper scripts). So maybe tars |
Yes. If a bundle is created on a system with restrictive permissions, those permissions are applied while unbundling, and this generally leads to permissions issues with zeek unless you are unbundling as the same user zeek runs as.
I think the I'll go take a look at the wrapper and see how much effort it would be to implement this. |
It appears the I wonder if we could just include a more recent Versions which include the new feature:
|
The umask set by a user affects permissions of files on disk, which are then honored when creating the zkg bundle tarball. Setting a umask to something like 0027 is a good security practice, but can create bundles that cause problems in common zeek installations.
It would be very useful if zkg could create identical bundles regardless of a user's umask (or the permissions of the files on disk), or at least emit a warning if scripts aren't world readable when creating a bundle.
The text was updated successfully, but these errors were encountered: