Security

This page describes access control and authentication mechanisms in X - and how you can implement your own.

This page does not describe security advisories. For that, see the SecurityPage.

Server Authentication

The core X protocol includes simple, host-based authentication. The familiar "xhost" client program is used to manipulate the list of allowable hosts.

The server supports a variety of additional authentication methods as add-ons. Authentication data is delivered to the server in the initial data that is sent by the connecting client. A string identifies the authentication method being used. The authentication methods currently supported in the X.Org xserver are:

The authentication code is located in the os directory of the xserver, in auth.c and other files. An update being considered would move the authentication methods out of the xserver and implement them as PAM modules (libraries).

Server Access Control

The X server has long included an extension, SECURITY, which provides support for a simple trusted/untrusted connection model. Untrusted clients are restricted in certain ways to prevent them from reading window contents of other clients, stealing input events, etc. Documentation for this extension is located in the xorg-docs package. This extension has several limitations:

Starting with release 7.2 the X server includes a general framework for building security extensions, the X Access Control Extension. The best place to start if you are a security extension writer is with the XACE documentation, which can be found in the xorg-docs package. XACE inherits from the SECURITY extension and has the same coverage problems, but work is ongoing to verify its coverage and extend it to new places, such as protocol extensions.


CategoryServerInternals