libcosmic greeter for greetd, which can be run inside cosmic-comp
pop-os / cosmic-greeter Goto Github PK
View Code? Open in Web Editor NEWlibcosmic greeter for greetd, which can be run inside cosmic-comp
License: GNU General Public License v3.0
libcosmic greeter for greetd, which can be run inside cosmic-comp
License: GNU General Public License v3.0
From the unlock screen, if you want to show the password (eye icon) it does not show it. The password is always *****
start-cosmic
works fine, cosmic-session
works fine, so I'm pretty confused and I've been trying to figure out why cosmic-greeter won't log in to the session properly. All I get is a brief black screen with a panic in greetd:
thread 'main' panicked at greetd/src/session/worker.rs:200:14:
unable to exec: EACCES
I tried looking at it with RUST_BACKTRACE=full
but the stack trace was completely unhelpful, going through a lot of unknown areas and some libc areas
I have these dependencies installed (not including dependencies derived from build depends) (Fedora)
Is there a way of testing cosmic-greeter
without actually having a fullscreen lock window?
Also, I'm not sure how this is supposed to be contributed to. This for now, I'm building and running the server
example and that seems to be the way to test it. But, I can't write any code without first unlocking the lock screen, which is very inconvenient.
Hi,
This is a bit esoteric, I'm happy to try to patch and test this myself, especially if someone can give me a pointer.
I am trying to get away from passwords for my local machine. I have PAM configured to allow me to login with a u2f/fido2 token.
However, I also have udev configured to loginctl lock-sessions
whenever I remove my fido2 token. This ends up trigger cosmic-greeter, which then does not find my fido2 token available, and switches to password prompt.
I'm wondering/hoping that there's a way to maybe bind Escape to "re-trigger" PAM? or like (securely) soft-reset the greeter/unlock process?/
Thanks for any tips! And thanks for Cosmic, already feels great!
On serw13, I sometimes see a grey screen with no dialog when I try to lock the screen. This seemed to happen less with cosmic-greeter as my DM than before when I was using GDM, but I just had it happen again.
These seem to be the relevant logs (before this was me moving panel applets around, and after it was me running commands in the TTY):
Mar 01 16:53:06 serw13 cosmic-panel[3656]: [GL] GL_INVALID_VALUE in glTexSubImage2D(xoffset 0 + width 440 > 432)
Mar 01 16:53:06 serw13 cosmic-panel[3656]: [GL] GL_INVALID_VALUE in glTexSubImage2D(xoffset 0 + width 440 > 432)
Mar 01 16:53:06 serw13 cosmic-session[3613]: 2024-03-01T23:53:06.068695Z ERROR egl{platform="PLATFORM_WAYLAND_KHR" version=(1, 5)}:egl_context{ptr=98939939080992}:renderer_gles2: [GL] GL_INVALID_VALUE in glTexSubImage2D(xoffset 0 + width 440 > 432)
Mar 01 16:53:06 serw13 cosmic-session[3613]: 2024-03-01T23:53:06.068723Z ERROR egl{platform="PLATFORM_WAYLAND_KHR" version=(1, 5)}:egl_context{ptr=98939939080992}:renderer_gles2: [GL] GL_INVALID_VALUE in glTexSubImage2D(xoffset 0 + width 440 > 432)
Mar 01 16:53:28 serw13 cosmic-greeter[10291]: pam_unix(login:auth): conversation failed
Mar 01 16:53:28 serw13 cosmic-greeter[10291]: pam_unix(login:auth): auth could not identify password for [jacob]
Here's the whole journalctl file in case I missed something (note that I had to restart COSMIC Greeter earlier in the boot to get the login screen working in the first place): cosmic-greeter-lock-screen-failure.txt
This can be successfully worked around without losing the session using the following commands @jackpot51 gave me:
killall cosmic-greeter
WAYLAND_DISPLAY=wayland-1 cosmic-greeter
I recently reorganized my Pictures folder, and moved the image I use for my wallpaper into a subdirectory.
When I launched cosmic-greeter as a lock-screen, the background was blank and black. When I check logs, I see:
[WARN cosmic_greeter::Locker] output wl_output@6: failed to load wallpaper "home/daniel/Pictures/wallpaper.png": Os { code: 2, kind: NotFound, message: "No such file or directory" }
This is replicated several times for each active display.
The behaviour on a reboot is similar, save that the default "Cosmic" wallpaper (the word Cosmic with a handful of stars on a whirly blue galaxy background) displays.
Howdie, thanks so much for sharing this project! <3
I haven't tried running cosmic-greeter as my greeter since the cosmic-greeter-daemon work, and I can't seem to get it to run as before
After systemctl disable greetd.service ; systemctl enable cosmic-greeter.service cosmic-greeter-daemon.service
, I reboot, and the system just sort of hangs or does nothing at the point where I'd usually see my other greeter (greetd) appear
I've also tried this with systemctl disable cosmic-greeter-daemon.service
but that doesn't seem to change any noticeable behaviour
What does work, is switching to a different virtual console, logging in there, and systemctl restart cosmic-greeter.service
I believe what's happened here is that systemd-homed systems ( https://systemd.io/HOME_DIRECTORY/ ) do not have users stored in /etc/passwd (my username does not appear listed here at all), and HOME directories are not even decrypted and mounted until after the user has logged in
I've briefly read through the cosmic-greeter-daemon code, and I believe it returns an empty Vec
because there aren't any users that pass the filter:
cosmic-greeter/daemon/src/main.rs
Line 59 in d133e60
But, I haven't yet found if/where cosmic-greeter would behave weirdly due to this
I figured I'd log this issue and come back once I've investigated more thoroughly, hopefully with a PR
needs design
Hello Cosmic Team,
First, I want to congratulate the team on the fantastic work with the new Cosmic DE. It's truly impressive!
I hope this is the right repo for this feature requests.
I have an idea that I believe could add an extra layer of polish and enhance the user experience even further. Inspired by macOS Sonoma, I think the following features would be great additions:
Smooth Transition Animations: macOS Sonoma features a seamless transition from the lock screen to the desktop, eliminating any flicker or brief black screens. Implementing a similar smooth animation in Cosmic DE would greatly enhance the visual experience. AFAIK, only macOS has this level of polish; Windows and Linux desktops do not.
Live Wallpaper Functionality: Another impressive feature in Sonoma is the live wallpaper. When the user is logged in, the wallpaper pauses, and when the screen is locked, the wallpaper becomes animated. Adding this dynamic element to the desktop environment could make it even more engaging and visually appealing.
Here is a demo video of the features I have been talkin' about:
https://github.com/user-attachments/assets/c3010a79-303d-424a-a0f6-ec33aaff1a87
Thank you for considering these suggestions. I believe they could significantly enhance the overall aesthetic and user experience of Cosmic.
Failed to build exited with exit code 1.
Its not possible to build the greeter for cosmic because git lfs is not supported throug Arch
While git LFS is pretty nifty, At least arch doesn't support it via makepkg officially. (It is possible to use an AUR package which is what im using for my own pkgbuild scripts) but it's not ideal.
PS. you can shrink the png to 640kb using ect (or to 372kb using JXL lossless but image-rs doesn't support jxl yet and it's unclear when they will be willing to) if size is a factor
On a system with an internal display (eDP-1) and an external display (DP-1) such that the two displays are aligned at their bottoms with eDP-1 at the left edge of DP-1, the session starts with displays correct, and maintains display layout in the lock-screen.
But, when first logging in, the displays are such that they are top edge aligned with eDP-1 to the right of DP-1. This was the default layout that was generated the first time that DP-1 was attached to the system. However, across many unplug-replug cycles, the displays have consistently resumed my user-set arrangement everywhere except for initial session login.
Seems like some permission issue with cosmic-greeter
causes cosmic-comp
to panic (cosmic-greeter
is never displayed, just the message in lines 116-132 in the attached file repeatedly being refreshed).
Output of journalctl -e
:
journalctl_greeter.txt
I started cosmic-session
from a different tty at the end and it starts up fine.
Sorry if it is a bit early to report an issue on something just implemented.
I noticed my Odyssey G9 picks up some ghosting of my wallpaper image if I leave my home desktop locked all day. Seeing ghosting on such a display makes me uneasy, so I would be much more likely to use COSMIC DE as my daily driver on this setup if the lock screen could make my displays go into standby mode. This would also be good for OLED and plasma displays.
I'm unsure if this is an issue with the greeter, but some apps request login keyring to get unlocked despite logging in properly through cosmic-greeter (in my case it was the Minecraft flatpak, issue doesn't seem to occur with other flatpaks).
OS: Fedora Silverblue 39 with COSMIC rpms applied
When I log in with cosmic-greeter, and run podman start {CONTAINER_ID}, I get an error similar to this:
sd-bus call: Process org.freedesktop.systemd1 exited with status 1: Input/output error
I followed an issue train:
containers/podman#13429
containers/buildah#4293
https://bugzilla.redhat.com/show_bug.cgi?id=1622259
Apparently, when $DBUS_SESSION_BUS_ADDRESS
is unset, podman/toolbox just fails.
I tried logging in with GDM, and running the toolbox works
when running in greeter mode (not lock-screen mode), I can press Tab multiple times and see that the password input box is focused, then seemingly nothing, then each of the buttons (e.g. shutdown) in that row under the clock, then back to the password input box
so it seems as though the session selector is correctly in the expected position in the Tab/focus order, but there's no visual indication that it is focused, and pressing Enter or Space or the arrow keys doesn't seem to display the list of sessions or change the selected session
I think it's possibly something to do with the way the button widget and the dropdown list are associated, but I'm not sure yet:
Lines 966 to 1040 in cc744b0
The Show Passwork Icon, right at the password entry area, does not actually show the password, It does nothing.
After #11, cosmic-greeter will run in the background process. It currently reads the background data and keeps it around. That should instead be done only when locked, and after unlocking it should trim malloc to reduce memory usage.
After today's update, COSMIC Greeter opened with a resolution of 640x480 (4:3), and my session did too. It's impossible to fix in the settings, and I can only resolve it by turning the monitor off and on again.
However, if I shut down my session, COSMIC Greeter returns to 640x480, but at least my desktop doesn't once I log in the second time.
When logging in using a fingerprint, there is currently a confirm button that needs to be pressed after the fingerprint has been read. Ideally, I would prefer to log in directly without having to press the confirm button once the fingerprint is read.
I can't reliably reproduce this, but I'd say about half the time the password field is not focused when opening my laptop.
With the current master branch of cosmic-greeter, the display manager won't launch with the error "configured default user ‘cosmic-greeter’ not found". I am building cosmic-epoch with all submodules updated using git submodule update --remote
with a Containerfile for a Fedora ostree image. The Container file is here: https://github.com/ryanabx/fedora-cosmic-atomic/blob/876895d2e3bc2740631ad62c165fa7ad8178d0e2/containers/fedora-cosmic-atomic/Containerfile
To fix this, I have to run some of the postinstall script in https://github.com/pop-os/cosmic-greeter/blob/master/debian/cosmic-greeter.postinst manually.
I had to create a cosmic-greeter
user with useradd
(adduser doesn't exist on a Fedora base image), make sure it is in the cosmic-greeter
group, and that it has a home directory at /var/lib/cosmic-greeter
I don't know if this should be a manual process on my part, so I'm writing this as an issue. GDM and SDDM automatically work from a regular install but then again I am installing them from the .rpm instead of building manually.
I'd also suggest if possible that some of the postinstall script instead use the more ubiquitous useradd
and groupadd
as opposed to adduser
and addgroup
.
when no "realname" is available, no name is being shown during login. Which can be confusing when having multiple users, as it's just blank
GDM used to have a [greeter]
section available in it's config, that allowed for inclusion or exclusion of certain users from the login screen. The config is still documented on the Gnome Help website:
5.4.4. Greeter Options
[greeter]
IncludeAll
IncludeAll=true
If true, then the face browser will show all users on the local machine. If false, the face browser will only show users who have recently logged in.
When this key is true, GDM will call fgetpwent() to get a list of local users on the system. Any users with a user id less than 500 (or 100 if running on Oracle Solaris) are filtered out. The Face Browser also will display any users that have previously logged in on the system (for example NIS/LDAP users). It gets this list via calling the ck-history ConsoleKit interface. It will also filter out any users which do not have a valid shell (valid shells are any shell that getusershell() returns - /sbin/nologin or /bin/false are considered invalid shells even if getusershell() returns them).
If false, then GDM more simply only displays users that have previously logged in on the system (local or NIS/LDAP users) by calling the ck-history ConsoleKit interface.
Include
Include=
Set to a list of users to always include in the Face Browser. This value is set to a list of users separated by commas. By default, the value is empty.
Exclude
Exclude=bin,root,daemon,adm,lp,sync,shutdown,halt,mail,news,uucp,operator,nobody,nobody4,noaccess,postgres,pvm,rpm,nfsnobody,pcap
Set to a list of users to always exclude in the Face Browser. This value is set to a list of users separated by commas. Note that the setting in the custom.conf overrides the default value, so if you wish to add additional users to the list, then you need to set the value to the default value with additional users appended to the list.
Source: https://help.gnome.org/admin/gdm/stable/configuration.html.en#greetersection
This was, unfortunately, removed when migrating to AccountsService over a decade ago:
I would like to request that COSMIC Greeter not make this same mistake, and leave the customization up to the user. At a minimum, I would like the ability to have certain users always displayed (via the Include
option) regardless of their account state.
This also benefits managed devices, where the user account may be locked, but should still be displayed on the login screen, in order to easily display messages regarding the account status when attempting to log in, and also facilitate password changes from the login screen, etc.
I'm uncertain when this began to be an issue, but I am finding I can no longer launch Gnome sessions using Wayland. I can launch Xorg Gnome sessions intermittently - though something in how those sessions launch is breaking Pop extensions for Gnome - but when ever I attempt to launch a Wayland session of Gnome, the screen goes black, as though it is launching a session, and immediately returns me to the greeter
login prompt.
In case it's helpful, I've noticed that lock screen working or not working seems to be consistent throughout any single cosmic session. If I start a session and it's working, it'll keep working until I logout/restart/etc.
I tested cosmic-greeter 0d7624b as display manager on a handful of graphics setups and found consistent behaviour across all of them.
I looked at integrated Intel and AMD graphics, discrete Nvidia and AMD desktop graphics, and a hybrid laptop with Intel iGPU and Nvidia dGPU.
Subjectively, the cosmic-session did feel like it loaded (drawing panel, dock, etc.) more slowly through cosmic-greeter vs. gdm, though that maybe a result of the desktop background being present in the DM.
All systems successfully logged in when first booted. On all systems, I could logout of the user session, and return to the DM login screen. I could login and logout multiple times.
On all systems, after several cycles of logging in and out, I would attempt another login and the user session would never launch. This usually took the form - symptomatically - of seeing the password prompt in cosmic-greeter disappear, and then nothing happening. Cosmic-greeter is responsive (e.g. I can shutdown with the GUI power button) in this state, it is just that the cosmic-session never starts. I need to look into this further.
I did not see any issue with cosmic-greeter displaying correctly when I logged out through the panel applet. However, on all hardware, I did see TTY1 getting stuck on a grey screen with a cursor when I exited my cosmic-session using the Super + Shift + Escape
shortcut. On all hardware, I also saw the lockscreen provided by cosmic-greeter similarly getting stuck on a grey screen when triggered with the Super + Escape
shortcut, but have yet to try it through the applet.
I am trying out cosmic-greeter on an Asus ZenBook with two screens. My main screen is 4k, and the other screen is positioned in the trackpad and portrait by default.
I am looking for a way to change the scaling for cosmic-greeter as it is way too small on my 4k main screen.
Additionally I would like a way to disable a screen/monitor (my trackpad screen), as it is completely useless on Linux.
It appears cosmic-greeting uses the same screen settings as the desktop, but only after having logged in. Upon startup everything is very small.
I do not believe this is currently possible, so it'd be much appreciated.
It's common functionality in plasma for example, that let you choose if you want to write down password each time you wake from suspend or not. Same with powering system on.
I only updated recently so I didn't realize I had didn't have cosmic-greeter-daemon
running. But with the latest commit it implicitly enabled it.
I did downgrade/remove the want section, try it again, and it worked, manually enabled cosmic-greeter-daemon
and it indeed just left me with a gray screen. Once cosmic-greeter-daemon
breaks cosmic, a downgrade and restart is needed simply restarting cosmic-greeter is not good enough.
Logs were made using journalctl --boot -g cosmic > logs/cosmic-greeter-good.txt
good log:
cosmic-greeter-good.txt
bad log:
cosmic-greeter-bad.txt
This happens about 90% of the time then randomly will just work - after starting my laptop with Cosmic installed, I see the login screen and enter my password, then afterwards the password entry box disappears but user is never logged in and it just sits there at the login screen. Everything is still clickable. There is just a user with avatar picture and no password entry box, but the other controls are still available. I can successfully restart from here but that's about it.
Usually I'm able to log-in but sometimes the greeter doesn't seem to work as expected.
I don't get the error message(below) in all of those occasions but I did got it once.
unable to send message: Transport endpoint is not connected (os error 107)
Let me know if anything on my end would fix this for me.
When #27 is merged, it will be possible to save a file to some path like /run/user/$UID/cosmic-greeter-$XDG_SESSION_ID
to denote when the session is supposed to be locked. This file can be used to automatically relock the session if either the compositor or the lock screen died and were restarted.
When launching a Pop!_OS 22.04 xorg Gnome session with Cosmic-Greeter, functionalities of the Cosmic extentions for Gnome do not work.
This includes:
super + q
to quit applications and super + f
to launch the file manager;super + f
when the desktop was the last item focused;These were just immediate issues. I'm truncating journal logs to drop in a subsequent comment (because no one needs 13000 lines when most of them aren't germane.)
Jun 07 20:45:10 pop-os kernel: greetd[30377]: segfault at 7ffc49729f98 ip 0000782fd5075048 sp 00007ffc49729f90 error 6 in libc.so.6[782fd5028000+195000] likely on CPU 6 (core 6, socket 0)
I was thinking about how in the past I've seen people ask if there was any ways to enable a PIN log-in for Linux and I think it would help make the desktop even easier for people to use.
I would probably limit it to just being used to log in and unlock any sessions already logged in. It would probably still be better if anything that requires root or 'sudo' still needs an admin password to fully authenticate.
Edit: I'm not sure if this applies only to comisc-greeter or if it will have to be implemented elsewhere.
Howdie, thanks so much for sharing this exciting work! <3
I wanted to report this just so that it's tracked/known, even though the actual fix is probably upstream: 1wilkens/pam-sys#27
After resuming from a suspend (and perhaps on boot), the screen is locked and the password input is visible, but not focused. Pressing the tab key (any number of times) does not visibly focus the input and instead I'm forced to focus with a mouse.
It updates after moving the mouse.
Such as the title
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.