Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • Sympl Sympl
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 61
    • Issues 61
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Sympl
  • SymplSympl
  • Issues
  • #298

Closed
Open
Created Sep 06, 2020 by Iain Hallam@iainhallam

sympl-filesystem-security: public-group doesn't work

Summary

When putting a group into <domain>/config/public-group, running sympl-filesystem-security produces the output id: ‘<group>’: no such user. Found on sympl-core/stretch 9.0.200510.0.

Steps to reproduce

Place the name of a group that isn't www-data in <domain>/config/public-group and run sympl-filesystem-security.

Possible fixes

https://gitlab.mythic-beasts.com/sympl/sympl/-/blob/buster/core/sbin/sympl-filesystem-security#L50 (and 51) use id -g $gid, which seems like it should find the GID of a group, but actually finds the GID of the primary group of user $gid. If no user of the same name as the requested group exists, this fails. The script seems like it will need to use getent group and cut or awk to get the right fields.

/cc @kelduum

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking