secureblue / hardened-chromium

A hardened chromium for desktop Linux inspired by Vanadium.
GNU General Public License v2.0
22 stars 5 forks source link

Invisible top bar #26

Closed kreativK closed 1 month ago

kreativK commented 1 month ago

Screenshot_20240801_163931 Screenshot_20240801_164022

The top bar is invisible. I can still search for stuff, but I can't see what I type and I can't minimize or close the program as usual because those buttons are gone.

When running the program in the console with the "chromium-browser" command, the following is flooding the console:

[24129:24172:0801/163633.198269:ERROR:client_shared_image.cc(294)] Unable to create ScopedMapping [24129:24172:0801/163633.198274:ERROR:one_copy_raster_buffer_provider.cc(355)] MapSharedImage Failed. [24129:24172:0801/163633.198540:ERROR:client_native_pixmap_dmabuf.cc(45)] Failed to mmap dmabuf: Invalid argument (22) [24129:24172:0801/163633.198551:ERROR:client_shared_image.cc(156)] Failed to map the buffer. [24129:24172:0801/163633.198556:ERROR:client_shared_image.cc(142)] ScopedMapping init failed. [24129:24172:0801/163633.198562:ERROR:client_shared_image.cc(294)] Unable to create ScopedMapping

My image is kinoite-asus-nvidia-userns-hardened and I use unstable hardened kargs.

Output of ujust check-local-overrides:

diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/authselect/authselect.conf /etc/authselect/authselect.conf 4c4 < with-faillock

with-fingerprint diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/authselect/dconf-db /etc/authselect/dconf-db 8c8 < enable-fingerprint-authentication=false

enable-fingerprint-authentication=true diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/authselect/fingerprint-auth /etc/authselect/fingerprint-auth 6c6,19 < auth required pam_debug.so auth=authinfo_unavail

auth required pam_env.so auth [success=done default=bad] pam_fprintd.so auth required pam_deny.so

account required pam_unix.so account required pam_permit.so

password required pam_deny.so

session optional pam_keyinit.so revoke session required pam_limits.so -session optional pam_systemd.so session [success=1 default=ignore] pam_succeed_if.so service in crond quiet use_uid session required pam_unix.so diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/authselect/system-auth /etc/authselect/system-auth 8c8 < auth required pam_faillock.so preauth silent

auth sufficient pam_fprintd.so 10d9 < auth required pam_faillock.so authfail 13d11 < account required pam_faillock.so Only in /etc: colord Only in /etc/cups: subscriptions.conf.O Only in /etc: libvirt Only in /etc/nvme: hostid Only in /etc/nvme: hostnqn diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/profile.d/flatpak.sh /etc/profile.d/flatpak.sh 28a29 LD_PRELOAD=/var/run/host/usr/lib64/glibc-hwcaps/x86-64-v3/libhardened_malloc.so Only in /etc: .rpm-ostree-shadow-mode-fixed2.stamp Only in /etc/sysconfig: anaconda Only in /etc/sysconfig: network diff -r --suppress-common-lines '--color=always' --exclude 'passwd' --exclude 'group' '--exclude=subgid' '--exclude=subuid' '--exclude=machine-id' '--exclude=adjtime' '--exclude=fstab' '--exclude=system-connections' '--exclude=shadow' '--exclude=gshadow' '--exclude=ssh_host' '--exclude=cmdline' '--exclude=crypttab' '--exclude=hostname' '--exclude=localtime' '--exclude=locale' '--exclude=lock' '--exclude=.updated' '--exclude=LOCK' '--exclude=vconsole' '--exclude=00-keyboard.conf' '--exclude=grub' '--exclude=system.control' '--exclude=cdi' '--exclude=default.target' /usr/etc/systemd/resolved.conf.d/securedns.conf /etc/systemd/resolved.conf.d/securedns.conf 2,3c2,7 < DNSSEC=allow-downgrade < DNSOverTLS=opportunistic

DNSOverTLS=yes Only in /etc/systemd/system/basic.target.wants: usbguard.service Only in /etc/systemd/system: dbus-org.usbguard.service Only in /etc/systemd/system/multi-user.target.wants: usbguard-dbus.service Only in /usr/etc/systemd/system/sysinit.target.wants: dmraid-activation.service Only in /etc/usbguard/IPCAccessControl.d: root

RKNF404 commented 1 month ago

When did this happen? Did you just launch it and it was gone or was it never there?

kreativK commented 1 month ago

When did this happen? Did you just launch it and it was gone or was it never there?

It worked when I first installed my system a few days ago but I switched to brave and didn't run it again until yesterday. Now it's just gone, can't get it back with a restart.

RKNF404 commented 1 month ago

Odd, I'm assuming you are certain you were running hardened chromium when it did work, because it shipped recently so there is a chance you weren't.

kreativK commented 1 month ago

Odd, I'm assuming you are certain you were running hardened chromium when it did work, because it shipped recently so there is a chance you weren't.

I installed the system on the 29th of july. I'm certain I ran the browser that was packaged with secureblue, named chromium web browser and with the blue chromium icon, which should be the same one causing errors right now. I don't know if anything has changed since then and I don't know if you just shipped regular chromium or hardened at the time.

RKNF404 commented 1 month ago

29th of July

Lol, thats the day it shipped. All the info around the icon is the same between hardened and regular chromium. Would you be willing to test run it under X11 if you haven't already? (You would need to enable XWayland)

kreativK commented 1 month ago

29th of July

Lol, thats the day it shipped. All the info around the icon is the same between hardened and regular chromium. Would you be willing to test run it under X11 if you haven't already? (You would need to enable XWayland)

Sorry, I see now that it actually was the 28th. I toggled XWayland and ran chromium-browser --backend=x11-backend.so --xwayland, it made no difference.

