News for hackers. Stuff that matters.
Re:HW accelerated Xwayland rendering for Nvidia merged by espadrine on Friday April 09, 2021 @06:16PM (#26756870)
I’d like to emphasize a major aspect that makes the switch a non-brainer: SECURITY.

The “good old days” of unencrypted Internet, where everyone could see your cookies, are no longer acceptable; the same is true of X11.

With X11, if you copy a password from your manager, you must assume all running apps now know it and transmitted it to a malicious server. There’s no way to tell.

With Wayland, it is only transmitted upon pasting, and only done directly from the copier app to the paster app.

With X11, everything displayed on the screen is compromised. Also, all inputs, keyboard and otherwise.

With Wayland, each app only sees their own pixels.

With X11, screen locking is pure hackery that doesn’t always protect the locked pixels and… login password.

Traditionally, you are meant to trust that process boundaries on Linux are sacredly secure, which is why Spectre was a big deal. But in practice, that is only true under Wayland.

Re:HW accelerated Xwayland rendering for Nvidia merged by marwis on Friday April 09, 2021 @08:16PM (#26757743)
X11 is also just a protocol and you can implement it securely and expose access control through extensions. In fact it already exists (XACE) just nobody is using it.
Re:HW accelerated Xwayland rendering for Nvidia merged by the_why_of_y on Saturday April 10, 2021 @05:16AM (#26760135)
XACE is basically an extension of SELinux into userspace for X11. Given that today Fedora/RHEL are the only distros that enable SELinux out of the box, such an approach would have been doomed to failure (or doomed to provide a product differentiator for RHEL in the best case) - not to mention the sheer joy and excitement that debugging SELinux AVC denials would produce for end users and desktop application developers.

https://www.freedesktop.org/software/XDevConf/x-security-wal...

Re:HW accelerated Xwayland rendering for Nvidia merged by jude- on Saturday April 10, 2021 @12:11AM (#26758850)
Exactly! It astonishes me that Wayland folks think that replacing the whole graphics stack is somehow easier than using an X extension that already exists. Really speaks to the profound immaturity of the project.
Re:HW accelerated Xwayland rendering for Nvidia merged by cycomanic on Saturday April 10, 2021 @12:46AM (#26759004)
My god, those "wayland folks" were the same people developing X. They were not some unrelated people pushing an agenda. It's always fascinating to see all the arm chair experts saying things how things ought to be done without ever having written a X extension or anything of that sort.
Re:HW accelerated Xwayland rendering for Nvidia merged by wander_homer on Saturday April 10, 2021 @02:21AM (#26759387)
So the fact that someone was a developer of X, means their resilient to following some agenda or non objective opinion? There's a really famous and often quoted talk about X vs Wayland from one of those developers and it was clearly made in a way to present Wayland in a better light by purposely portraying X11 in a bad way, for example by leaving out crucial details. Like in one example they picked on the slow startup time of applications and attributed it to the blocking calls made to X.org, without even mentioning that asynchronous alternatives are not only available, but toolkits like Qt were already using them exclusively at that time. The verdict of course was that X11 is broken and fixing that is almost impossible.
Re:HW accelerated Xwayland rendering for Nvidia merged by Szpadel on Saturday April 10, 2021 @08:29AM (#26760997)
X11 was designed to everything like OS, it's display server, gui library, font manager, printing server and more, X11 was ment to be like qt or gtk, you tell it that you want to display input and it will draw it for you, the issue now it that basically every app now display every window as one bitmap, because we do not want to use 98% of the x11. Also why do you think there wasn't much development activity in X for years now? There is so much wrong with it's state that nobody wants to work with it. It's like talking: why someone would like to use rust or go or c# when we have cobol? why not just write cobol extension?
Re:HW accelerated Xwayland rendering for Nvidia merged by wander_homer on Saturday April 10, 2021 @08:56AM (#26761140)
I'm not really sure what you're getting at. Like I never said there's no point in using or developing Wayland. I was addressing the statement, that Wayland was build by former X11 developers, which supposedly makes them purely objective authorities. Of course, that's not the case as, can be seen by the example I gave.
Re:HW accelerated Xwayland rendering for Nvidia merged by cycomanic on Saturday April 10, 2021 @02:25PM (#26763720)
No, you're arguing a strawman. What I'm saying is, if you have never even tried writing an X extension, likely never properly looked at the X protocol (let alone it's implementation) you have no leg to stand on to make technical criticism of the people who did the work and then decided it was too much work and build something else.
Re:HW accelerated Xwayland rendering for Nvidia merged by jude- on Saturday April 10, 2021 @06:46PM (#26765956)
And, have you written a Wayland extension and a X11 extension and learned the difference? No? Then why should we listen to you?
Re:HW accelerated Xwayland rendering for Nvidia merged by taway098123 on Monday April 12, 2021 @07:50PM (#26786566)
There isn't really much difference. It's about the same amount of work either way to ship an extension.

In Wayland, you make the extension, then you patch every compositor, every toolkit and every application.

In X11, you make the extension, then you patch the X server, Xlib, XCB, every window manager, every toolkit, and every application.

Re:HW accelerated Xwayland rendering for Nvidia merged by jude- on Tuesday April 13, 2021 @03:52AM (#26789341)
The question was related to the relative difficulty of replacing the whole graphics stack vs. patching in support for an X extension that has existed for longer than Wayland. One of these things is far, far less work than the other.
Re:HW accelerated Xwayland rendering for Nvidia merged by taway098123 on Tuesday April 13, 2021 @12:06PM (#26794354)
As someone who has done both, I respectfully disagree.
Re:HW accelerated Xwayland rendering for Nvidia merged by jude- on Tuesday April 13, 2021 @02:47PM (#26797147)
I call bullshit. If you had done so, you would have shared links to them to prove your point.
Re:HW accelerated Xwayland rendering for Nvidia merged by taway098123 on Tuesday April 13, 2021 @02:59PM (#26797330)
There's no code I can show you that would be any more convincing than just looking at the code to the X server and then looking at the code to any wayland implementation. There's not anything particularly special about these projects.
Re:HW accelerated Xwayland rendering for Nvidia merged by atq2119 on Saturday April 10, 2021 @02:27AM (#26759410)
> With X11, if you copy a password from your manager, you must assume all running apps now know it and transmitted it to a malicious server. There’s no way to tell.

With Wayland, it is only transmitted upon pasting, and only done directly from the copier app to the paster app.

Can you elaborate?

This sounds implausible, wishful thinking since key bindings are managed by individual applications. Whoever holds the clipboard must trust the application that claims to have received a paste command from the user. I don't see anything that could prevent spoofing without just blocking clipboard access entirely or making the usability a lot worse.

Re:HW accelerated Xwayland rendering for Nvidia merged by espadrine on Saturday April 10, 2021 @06:55AM (#26760545)
In X11, every client is equal.

In Wayland, the compositor has special standing. For instance, KWin will only allow the currently active window to paste.

There is more information here: https://phabricator.kde.org/T4449#192501

Re:HW accelerated Xwayland rendering for Nvidia merged by atq2119 on Saturday April 10, 2021 @03:56PM (#26764552)
Leaving aside for the moment that this policy is only a partial protection against a malicious client, the same policy could well be implemented in X11. (The window manager is not fully equal.)

At a meta level, this is probably the most frustrating thing about Wayland: all of its benefits could be realized in the X context itself, even the getting rid of legacy baggage (deprecate parts of the protocol leading up to the definition of an X12).

People actively chose not to do this and instead delayed progress by at least a decade.

Ideally, Wayland would have just served as a tech demo to guide the evolution of X. But as a community, we give too much credit to people working on shiny new things.

Re:HW accelerated Xwayland rendering for Nvidia merged by espadrine on Sunday April 11, 2021 @01:07PM (#26771792)
X12 is simply called Wayland.
Re:HW accelerated Xwayland rendering for Nvidia merged by jrm4 on Sunday April 11, 2021 @12:19AM (#26767458)
Again, long time Linux user and this really doesn't tell me why Wayland is good, it tells me that the Linux ecosystem is getting frog-boiled into accepting the same sort of frightfully dumb practices that the other operating systems have been doing for years? How did we get to a place where I have to pit the security of some of my apps against other apps?
Re:HW accelerated Xwayland rendering for Nvidia merged by stingraycharles on Saturday April 10, 2021 @01:58AM (#26759287)
“With X11, everything displayed on the screen is compromised. Also, all inputs, keyboard and otherwise.

”With Wayland, each app only sees their own pixels.”

Out of curiosity, if this is true, how are screenshots / screen recorders implemented? Do they require some special permissions? And if this is the case, why wouldn’t any app be able to acquire these special permissions?

Re:HW accelerated Xwayland rendering for Nvidia merged by dijit on Saturday April 10, 2021 @02:57AM (#26759527)
This is currently why a lot of people are complaining screen recorders do not work.

There are solutions to this, which allow finer grained access to screen recording in future, but there are a couple of competing standards right now.