Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pam_putenv(3) [v7 man page]

PAM_PUTENV(3)							 Linux-PAM Manual						     PAM_PUTENV(3)

NAME
pam_putenv - set or change PAM environment variable SYNOPSIS
#include <security/pam_appl.h> int pam_putenv(pam_handle_t *pamh, const char *name_value); DESCRIPTION
The pam_putenv function is used to add or change the value of PAM environment variables as associated with the pamh handle. The pamh argument is an authentication handle obtained by a prior call to pam_start(). The name_value argument is a single NUL terminated string of one of the following forms: NAME=value of variable In this case the environment variable of the given NAME is set to the indicated value: value of variable. If this variable is already known, it is overwritten. Otherwise it is added to the PAM environment. NAME= This function sets the variable to an empty value. It is listed separately to indicate that this is the correct way to achieve such a setting. NAME Without an '=' the pam_putenv() function will delete the corresponding variable from the PAM environment. pam_putenv() operates on a copy of name_value, which means in contrast to putenv(3), the application is responsible to free the data. RETURN VALUES
PAM_PERM_DENIED Argument name_value given is a NULL pointer. PAM_BAD_ITEM Variable requested (for deletion) is not currently set. PAM_ABORT The pamh handle is corrupt. PAM_BUF_ERR Memory buffer error. PAM_SUCCESS The environment variable was successfully updated. SEE ALSO
pam_start(3), pam_getenv(3), pam_getenvlist(3), pam_strerror(3), pam(7) Linux-PAM Manual 06/04/2011 PAM_PUTENV(3)

Check Out this Related Man Page

PAM_PUTENV(3)							 Linux-PAM Manual						     PAM_PUTENV(3)

NAME
pam_putenv - set or change PAM environment variable SYNOPSIS
#include <security/pam_appl.h> int pam_putenv(pam_handle_t *pamh, const char *name_value); DESCRIPTION
The pam_putenv function is used to add or change the value of PAM environment variables as associated with the pamh handle. The pamh argument is an authentication handle obtained by a prior call to pam_start(). The name_value argument is a single NUL terminated string of one of the following forms: NAME=value of variable In this case the environment variable of the given NAME is set to the indicated value: value of variable. If this variable is already known, it is overwritten. Otherwise it is added to the PAM environment. NAME= This function sets the variable to an empty value. It is listed separately to indicate that this is the correct way to achieve such a setting. NAME Without an '=' the pam_putenv() function will delete the corresponding variable from the PAM environment. pam_putenv() operates on a copy of name_value, which means in contrast to putenv(3), the application is responsible to free the data. RETURN VALUES
PAM_PERM_DENIED Argument name_value given is a NULL pointer. PAM_BAD_ITEM Variable requested (for deletion) is not currently set. PAM_ABORT The pamh handle is corrupt. PAM_BUF_ERR Memory buffer error. PAM_SUCCESS The environment variable was successfully updated. SEE ALSO
pam_start(3), pam_getenv(3), pam_getenvlist(3), pam_strerror(3), pam(7) Linux-PAM Manual 06/04/2011 PAM_PUTENV(3)
Man Page

5 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

"$" in environment variable

Hi, I have a problem with retreiving the value of an environment variable. The name of the variable is: DIR$INP I am not able to change the name of the variable, because it is used by programs to which I do not have access to. The variable contains the name of a directory as value. I have... (6 Replies)
Discussion started by: lamac
6 Replies

2. Linux

How do i set environment variable

Hi, I am quite new to Linux. And I have doubt how to set new environment variable with value to a C executable. Let say I have a environment variable $Hack ; I would like to load a value for this variable; so that when the C executable is executed, the $Hack would set the variable value. ... (4 Replies)
Discussion started by: ahjiefreak
4 Replies

3. Solaris

Environment variable

Hello, For the moment, my LC_ALL variable is set as "" by default. If I want to change this value, I do : export LC_ALL="en_fr" for example. That I want to know it's : how can I set by default this value ? I want to save it on my profile in order to get it when I open my session... :confused:... (2 Replies)
Discussion started by: MasterapocA
2 Replies

4. UNIX for Dummies Questions & Answers

cshrc Environment Variable Question

How do I input the environment variable in the .cshrc file to have the up and down arrows recall the last commands??? This is for Solaris 10. :confused::confused: (1 Reply)
Discussion started by: CFSR
1 Replies

5. Shell Programming and Scripting

Not able to change the environment variable in k shell

Hi All, I am trying the following to set the environment variable in my scirpt.But it is not setting with the correct value. Can you guys please help me out to get the correct value. 1. I have environment variable NLS_LANG=American_America.UTF8 2. In my script (ksh) i am trying the following... (1 Reply)
Discussion started by: girish.raos
1 Replies