kreativK commented 1 month ago

I see now that before it starts spamming the konsole with the errors provided above, it gives these errors:

[30715:30737:0801/174829.638666:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Code Cache/js [30715:30752:0801/174829.638677:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Code Cache/wasm [30715:30752:0801/174829.638774:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Code Cache/wasm [30715:30752:0801/174829.638778:ERROR:simple_backend_impl.cc(751)] Simple Cache Backend: wrong file structure on disk: 1 path: /dev/null/Default/Code Cache/wasm [30715:30737:0801/174829.638781:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Code Cache/js [30715:30737:0801/174829.638790:ERROR:simple_backend_impl.cc(751)] Simple Cache Backend: wrong file structure on disk: 1 path: /dev/null/Default/Code Cache/js [30715:30764:0801/174829.638862:ERROR:disk_cache.cc(208)] Unable to create cache [30715:30764:0801/174829.638875:ERROR:disk_cache.cc(208)] Unable to create cache Warning: disabling flag --expose_wasm due to conflicting flags [30762:30803:0801/174829.760206:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Cache/Cache_Data [30762:30803:0801/174829.760604:ERROR:simple_backend_impl.cc(79)] Failed to create directory: /dev/null/Default/Cache/Cache_Data [30762:30803:0801/174829.760612:ERROR:simple_backend_impl.cc(751)] Simple Cache Backend: wrong file structure on disk: 1 path: /dev/null/Default/Cache/Cache_Data [30762:30806:0801/174829.760835:ERROR:disk_cache.cc(208)] Unable to create cache

34N0 commented 1 month ago

Did you change your home directory /partition?

What happens if you clear the browsee cache by deleting the content in $HOME/.cache/google-chrome/Default/Cache ?

RKNF404 commented 1 month ago

@34N0 Cache is disabled, these errors are normal. So are the wasm errors.

@kreativK

--backend=x11-backend.so

I'm not sure this works, maybe it does. I meant try chromium-browser --ozone-platform=x11

kreativK commented 1 month ago

@34N0 Cache is disabled, these errors are normal. So are the wasm errors.

@kreativK

--backend=x11-backend.so

I'm not sure this works, maybe it does. I meant try chromium-browser --ozone-platform=x11

This fixed it!

RKNF404 commented 1 month ago

@kreativK Awesome, I guess chromium isn't too stable on wayland+nvidia yet.

Could also just be a wayland+nvidia thing relating to decorations, idk.

RKNF404 commented 1 month ago

you can set it to always run in x11 in about:flags -> search "Preferred Ozone platform" -> set it to x11.

kreativK commented 1 month ago

@kreativK Awesome, I guess chromium isn't too stable on wayland+nvidia yet.

Could also just be a wayland+nvidia thing relating to decorations, idk.

Yeah maybe. Something similar happened with brave, it couldn't open without --ozone-platform=wayland, but I could change the ozone flag to Wayland and I didn't need to enable XWayland.

you can set it to always run in x11 in about:flags -> search "Preferred Ozone platform" -> set it to x11.

This weirdly doesn't work, and setting it to Wayland doesn't work either. I have to manually run it with "chromium-browser --ozone-platform=x11", otherwise the top bar stays invisible.

kreativK commented 1 month ago

Did you change your home directory /partition?

What happens if you clear the browsee cache by deleting the content in $HOME/.cache/google-chrome/Default/Cache ?

I haven't changed my home directory or partition

RKNF404 commented 1 month ago

This weirdly doesn't work, and setting it to Wayland doesn't work either. I have to manually run it with "chromium-browser --ozone-platform=x11", otherwise the top bar stays invisible.

... huh. Strange. They do the same thing? Does --ozone-platform=x11 or --ozone-platform-hint=x11 show under Command Line in about:version when you run it without the commandline flag but with the about:flags toggle?

kreativK commented 1 month ago

... huh. Strange. They do the same thing?

Yeah, they both have the top bar invisible.

Does --ozone-platform=x11 or --ozone-platform-hint=x11 show under Command Line in about:version when you run it without the commandline flag but with the about:flags toggle?

No, it says --ozone-platform=wayland in about:version even tho its toggled to x11 in about:flags

RKNF404 commented 1 month ago

Yeah, they both have the top bar invisible.

Wdym both?

No, it says --ozone-platform=wayland in about:version even tho its toggled to x11 in about:flags

Did you restart after doing it?

kreativK commented 1 month ago

Wdym both?

When you asked if they do the same thing I thought you meant setting the ozone about:flags to X11 and Wayland.

Did you restart after doing it?

Restarting chromium after toggling to X11? If so, yes.

RKNF404 commented 1 month ago

When you asked if they do the same thing I thought you meant setting the ozone about:flags to X11 and Wayland.

Sorry, I meant the commandline flags and UI flag. They should do the same thing...

Restarting chromium after toggling to X11? If so, yes.

I think I know what the issue is but I'm not sure, you can add the flag to /etc/chromium.conf in the mean time.

kreativK commented 1 month ago

Sorry, I meant the commandline flags and UI flag. They should do the same thing...

Oh, yeah weirdly they don't.

I think I know what the issue is but I'm not sure, you can add the flag to /etc/chromium.conf in the mean time.

I FIXED IT! In /etc/chromium.conf, NATIVE_WAYLAND was turned off. I edited it to on and now it starts as it should, I can even toggle XWayland to off. Changed the ozone about:flags to wayland and no difference, everything just works as it should!

RKNF404 commented 1 month ago

... huh. Alright. That seems like something we need to fix then, alter the chromium.conf for that I guess. Thank you.

kreativK commented 1 month ago

Yeah, thx for the help!