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

add a few upstream gnome commits #1

Open
wants to merge 5 commits into
base: blacklist_some_env
Choose a base branch
from

Conversation

ItzSwirlz
Copy link

No description provided.

Variables like CINNAMON_SHELL_SESSION_MODE may not always be set at 
login,
causing them to survive between session. Add a list of variables that
need to be unset, and explicitly unset them on the systemd side.

The list is taken from GDMs list of variables.

See: GNOME/gnome-session@b7b24627
Specifically, systemd only permits " \t\n" and we should stick to the
same set of permitted space characters.

See also
  systemd/systemd#17378

Fixes issue with not filtering the variables with return characters.

See: GNOME/gnome-session@fe22c4ee
systemd cannot be auto-started. Doing this avoids warnings during login
of the gdm user where we (intentionally) cannot use systemd.

See: GNOME/gnome-session@87d92fec
It seems that the pattern we use will create a subpattern match for
every character of the value. This appears to then result in a stack
overflow when matching very long values.

It might be an idea to limit the overall length of an environment
variable that is uploaded. But, this should fix the issue of crashes.

Fixes a stack overflow caused by long environment variables.

See: GNOME/gnome-session@3b57d117
Commit 646b9bc (included in 3.33.92) prevented one run of gnome-session
from uploading environment variables into `systemd --user` that should 
not
leak into a different login session, such as XDG_SESSION_ID. However,
non-GNOME session managers (and in particular the forks of gnome-session
found in Cinnamon and MATE) might still upload those environment 
variables.

The other session managers should be fixed, similar to 646b9bc, but we
can mitigate this for GNOME sessions by actively unsetting the undesired
variables, instead of just not setting them.

Stops innapropriate variables from leaking into later sessions - see 
https://gitlab.gnome.org/GNOME/gnome-session/-/issues/86

From: GNOME/gnome-session@d44888fb
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

Successfully merging this pull request may close these issues.

1 participant