/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */1/* include/kdc_audit.h - KDC-facing API for audit */2/*3* Copyright 2013 by the Massachusetts Institute of Technology.4*5* Redistribution and use in source and binary forms, with or without6* modification, are permitted provided that the following conditions7* are met:8*9* * Redistributions of source code must retain the above copyright10* notice, this list of conditions and the following disclaimer.11*12* * Redistributions in binary form must reproduce the above copyright13* notice, this list of conditions and the following disclaimer in14* the documentation and/or other materials provided with the15* distribution.16*17* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS18* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT19* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS20* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE21* COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,22* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES23* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR24* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)25* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,26* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)27* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED28* OF THE POSSIBILITY OF SUCH DAMAGE.29*/3031#ifndef KRB5_KDC_AUDIT__32#define KRB5_KDC_AUDIT__3334#include <krb5/krb5.h>35#include <net-server.h>36#include <krb5/audit_plugin.h>3738krb5_error_code load_audit_modules(krb5_context context);39void unload_audit_modules(krb5_context context);4041/* Utilities */4243krb5_error_code44kau_make_tkt_id(krb5_context context,45const krb5_ticket *ticket, char **out);4647krb5_error_code48kau_init_kdc_req(krb5_context context, krb5_kdc_req *request,49const struct sockaddr *from, krb5_audit_state **au_state);5051void kau_free_kdc_req(krb5_audit_state *state);5253/* KDC-facing audit API */5455void56kau_kdc_start(krb5_context context, const krb5_boolean ev_success);5758void59kau_kdc_stop(krb5_context context, const krb5_boolean ev_success);6061void62kau_as_req(krb5_context context, const krb5_boolean ev_success,63krb5_audit_state *state);6465void66kau_tgs_req(krb5_context context, const krb5_boolean ev_success,67krb5_audit_state *state);6869void70kau_s4u2self(krb5_context context, const krb5_boolean ev_success,71krb5_audit_state *state);7273void74kau_s4u2proxy(krb5_context context, const krb5_boolean ev_success,75krb5_audit_state *state);7677void78kau_u2u(krb5_context context, const krb5_boolean ev_success,79krb5_audit_state *state);8081#endif /* KRB5_KDC_AUDIT__ */828384