libsss_sudo
1.9.2
Main Page
Modules
Data Structures
Files
File List
src
sss_client
sudo
sss_sudo.h
1
/*
2
Authors:
3
Pavel Březina <pbrezina@redhat.com>
4
5
Copyright (C) 2011 Red Hat
6
7
This program is free software; you can redistribute it and/or modify
8
it under the terms of the GNU General Public License as published by
9
the Free Software Foundation; either version 3 of the License, or
10
(at your option) any later version.
11
12
This program is distributed in the hope that it will be useful,
13
but WITHOUT ANY WARRANTY; without even the implied warranty of
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
GNU General Public License for more details.
16
17
You should have received a copy of the GNU General Public License
18
along with this program. If not, see <http://www.gnu.org/licenses/>.
19
*/
20
21
#ifndef SSS_SUDO_H_
22
#define SSS_SUDO_H_
23
32
#include <stdint.h>
33
#include <sys/types.h>
34
38
#define SSS_SUDO_ERROR_OK 0
39
45
struct
sss_sudo_attr
{
47
char
*
name
;
49
char
**
values
;
50
55
unsigned
int
num_values
;
56
};
57
62
struct
sss_sudo_rule
{
64
unsigned
int
num_attrs
;
65
67
struct
sss_sudo_attr
*
attrs
;
68
};
69
75
struct
sss_sudo_result
{
83
unsigned
int
num_rules
;
84
86
struct
sss_sudo_rule
*
rules
;
87
};
88
115
int
sss_sudo_send_recv
(uid_t uid,
116
const
char
*username,
117
const
char
*domainname,
118
uint32_t *_error,
119
struct
sss_sudo_result
**_result);
120
150
int
sss_sudo_send_recv_defaults
(uid_t uid,
151
const
char
*username,
152
uint32_t *_error,
153
char
**_domainname,
154
struct
sss_sudo_result
**_result);
155
162
void
sss_sudo_free_result
(
struct
sss_sudo_result
*result);
163
180
int
sss_sudo_get_values
(
struct
sss_sudo_rule
*e,
181
const
char
*attrname,
182
char
***values);
183
190
void
sss_sudo_free_values
(
char
**values);
191
195
#endif
/* SSS_SUDO_H_ */
Generated by
1.8.1.2