krb5_common.h revision 45aeb924ec3ac448bb8d174a5cc061ed98b147c7
/*
SSSD
Kerberos Backend, common header file
Authors:
Sumit Bose <sbose@redhat.com>
Copyright (C) 2009 Red Hat
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 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, see <http://www.gnu.org/licenses/>.
*/
#ifndef __KRB5_COMMON_H__
#define __KRB5_COMMON_H__
#include "config.h"
#include <stdbool.h>
#include "providers/dp_backend.h"
#include "util/sss_krb5.h"
#define SSSD_KRB5_KDC "SSSD_KRB5_KDC"
#define SSSD_KRB5_REALM "SSSD_KRB5_REALM"
#define SSSD_KRB5_RENEWABLE_LIFETIME "SSSD_KRB5_RENEWABLE_LIFETIME"
#define SSSD_KRB5_LIFETIME "SSSD_KRB5_LIFETIME"
#define SSSD_KRB5_USE_FAST "SSSD_KRB5_USE_FAST"
#define SSSD_KRB5_FAST_PRINCIPAL "SSSD_KRB5_FAST_PRINCIPAL"
#define SSSD_KRB5_CANONICALIZE "SSSD_KRB5_CANONICALIZE"
#define SSS_KRB5KDC_FO_SRV "KERBEROS"
#define SSS_KRB5KPASSWD_FO_SRV "KPASSWD"
enum krb5_opts {
KRB5_KDC = 0,
};
struct krb5_service {
char *name;
char *realm;
bool write_kdcinfo;
};
struct fo_service;
struct deferred_auth_ctx;
struct renew_tgt_ctx;
enum krb5_config_type {
};
struct krb5_ctx {
/* opts taken from kinit */
/* in seconds */
int forwardable;
int proxiable;
int addresses;
int not_forwardable;
int not_proxiable;
int no_addresses;
int verbose;
char* principal_name;
char* service_name;
char* keytab_name;
char* k5_cache_name;
char* k4_cache_name;
struct krb5_service *service;
struct krb5_service *kpasswd_service;
int child_debug_fd;
struct deferred_auth_ctx *deferred_auth_ctx;
struct renew_tgt_ctx *renew_tgt_ctx;
bool use_fast;
enum krb5_config_type config_type;
};
struct remove_info_files_ctx {
char *realm;
const char *kdc_service_name;
const char *kpasswd_service_name;
};
struct sss_domain_info *dom,
const char *service);
const char *service_name,
const char *primary_servers,
const char *backup_servers,
const char *realm,
bool use_kdcinfo,
struct krb5_service **_service);
void remove_krb5_info_files_callback(void *pvt);
struct tevent_signal *se,
int signum,
int count,
void *siginfo,
void *private_data);
const char *service);
bool *different_realm);
void **pvt_auth_data);
#endif /* __KRB5_COMMON_H__ */