Lines Matching defs:entry

47  *	entry	(input) The policy entry to be written out to the DB.
48 * mask (input) Specifies which fields in entry are to ge written out
53 * Entry must be a valid principal entry, and mask have a valid value.
64 kadm5_policy_ent_t entry, long mask)
73 return kadm5_create_policy_internal(server_handle, entry, mask);
82 * entry (input) The policy entry to be written out to the DB.
83 * mask (input) Specifies which fields in entry are to ge written out
88 * Entry must be a valid principal entry, and mask have a valid value.
98 kadm5_policy_ent_t entry, long mask)
107 if ((entry == (kadm5_policy_ent_t) NULL) || (entry->policy == NULL))
109 if(strlen(entry->policy) == 0)
114 pent.name = entry->policy;
115 p = entry->policy;
125 pent.pw_max_life = entry->pw_max_life;
130 if(entry->pw_min_life > entry->pw_max_life && entry->pw_max_life != 0)
133 pent.pw_min_life = entry->pw_min_life;
138 if(entry->pw_min_length < MIN_PW_LENGTH)
140 pent.pw_min_length = entry->pw_min_length;
145 if(entry->pw_min_classes > MAX_PW_CLASSES || entry->pw_min_classes < MIN_PW_CLASSES)
147 pent.pw_min_classes = entry->pw_min_classes;
152 if(entry->pw_history_num < MIN_PW_HISTORY ||
153 entry->pw_history_num > MAX_PW_HISTORY)
156 pent.pw_history_num = entry->pw_history_num;
161 pent.policy_refcnt = entry->policy_refcnt;
172 osa_policy_ent_t entry;
184 if((ret = krb5_db_get_policy(handle->context, name, &entry,&cnt)))
189 if(entry->policy_refcnt != 0) {
190 krb5_db_free_policy(handle->context, entry);
193 krb5_db_free_policy(handle->context, entry);
202 kadm5_policy_ent_t entry, long mask)
211 return kadm5_modify_policy_internal(server_handle, entry, mask);
216 kadm5_policy_ent_t entry, long mask)
225 if((entry == (kadm5_policy_ent_t) NULL) || (entry->policy == NULL))
227 if(strlen(entry->policy) == 0)
232 if ((ret = krb5_db_get_policy(handle->context, entry->policy, &p, &cnt)))
238 p->pw_max_life = entry->pw_max_life;
240 if(entry->pw_min_life > p->pw_max_life && p->pw_max_life != 0) {
244 p->pw_min_life = entry->pw_min_life;
247 if(entry->pw_min_length < MIN_PW_LENGTH) {
251 p->pw_min_length = entry->pw_min_length;
254 if(entry->pw_min_classes > MAX_PW_CLASSES ||
255 entry->pw_min_classes < MIN_PW_CLASSES) {
259 p->pw_min_classes = entry->pw_min_classes;
262 if(entry->pw_history_num < MIN_PW_HISTORY ||
263 entry->pw_history_num > MAX_PW_HISTORY) {
267 p->pw_history_num = entry->pw_history_num;
270 p->policy_refcnt = entry->policy_refcnt;
278 kadm5_policy_ent_t entry)
291 * In version 1, entry is a pointer to a kadm5_policy_ent_t that
295 entry_orig = (kadm5_policy_ent_rec **) entry;
297 entry = &entry_local;
310 if ((entry->policy = (char *) malloc(strlen(t->name) + 1)) == NULL) {
314 strcpy(entry->policy, t->name);
315 entry->pw_min_life = t->pw_min_life;
316 entry->pw_max_life = t->pw_max_life;
317 entry->pw_min_length = t->pw_min_length;
318 entry->pw_min_classes = t->pw_min_classes;
319 entry->pw_history_num = t->pw_history_num;
320 entry->policy_refcnt = t->policy_refcnt;
326 free(entry->policy);
330 *new = *entry;