diff options
Diffstat (limited to '')
-rw-r--r-- | modules/pam_env/pam_env.8 | 158 | ||||
-rw-r--r-- | modules/pam_env/pam_env.8.xml | 263 |
2 files changed, 421 insertions, 0 deletions
diff --git a/modules/pam_env/pam_env.8 b/modules/pam_env/pam_env.8 new file mode 100644 index 0000000..2a3ea16 --- /dev/null +++ b/modules/pam_env/pam_env.8 @@ -0,0 +1,158 @@ +'\" t +.\" Title: pam_env +.\" Author: [see the "AUTHOR" section] +.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/> +.\" Date: 05/18/2017 +.\" Manual: Linux-PAM Manual +.\" Source: Linux-PAM Manual +.\" Language: English +.\" +.TH "PAM_ENV" "8" "05/18/2017" "Linux-PAM Manual" "Linux-PAM Manual" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +pam_env \- PAM module to set/unset environment variables +.SH "SYNOPSIS" +.HP \w'\fBpam_env\&.so\fR\ 'u +\fBpam_env\&.so\fR [debug] [conffile=\fIconf\-file\fR] [envfile=\fIenv\-file\fR] [readenv=\fI0|1\fR] [user_envfile=\fIenv\-file\fR] [user_readenv=\fI0|1\fR] +.SH "DESCRIPTION" +.PP +The pam_env PAM module allows the (un)setting of environment variables\&. Supported is the use of previously set environment variables as well as +\fIPAM_ITEM\fRs such as +\fIPAM_RHOST\fR\&. +.PP +By default rules for (un)setting of variables are taken from the config file +/etc/security/pam_env\&.conf\&. An alternate file can be specified with the +\fIconffile\fR +option\&. +.PP +Second a file (/etc/environment +by default) with simple +\fIKEY=VAL\fR +pairs on separate lines will be read\&. With the +\fIenvfile\fR +option an alternate file can be specified\&. And with the +\fIreadenv\fR +option this can be completly disabled\&. +.PP +Third it will read a user configuration file ($HOME/\&.pam_environment +by default)\&. The default file file can be changed with the +\fIuser_envfile\fR +option and it can be turned on and off with the +\fIuser_readenv\fR +option\&. +.PP +Since setting of PAM environment variables can have side effects to other modules, this module should be the last one on the stack\&. +.SH "OPTIONS" +.PP +\fBconffile=\fR\fB\fI/path/to/pam_env\&.conf\fR\fR +.RS 4 +Indicate an alternative +pam_env\&.conf +style configuration file to override the default\&. This can be useful when different services need different environments\&. +.RE +.PP +\fBdebug\fR +.RS 4 +A lot of debug information is printed with +\fBsyslog\fR(3)\&. +.RE +.PP +\fBenvfile=\fR\fB\fI/path/to/environment\fR\fR +.RS 4 +Indicate an alternative +environment +file to override the default\&. The syntax are simple +\fIKEY=VAL\fR +pairs on separate lines\&. The +\fIexport\fR +instruction can be specified for bash compatibility, but will be ignored\&. This can be useful when different services need different environments\&. +.RE +.PP +\fBreadenv=\fR\fB\fI0|1\fR\fR +.RS 4 +Turns on or off the reading of the file specified by envfile (0 is off, 1 is on)\&. By default this option is on\&. +.RE +.PP +\fBuser_envfile=\fR\fB\fIfilename\fR\fR +.RS 4 +Indicate an alternative +\&.pam_environment +file to override the default\&.The syntax is the same as for +\fI/etc/environment\fR\&. The filename is relative to the user home directory\&. This can be useful when different services need different environments\&. +.RE +.PP +\fBuser_readenv=\fR\fB\fI0|1\fR\fR +.RS 4 +Turns on or off the reading of the user specific environment file\&. 0 is off, 1 is on\&. By default this option is on\&. +.RE +.SH "MODULE TYPES PROVIDED" +.PP +The +\fBauth\fR +and +\fBsession\fR +module types are provided\&. +.SH "RETURN VALUES" +.PP +PAM_ABORT +.RS 4 +Not all relevant data or options could be gotten\&. +.RE +.PP +PAM_BUF_ERR +.RS 4 +Memory buffer error\&. +.RE +.PP +PAM_IGNORE +.RS 4 +No pam_env\&.conf and environment file was found\&. +.RE +.PP +PAM_SUCCESS +.RS 4 +Environment variables were set\&. +.RE +.SH "FILES" +.PP +/etc/security/pam_env\&.conf +.RS 4 +Default configuration file +.RE +.PP +/etc/environment +.RS 4 +Default environment file +.RE +.PP +$HOME/\&.pam_environment +.RS 4 +User specific environment file +.RE +.SH "SEE ALSO" +.PP +\fBpam_env.conf\fR(5), +\fBpam.d\fR(5), +\fBpam\fR(8), +\fBenviron\fR(7)\&. +.SH "AUTHOR" +.PP +pam_env was written by Dave Kinchlea <kinch@kinch\&.ark\&.com>\&. diff --git a/modules/pam_env/pam_env.8.xml b/modules/pam_env/pam_env.8.xml new file mode 100644 index 0000000..d6e20a2 --- /dev/null +++ b/modules/pam_env/pam_env.8.xml @@ -0,0 +1,263 @@ +<?xml version="1.0" encoding="ISO-8859-1"?> +<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" + "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"> + +<refentry id='pam_env'> + + <refmeta> + <refentrytitle>pam_env</refentrytitle> + <manvolnum>8</manvolnum> + <refmiscinfo class='setdesc'>Linux-PAM Manual</refmiscinfo> + </refmeta> + + <refnamediv id='pam_env-name'> + <refname>pam_env</refname> + <refpurpose> + PAM module to set/unset environment variables + </refpurpose> + </refnamediv> + +<!-- body begins here --> + + <refsynopsisdiv> + <cmdsynopsis id="pam_env-cmdsynopsis"> + <command>pam_env.so</command> + <arg choice="opt"> + debug + </arg> + <arg choice="opt"> + conffile=<replaceable>conf-file</replaceable> + </arg> + <arg choice="opt"> + envfile=<replaceable>env-file</replaceable> + </arg> + <arg choice="opt"> + readenv=<replaceable>0|1</replaceable> + </arg> + <arg choice="opt"> + user_envfile=<replaceable>env-file</replaceable> + </arg> + <arg choice="opt"> + user_readenv=<replaceable>0|1</replaceable> + </arg> + </cmdsynopsis> + </refsynopsisdiv> + + + <refsect1 id="pam_env-description"> + <title>DESCRIPTION</title> + <para> + The pam_env PAM module allows the (un)setting of environment + variables. Supported is the use of previously set environment + variables as well as <emphasis>PAM_ITEM</emphasis>s such as + <emphasis>PAM_RHOST</emphasis>. + </para> + <para> + By default rules for (un)setting of variables are taken from the + config file <filename>/etc/security/pam_env.conf</filename>. An + alternate file can be specified with the <emphasis>conffile</emphasis> + option. + </para> + <para> + Second a file (<filename>/etc/environment</filename> by default) with simple + <emphasis>KEY=VAL</emphasis> pairs on separate lines will be read. + With the <emphasis>envfile</emphasis> option an alternate file can be specified. + And with the <emphasis>readenv</emphasis> option this can be completly disabled. + </para> + <para> + Third it will read a user configuration file + (<filename>$HOME/.pam_environment</filename> by default). + The default file file can be changed with the + <emphasis>user_envfile</emphasis> option + and it can be turned on and off with the <emphasis>user_readenv</emphasis> option. + </para> + <para> + Since setting of PAM environment variables can have side effects + to other modules, this module should be the last one on the stack. + </para> + </refsect1> + + <refsect1 id="pam_env-options"> + <title>OPTIONS</title> + <variablelist> + + <varlistentry> + <term> + <option>conffile=<replaceable>/path/to/pam_env.conf</replaceable></option> + </term> + <listitem> + <para> + Indicate an alternative <filename>pam_env.conf</filename> + style configuration file to override the default. This can + be useful when different services need different environments. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term> + <option>debug</option> + </term> + <listitem> + <para> + A lot of debug information is printed with + <citerefentry><refentrytitle>syslog</refentrytitle><manvolnum>3</manvolnum></citerefentry>. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term> + <option>envfile=<replaceable>/path/to/environment</replaceable></option> + </term> + <listitem> + <para> + Indicate an alternative <filename>environment</filename> + file to override the default. The syntax are simple + <emphasis>KEY=VAL</emphasis> pairs on separate lines. The + <emphasis>export</emphasis> instruction can be specified for bash + compatibility, but will be ignored. + This can be useful when different services need different environments. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term> + <option>readenv=<replaceable>0|1</replaceable></option> + </term> + <listitem> + <para> + Turns on or off the reading of the file specified by envfile + (0 is off, 1 is on). By default this option is on. + </para> + </listitem> + </varlistentry> + + + <varlistentry> + <term> + <option>user_envfile=<replaceable>filename</replaceable></option> + </term> + <listitem> + <para> + Indicate an alternative <filename>.pam_environment</filename> + file to override the default.The syntax is the same as + for <emphasis>/etc/environment</emphasis>. + The filename is relative to the user home directory. + This can be useful when different services need different + environments. + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term> + <option>user_readenv=<replaceable>0|1</replaceable></option> + </term> + <listitem> + <para> + Turns on or off the reading of the user specific environment + file. 0 is off, 1 is on. By default this option is on. + </para> + </listitem> + </varlistentry> + + </variablelist> + </refsect1> + + <refsect1 id="pam_env-types"> + <title>MODULE TYPES PROVIDED</title> + <para> + The <option>auth</option> and <option>session</option> module + types are provided. + </para> + </refsect1> + + <refsect1 id="pam_env-return_values"> + <title>RETURN VALUES</title> + <variablelist> + <varlistentry> + <term>PAM_ABORT</term> + <listitem> + <para> + Not all relevant data or options could be gotten. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term>PAM_BUF_ERR</term> + <listitem> + <para> + Memory buffer error. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term>PAM_IGNORE</term> + <listitem> + <para> + No pam_env.conf and environment file was found. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term>PAM_SUCCESS</term> + <listitem> + <para> + Environment variables were set. + </para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1 id="pam_env-files"> + <title>FILES</title> + <variablelist> + <varlistentry> + <term><filename>/etc/security/pam_env.conf</filename></term> + <listitem> + <para>Default configuration file</para> + </listitem> + </varlistentry> + <varlistentry> + <term><filename>/etc/environment</filename></term> + <listitem> + <para>Default environment file</para> + </listitem> + </varlistentry> + <varlistentry> + <term><filename>$HOME/.pam_environment</filename></term> + <listitem> + <para>User specific environment file</para> + </listitem> + </varlistentry> + </variablelist> + </refsect1> + + <refsect1 id="pam_env-see_also"> + <title>SEE ALSO</title> + <para> + <citerefentry> + <refentrytitle>pam_env.conf</refentrytitle><manvolnum>5</manvolnum> + </citerefentry>, + <citerefentry> + <refentrytitle>pam.d</refentrytitle><manvolnum>5</manvolnum> + </citerefentry>, + <citerefentry> + <refentrytitle>pam</refentrytitle><manvolnum>8</manvolnum> + </citerefentry>, + <citerefentry> + <refentrytitle>environ</refentrytitle><manvolnum>7</manvolnum> + </citerefentry>. + </para> + </refsect1> + + <refsect1 id="pam_env-authors"> + <title>AUTHOR</title> + <para> + pam_env was written by Dave Kinchlea <kinch@kinch.ark.com>. + </para> + </refsect1> +</refentry> |