Skip to content
Search

Xauth

lastmod 2020-09-05created 2020-09-052 edits

xhost controls access using things like host names on the network, but when you want stricter access control, use xauth.

xauth uses an authentication string called a magic cookie. By setting the X server's cookie on the terminal that runs the X application, it serves as the key that controls access.

$ xauth list

Extract

The X server's cookie is sent to the terminal that runs the client. Use xauth extract to create an xauth instruction file, then pipe (|) it and use ssh to have the target host run xauth merge, which registers it on the target host.

$ xauth extract - $DISPLAY | ssh -l {사용자명} {실행단말기} xauth merge -

See also

Favorite site

author Zer0 sitemap