pam_getenvlist − getting the PAM environment

#include <security/pam_appl.h>

char **pam_getenvlist(pam_handle_t *pamh);


The pam_getenvlist function returns a complete copy of the PAM environment as associated with the handle pamh. The PAM environment variables represent the contents of the regular environment variables of the authenticated user when service is granted.

The format of the memory is a malloc()´d array of char pointers, the last element of which is set to NULL. Each of the non−NULL entries in this array point to a NUL terminated and malloc()´d char string of the form: "name=value".

It should be noted that this memory will never be free()´d by libpam. Once obtained by a call to pam_getenvlist, it is the responsibility of the calling application to free() this memory.

It is by design, and not a coincidence, that the format and contents of the returned array matches that required for the third argument of the execle(3) function call.

The pam_getenvlist function returns NULL on failure.

(3), pam_getenv(3), pam_putenv(3), pam(8)

More Linux Commands

hwinfo(8) - probe for hardware (Admin - Linux man page).....
hwinfo is used to probe for the hardware present in the system. It can be used to generate a system overview log which can be later used for support. OPTIONS No

ldap_modrdn2_s(3) - Perform an LDAP modify RDN operation....
The ldap_modrdn() and ldap_modrdn_s() routines perform an LDAP modify RDN operation. They both take dn, the DN of the entry whose RDN is to be changed, and newr

Tk_Alloc3DBorderFromObj(3) - draw borders with three-dimensi
These procedures provide facilities for drawing window borders in a way that produces a three-dimensional appearance. Tk_Alloc3DBorderFromObj allocates colors a

wattr_get(3ncurses) - curses character and window attribute
These routines manipulate the current attributes of the named window. The current attributes of a window apply to all characters that are written into the windo

dbus-run-session(1) start a process as a new DBus session...
dbus-run-session is used to start a session bus instance of dbus-daemon from a shell script, and start a specified program in that session. The dbus-daemon will

ugetrlimit(2) - get/set resource limits - Linux manual page
The getrlimit() and setrlimit() system calls get and set resource limits respectively. Each resource has an associated soft and hard limit, as defined by the rl

perlsub(1) - Perl subroutines (Commands - Linux man page)...
Like many languages, Perl provides for user-defined subroutines. These may be located anywhere in the main program, loaded in from other files via the do, requi

ber_printf(3) - OpenLDAP LBER simplified Basic Encoding Rule
These routines provide a subroutine interface to a simplified implementation of the Basic Encoding Rules of ASN.1. The version of BER these routines support is

slk_attr_set_sp(3ncurses) - curses screen-pointer extension
This implementation can be configured to provide a set of functions which improve the ability to manage multiple screens. This feature can be added to any of th

standout(3ncurses) - curses character and window attribute c
These routines manipulate the current attributes of the named window. The current attributes of a window apply to all characters that are written into the windo

XtAddCallback(3) - add and remove callback procedures.......
The XtAddCallback function adds the specified callback procedure to the specified widgets callback list. The XtAddCallbacks add the specified list of callbacks

glMap1(3gl) - define a one-dimensional evaluator (Man Page)
glMap1.3gl - Evaluators provide a way to use polynomial or rational polynomial mapping to produce vertices, normals, texture coordinates, and colors. The values

We can't live, work or learn in freedom unless the software we use is free.