2N/A/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
2N/A/*
2N/A * lib/kdb/kdb_ldap/ldap_tkt_policy.h
2N/A *
2N/A * Copyright (c) 2004-2005, Novell, Inc.
2N/A * All rights reserved.
2N/A *
2N/A * Redistribution and use in source and binary forms, with or without
2N/A * modification, are permitted provided that the following conditions are met:
2N/A *
2N/A * * Redistributions of source code must retain the above copyright notice,
2N/A * this list of conditions and the following disclaimer.
2N/A * * Redistributions in binary form must reproduce the above copyright
2N/A * notice, this list of conditions and the following disclaimer in the
2N/A * documentation and/or other materials provided with the distribution.
2N/A * * The copyright holder's name is not used to endorse or promote products
2N/A * derived from this software without specific prior written permission.
2N/A *
2N/A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
2N/A * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2N/A * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
2N/A * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
2N/A * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
2N/A * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
2N/A * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
2N/A * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
2N/A * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
2N/A * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
2N/A * POSSIBILITY OF SUCH DAMAGE.
2N/A */
2N/A
2N/A#ifndef _LDAP_POLICY_H
2N/A#define _LDAP_POLICY_H 1
2N/A
2N/A/* policy specific mask */
2N/A
2N/A#define LDAP_POLICY_MAXTKTLIFE 0x0001
2N/A#define LDAP_POLICY_MAXRENEWLIFE 0x0002
2N/A#define LDAP_POLICY_TKTFLAGS 0x0004
2N/A#define LDAP_POLICY_COUNT 0x0008
2N/A/* policy object structure */
2N/A
2N/Atypedef struct _krb5_ldap_policy_params {
2N/A char *policy;
2N/A long mask;
2N/A long maxtktlife;
2N/A long maxrenewlife;
2N/A long tktflags;
2N/A krb5_tl_data *tl_data;
2N/A}krb5_ldap_policy_params;
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_create_policy(krb5_context, krb5_ldap_policy_params *, int);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_modify_policy(krb5_context, krb5_ldap_policy_params *, int);
2N/A
2N/A/* Solaris kerberos: unsigned better for mask */
2N/Akrb5_error_code
2N/Akrb5_ldap_read_policy(krb5_context, char *, krb5_ldap_policy_params **,
2N/A unsigned int *);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_delete_policy(krb5_context, char *);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_clear_policy(krb5_context, char *);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_list_policy(krb5_context, char *, char ***);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_free_policy(krb5_context, krb5_ldap_policy_params *);
2N/A
2N/Akrb5_error_code
2N/Akrb5_ldap_change_count(krb5_context, char *, int);
2N/A
2N/A#endif