1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20 package org.apache.directory.server.kerberos.shared.store;
21
22
23 import java.util.Map;
24
25 import javax.security.auth.kerberos.KerberosPrincipal;
26
27 import org.apache.directory.server.kerberos.shared.crypto.encryption.EncryptionType;
28 import org.apache.directory.server.kerberos.shared.messages.value.EncryptionKey;
29 import org.apache.directory.server.kerberos.shared.messages.value.KerberosTime;
30 import org.apache.directory.server.kerberos.shared.messages.value.SamType;
31
32
33
34
35
36
37 public class PrincipalStoreEntry
38 {
39
40 private String distinguishedName;
41 private String commonName;
42 private KerberosPrincipal principal;
43 private String realmName;
44
45
46 private String userId;
47
48
49 private KerberosTime validStart;
50 private KerberosTime validEnd;
51 private KerberosTime passwordEnd;
52 private int keyVersionNumber;
53 private int maxLife;
54 private int maxRenew;
55 private int kdcFlags;
56 private SamType samType;
57
58 private boolean disabled;
59 private boolean lockedOut;
60 private KerberosTime expiration;
61
62 private Map<EncryptionType, EncryptionKey> keyMap;
63
64
65 PrincipalStoreEntry( String distinguishedName, String commonName, String userId, KerberosPrincipal principal,
66 int keyVersionNumber, KerberosTime validStart, KerberosTime validEnd, KerberosTime passwordEnd, int maxLife,
67 int maxRenew, int kdcFlags, Map<EncryptionType, EncryptionKey> keyMap, String realmName, SamType samType,
68 boolean disabled, boolean lockedOut, KerberosTime expiration )
69 {
70 this.distinguishedName = distinguishedName;
71 this.commonName = commonName;
72 this.userId = userId;
73 this.principal = principal;
74 this.validStart = validStart;
75 this.validEnd = validEnd;
76 this.passwordEnd = passwordEnd;
77 this.keyVersionNumber = keyVersionNumber;
78 this.maxLife = maxLife;
79 this.maxRenew = maxRenew;
80 this.kdcFlags = kdcFlags;
81 this.realmName = realmName;
82 this.disabled = disabled;
83 this.lockedOut = lockedOut;
84 this.expiration = expiration;
85 this.samType = samType;
86 this.keyMap = keyMap;
87 }
88
89
90
91
92
93
94
95 public boolean isDisabled()
96 {
97 return disabled;
98 }
99
100
101
102
103
104
105
106 public boolean isLockedOut()
107 {
108 return lockedOut;
109 }
110
111
112
113
114
115
116
117 public KerberosTime getExpiration()
118 {
119 return expiration;
120 }
121
122
123
124
125
126
127
128 public String getDistinguishedName()
129 {
130 return distinguishedName;
131 }
132
133
134
135
136
137
138
139 public String getCommonName()
140 {
141 return commonName;
142 }
143
144
145
146
147
148
149
150 public String getUserId()
151 {
152 return userId;
153 }
154
155
156
157
158
159
160
161 public Map<EncryptionType, EncryptionKey> getKeyMap()
162 {
163 return keyMap;
164 }
165
166
167
168
169
170
171
172 public int getKDCFlags()
173 {
174 return kdcFlags;
175 }
176
177
178
179
180
181
182
183 public int getKeyVersionNumber()
184 {
185 return keyVersionNumber;
186 }
187
188
189
190
191
192
193
194 public int getMaxLife()
195 {
196 return maxLife;
197 }
198
199
200
201
202
203
204
205 public int getMaxRenew()
206 {
207 return maxRenew;
208 }
209
210
211
212
213
214
215
216 public KerberosTime getPasswordEnd()
217 {
218 return passwordEnd;
219 }
220
221
222
223
224
225
226
227 public KerberosPrincipal getPrincipal()
228 {
229 return principal;
230 }
231
232
233
234
235
236
237
238 public String getRealmName()
239 {
240 return realmName;
241 }
242
243
244
245
246
247
248
249 public KerberosTime getValidEnd()
250 {
251 return validEnd;
252 }
253
254
255
256
257
258
259
260 public KerberosTime getValidStart()
261 {
262 return validStart;
263 }
264
265
266
267
268
269
270
271 public SamType getSamType()
272 {
273 return samType;
274 }
275 }