blob: b0bfba294cdb5c83bab754e0baae64c94a1baa83 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
/***************************************************************************
* Copyright (C) 2012 by Timothy Pearson *
* [email protected] *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
***************************************************************************/
#ifndef _LIBTDELDAP_H_
#define _LIBTDELDAP_H_
#include <unistd.h>
#include <tqstring.h>
#include <tqdatetime.h>
#include <tqvaluelist.h>
enum LDAPUserStatus {
USER_STATUS_ENABLED,
USER_STATUS_DISABLED
};
typedef TQValueList<uid_t> UserList;
typedef TQValueList<gid_t> GroupList;
class LDAPUserInfo
{
public:
TQString name;
uid_t uid;
TQString shell;
TQString homedir;
gid_t primary_gid;
GroupList grouplist;
LDAPUserStatus status;
TQDate password_last_changed;
bool password_expires;
TQDate password_expiration;
bool password_ages;
int new_password_interval;
int new_password_warn_interval;
int new_password_lockout_delay;
bool password_has_minimum_age;
int password_minimum_age;
TQString realName;
TQString organization;
// FIXME
// Add other attributes (cubicle, phone number, etc)
};
class LDAPGroupInfo
{
public:
TQString name;
gid_t gid;
UserList userlist;
};
#endif // _LIBTDELDAP_H_
|