UBTU-20-010048 - The Ubuntu operating system must be configured so that remote X connections are disabled, unless to fulfill documented and validated mission requirements.

Warning! Audit Deprecated

This audit has been deprecated and will be removed in a future update.

View Next Audit Version

Information

The security risk of using X11 forwarding is that the client's X11 display server may be exposed to attack when the SSH client requests forwarding. A System Administrator may have a stance in which they want to protect clients that may expose themselves to attack by unwittingly requesting X11 forwarding, which can warrant a ''no'' setting.

X11 forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remote host (for the user's X11 authorization database) can access the local X11 display through the forwarded connection. An attacker may then be able to perform activities such as keystroke monitoring if the ForwardX11Trusted option is also enabled.

If X11 services are not required for the system's intended function, they should be disabled or restricted as appropriate to the system's needs.

Solution

Edit the '/etc/ssh/sshd_config' file to uncomment or add the line for the 'X11Forwarding' keyword and set its value to 'no' (this file may be named differently or be in a different location if using a version of SSH that is provided by a third-party vendor):

X11Forwarding no

Restart the SSH daemon for the changes to take effect:

$ sudo systemctl restart sshd.service

See Also

https://dl.dod.cyber.mil/wp-content/uploads/stigs/zip/U_CAN_Ubuntu_20-04_LTS_V1R9_STIG.zip

Item Details

References: CAT|I, CCI|CCI-000366, Rule-ID|SV-238219r858533_rule, STIG-ID|UBTU-20-010048, Vuln-ID|V-238219

Plugin: Unix

Control ID: e7891986bdde53ba1ec0e84f82672f5e1ebe326e351476e9411919fd012a8f4c