Blame man/man3/semanage_exists.3

Packit 366192
.TH semanage_exists 3 "16 March 2006" "ivg2@cornell.edu" "Libsemanage API documentation"
Packit 366192
Packit 366192
.SH "NAME" 
Packit 366192
semanage_exists \- SELinux Management API
Packit 366192
Packit 366192
.SH "SYNOPSIS"
Packit 366192
The following exists function is supported for any semanage record.
Packit 366192
.br
Packit 366192
Replace the function and object name as necessary.
Packit 366192
Packit 366192
.B extern int EXISTS_FUNCTION (
Packit 366192
.br
Packit 366192
.BI "	semanage_handle_t *" handle ","
Packit 366192
.br
Packit 366192
.BI "	const semanage_OBJECT_key_t *" key ","
Packit 366192
.br
Packit 366192
.BI "	semanage_OBJECT_t **" response ");"
Packit 366192
Packit 366192
.SH "DESCRIPTION"
Packit 366192
.TP
Packit 366192
.B Behavior:
Packit 366192
The exists function will return 0 if a matching key is not found, and 1 otherwise. 
Packit 366192
Packit 366192
.TP
Packit 366192
.B Parameters:
Packit 366192
The 
Packit 366192
.I handle
Packit 366192
is used to track persistent state across semanage calls, and for error reporting. The
Packit 366192
.I key 
Packit 366192
identifies the object being checked. The result of the test will be stored in the address pointed by 
Packit 366192
.I response
Packit 366192
The key is a property of the caller, and will not be stored or modified internally. 
Packit 366192
Packit 366192
.TP
Packit 366192
.B Requirements:
Packit 366192
This function requires an semanage connection to be established (see 
Packit 366192
.BR semanage_connect "(3)"
Packit 366192
)
Packit 366192
Packit 366192
.SH "RETURN VALUE"
Packit 366192
In case of failure, \-1 is returned, and the semanage error callback is invoked, describing the error.
Packit 366192
Otherwise a non-negative integer is returned (a commit number). The same number will be returned by all other read calls to the semanage database until the next commit.
Packit 366192
Packit 366192
.SH "SEE ALSO"
Packit 366192
.BR semanage_handle_create "(3), " semanage_connect "(3), "