]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - contrib/openpam/doc/man/openpam_borrow_cred.3
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / contrib / openpam / doc / man / openpam_borrow_cred.3
1 .\" Generated from openpam_borrow_cred.c by gendoc.pl
2 .\" $Id: openpam_borrow_cred.c 649 2013-03-05 17:58:33Z des $
3 .Dd September 7, 2013
4 .Dt OPENPAM_BORROW_CRED 3
5 .Os
6 .Sh NAME
7 .Nm openpam_borrow_cred
8 .Nd temporarily borrow user credentials
9 .Sh LIBRARY
10 .Lb libpam
11 .Sh SYNOPSIS
12 .In sys/types.h
13 .In security/pam_appl.h
14 .In security/openpam.h
15 .Ft "int"
16 .Fn openpam_borrow_cred "pam_handle_t *pamh" "const struct passwd *pwd"
17 .Sh DESCRIPTION
18 The
19 .Fn openpam_borrow_cred
20 function saves the current credentials and
21 switches to those of the user specified by its
22 .Fa pwd
23 argument.
24 The affected credentials are the effective UID, the effective GID, and
25 the group access list.
26 The original credentials can be restored using
27 .Xr openpam_restore_cred 3 .
28 .Pp
29 .Sh RETURN VALUES
30 The
31 .Fn openpam_borrow_cred
32 function returns one of the following values:
33 .Bl -tag -width 18n
34 .It Bq Er PAM_BUF_ERR
35 Memory buffer error.
36 .It Bq Er PAM_PERM_DENIED
37 Permission denied.
38 .It Bq Er PAM_SYSTEM_ERR
39 System error.
40 .El
41 .Sh SEE ALSO
42 .Xr setegid 2 ,
43 .Xr seteuid 2 ,
44 .Xr setgroups 2 ,
45 .Xr openpam_restore_cred 3 ,
46 .Xr pam 3 ,
47 .Xr pam_strerror 3
48 .Sh STANDARDS
49 The
50 .Fn openpam_borrow_cred
51 function is an OpenPAM extension.
52 .Sh AUTHORS
53 The
54 .Fn openpam_borrow_cred
55 function and this manual page were
56 developed for the
57 .Fx
58 Project by ThinkSec AS and Network Associates Laboratories, the
59 Security Research Division of Network Associates, Inc.\& under
60 DARPA/SPAWAR contract N66001-01-C-8035
61 .Pq Dq CBOSS ,
62 as part of the DARPA CHATS research program.
63 .Pp
64 The OpenPAM library is maintained by
65 .An Dag-Erling Sm\(/orgrav Aq des@des.no .