xref: /netbsd-src/external/bsd/openpam/dist/doc/man/pam_set_data.3 (revision 0d9d0fd8a30be9a1924e715bbcf67a4a83efd262)
1.\"	$NetBSD: pam_set_data.3,v 1.9 2023/06/30 21:46:20 christos Exp $
2.\"
3.\" Generated from pam_set_data.c by gendoc.pl
4.Dd June 27, 2023
5.Dt PAM_SET_DATA 3
6.Os
7.Sh NAME
8.Nm pam_set_data
9.Nd set module information
10.Sh SYNOPSIS
11.In sys/types.h
12.In security/pam_appl.h
13.Ft "int"
14.Fn pam_set_data "pam_handle_t *pamh" "const char *module_data_name" "void *data" "void (*cleanup)(pam_handle_t *pamh, void *data, int pam_end_status)"
15.Sh DESCRIPTION
16The
17.Fn pam_set_data
18function associates a pointer to an opaque object
19with an arbitrary string specified by the
20.Fa module_data_name
21argument,
22in the PAM context specified by the
23.Fa pamh
24argument.
25.Pp
26If not
27.Dv NULL ,
28the
29.Fa cleanup
30argument should point to a function
31responsible for releasing the resources associated with the object.
32.Pp
33This function and its counterpart
34.Xr pam_get_data 3
35are useful for managing
36data that are meaningful only to a particular service module.
37.Sh RETURN VALUES
38The
39.Fn pam_set_data
40function returns one of the following values:
41.Bl -tag -width 18n
42.It Bq Er PAM_SUCCESS
43Success.
44.It Bq Er PAM_BUF_ERR
45Memory buffer error.
46.It Bq Er PAM_SYSTEM_ERR
47System error.
48.El
49.Sh SEE ALSO
50.Xr openpam_free_data 3 ,
51.Xr pam 3 ,
52.Xr pam_get_data 3 ,
53.Xr pam_strerror 3
54.Sh STANDARDS
55.Rs
56.%T "X/Open Single Sign-On Service (XSSO) - Pluggable Authentication Modules"
57.%D "June 1997"
58.Re
59.Sh AUTHORS
60The
61.Fn pam_set_data
62function and this manual page were
63developed for the
64.Fx
65Project by ThinkSec AS and Network Associates Laboratories, the
66Security Research Division of Network Associates, Inc.\& under
67DARPA/SPAWAR contract N66001-01-C-8035
68.Pq Dq CBOSS ,
69as part of the DARPA CHATS research program.
70.Pp
71The OpenPAM library is maintained by
72.An Dag-Erling Sm\(/orgrav Aq Mt des@des.no .
73