Reader small image

You're reading from  Mastering Linux Security and Hardening - Third Edition

Product typeBook
Published inFeb 2023
Reading LevelIntermediate
PublisherPackt
ISBN-139781837630516
Edition3rd Edition
Languages
Tools
Right arrow
Author (1)
Donald A. Tevault
Donald A. Tevault
author image
Donald A. Tevault

Donald A. Tevault - but you can call him Donnie - got involved with Linux way back in 2006, and has been working with it ever since. He holds the Linux Professional Institute Level 3-Security certification, and the GIAC Incident Handler certification. Donnie is a professional Linux trainer, and thanks to the magic of the internet, teaches Linux classes literally the world over from the comfort of his living room. He's also a Linux security researcher for an IoT security company.
Read more about Donald A. Tevault

Right arrow

Configuring other miscellaneous security settings

Our SSH configuration is a lot more secure than it used to be, but we can still make it better. Here are a few little tricks that you might not have seen elsewhere.

Disabling X11 forwarding

When you SSH into a server in the normal manner, as we’ve been doing, you can only run text-mode programs. If you try to remotely run any GUI-based program, such as Firefox, you’ll get an error message. But, when you open the sshd_config file of pretty much any Linux distro, you’ll see this line:

X11Forwarding yes

This means that with the right option switch, you can remotely run GUI-based programs. Assuming that you’re logging into a machine that has a graphical desktop environment installed, you can use either the -Y or the -X option when logging in, like so:

ssh -X donnie@192.168.0.12

or

ssh -Y donnie@192.168.0.12

The problem here is that the X11 protocol, which powers graphical desktop...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Mastering Linux Security and Hardening - Third Edition
Published in: Feb 2023Publisher: PacktISBN-13: 9781837630516

Author (1)

author image
Donald A. Tevault

Donald A. Tevault - but you can call him Donnie - got involved with Linux way back in 2006, and has been working with it ever since. He holds the Linux Professional Institute Level 3-Security certification, and the GIAC Incident Handler certification. Donnie is a professional Linux trainer, and thanks to the magic of the internet, teaches Linux classes literally the world over from the comfort of his living room. He's also a Linux security researcher for an IoT security company.
Read more about Donald A. Tevault