Codex

Auth

Section: User Contributed Perl Documentation (3pm)

Updated: 2006-01-19

Index?action=index Return to Main Contents


NAME

X11::Auth - Perl module to read X11 authority files

SYNOPSIS

DESCRIPTION

This module is an approximate perl replacement for the libXau C library and the xauth?(1) program. It reads and interprets the files (usually '~/.Xauthority') that hold authorization data used in connecting to X servers. Since it was written mainly for the use of X11::Protocol, its functionality is currently restricted to reading, not writing, of these files.

METHODS

new

Open an authority file, and create an object to handle it. The filename will be taken from the XAUTHORITY environment variable, if present, or '.Xauthority' in the user's home directory, or it may be overridden by an argument. 'open' may be used as a synonym.

get_one

Read one entry from the file. Returns a null list at end of file. is usually 'Internet' or 'Local', and can be any string.

get_all

Read all of the entries in the file. Each member of the array returned is an array ref similar to the list returned by get_one().

get_by_host

Get authentication data for a connection of type to display on . If is 'Internet', the host will be translated into an appropriate address by gethostbyname(). If no data is found, returns an empty list.

COMPATIBILITY

The following table shows the (rough) correspondence between libXau calls and X11::Auth methods:

AUTHOR

Stephen McCamant <[email protected]>

SEE ALSO

perl?(1), X11::Protocol, Xau?(3), xauth?(1), lib/Xau/README in the X11 source distribution.


Index

NAME

SYNOPSIS

DESCRIPTION

METHODS

new

get_one

get_all

get_by_host

COMPATIBILITY

AUTHOR

SEE ALSO