Userland build of Kerberos5 (AKA Heimdal). More to come.

This is not ready for primetime yet! Please hold off on the bug reports.
This commit is contained in:
markm 2000-01-15 21:38:08 +00:00
parent a4a1a839ad
commit 789632cad6
37 changed files with 2329 additions and 0 deletions

7
kerberos5/Makefile Normal file
View File

@ -0,0 +1,7 @@
# $FreeBSD$
SUBDIR= lib libexec usr.bin
bootstrap: cleandir obj depend all install kprog
.include <bsd.subdir.mk>

151
kerberos5/Makefile.inc Normal file
View File

@ -0,0 +1,151 @@
# $FreeBSD$
.if !defined(DISTRIBUTION)
DISTRIBUTION= krb5
.if !defined(INCLUDEOBJDIR)
INCLUDEDIR= ${.CURDIR}/../../include
KRB4DIR= ${.CURDIR}/../../../crypto/kerberosIV
KRB5DIR= ${.CURDIR}/../../../crypto/heimdal
ROKENDIR= ${.CURDIR}/../../lib/libroken
.if exists(${.OBJDIR}/../../include)
INCLUDEOBJDIR= ${.OBJDIR}/../../include
.else
INCLUDEOBJDIR= ${.CURDIR}/../../include
.endif
.if exists(${.OBJDIR}/../../lib/libasn1)
ASN1OBJDIR= ${.OBJDIR}/../../lib/libasn1
.else
ASN1OBJDIR= ${.CURDIR}/../../lib/libasn1
.endif
.if exists(${.OBJDIR}/../../lib/libhdb)
HDBOBJDIR= ${.OBJDIR}/../../lib/libhdb
.else
HDBOBJDIR= ${.CURDIR}/../../lib/libhdb
.endif
.if exists(${.OBJDIR}/../../lib/libroken)
ROKENOBJDIR= ${.OBJDIR}/../../lib/libroken
.else
ROKENOBJDIR= ${.CURDIR}/../../lib/libroken
.endif
.if exists(${.OBJDIR}/../../lib/libkrb4)
KRB4OBJDIR= ${.OBJDIR}/../../lib/libkrb4
.else
KRB4OBJDIR= ${.CURDIR}/../../lib/libkrb4
.endif
.if exists(${.OBJDIR}/../../lib/libkrb5)
KRB5OBJDIR= ${.OBJDIR}/../../lib/libkrb5
.else
KRB5OBJDIR= ${.CURDIR}/../../lib/libkrb5
.endif
.if exists(${.OBJDIR}/../../lib/libkadm5clnt)
KADM5COBJDIR= ${.OBJDIR}/../../lib/libkadm5clnt
.else
KADM5COBJDIR= ${.CURDIR}/../../lib/libkadm5clnt
.endif
.if exists(${.OBJDIR}/../../lib/libkadm5srv)
KADM5SOBJDIR= ${.OBJDIR}/../../lib/libkadm5srv
.else
KADM5SOBJDIR= ${.CURDIR}/../../lib/libkadm5srv
.endif
.if exists(${.OBJDIR}/../../lib/libkafs5)
KAFS5OBJDIR= ${.OBJDIR}/../../lib/libkafs5
.else
KAFS5OBJDIR= ${.CURDIR}/../../lib/libkafs5
.endif
.if exists(${.OBJDIR}/../../lib/libkrb5util)
KRB5UTILOBJDIR= ${.OBJDIR}/../../lib/libkrb5util
.else
KRB5UTILOBJDIR= ${.CURDIR}/../../lib/libkrb5util
.endif
.if exists(${.OBJDIR}/../../lib/libkdb5)
KDB5OBJDIR= ${.OBJDIR}/../../lib/libkdb5
.else
KDB5OBJDIR= ${.CURDIR}/../../lib/libkdb5
.endif
.if exists(${.OBJDIR}/../../lib/libsl)
SLOBJDIR= ${.OBJDIR}/../../lib/libsl
.else
SLOBJDIR= ${.CURDIR}/../../lib/libsl
.endif
CFLAGS+=-Wall -I${INCLUDEDIR} -I${INCLUDEOBJDIR} -DHAVE_CONFIG_H
.if defined(KRB5_KRB4_COMPAT)
CFLAGS+=-DKRB5_KRB4_COMPAT
.endif
.if defined(INET6)
CFLAGS+=-DINET6
.endif
COMPILE_ET= compile_et
.ORDER: asn1_err.c asn1_err.h
asn1_err.c asn1_err.h: ${KRB5DIR}/lib/asn1/asn1_err.et
test -e ${.OBJDIR}/asn1_err.et || ln -sf ${.ALLSRC}
${COMPILE_ET} asn1_err.et
CLEANFILES+=asn1_err.h asn1_err.c asn1_err.et
.ORDER: hdb_err.c hdb_err.h
hdb_err.c hdb_err.h: ${KRB5DIR}/lib/hdb/hdb_err.et
test -e ${.OBJDIR}/hdb_err.et || ln -sf ${.ALLSRC}
${COMPILE_ET} hdb_err.et
CLEANFILES+=hdb_err.h hdb_err.c hdb_err.et
.ORDER: heim_err.c heim_err.h
heim_err.c heim_err.h: ${KRB5DIR}/lib/krb5/heim_err.et
test -e ${.OBJDIR}/heim_err.et || ln -sf ${.ALLSRC}
${COMPILE_ET} heim_err.et
CLEANFILES+=heim_err.h heim_err.c heim_err.et
.ORDER: krb5_err.c krb5_err.h
krb5_err.c krb5_err.h: ${KRB5DIR}/lib/krb5/krb5_err.et
test -e ${.OBJDIR}/krb5_err.et || ln -sf ${.ALLSRC}
${COMPILE_ET} krb5_err.et
CLEANFILES+=krb5_err.h krb5_err.c krb5_err.et
.ORDER: kadm5_err.c kadm5_err.h
kadm5_err.c kadm5_err.h: \
${KRB5DIR}/lib/kadm5/kadm5_err.et
test -e ${.OBJDIR}/kadm5_err.et || ln -sf ${.ALLSRC}
${COMPILE_ET} kadm5_err.et
CLEANFILES+=kadm5_err.h kadm5_err.c kadm5_err.et
.if defined(INCLUDES)
beforeinstall: ${INCLUDES}
.for INC in ${INCLUDES}
${INSTALL} -C -o ${BINOWN} -g ${BINGRP} -m 444 \
${INC} ${DESTDIR}/usr/include/${INC}
.endfor
.endif
.else
INCLUDEDIR= ${.CURDIR}/../../include
KRB4DIR= ${.CURDIR}/../../crypto/kerberosIV
KRB5DIR= ${.CURDIR}/../../crypto/heimdal
ROKENDIR= ${.CURDIR}/../../lib/libroken
.endif
.endif

13
kerberos5/README Normal file
View File

@ -0,0 +1,13 @@
This subtree is world-exportable, as it does not contain any
cryptographic code.
At the time of writing, it did not even contain source code, only
Makefiles and headers.
Please maintain this "exportable" status quo.
Thanks!
MarkM
markm@freebsd.org
20th Sept 1997

View File

@ -0,0 +1,11 @@
# $Id$
.if exists(${.OBJDIR}/../../include)
INCLUDEOBJDIR= ${.OBJDIR}/../include
.else
INCLUDEOBJDIR= ${.CURDIR}/../include
.endif
depend lint tags:
.include <bsd.prog.mk>

1151
kerberos5/include/config.h Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,58 @@
/* This is a generated file */
#ifndef __krb5_private_h__
#define __krb5_private_h__
#ifdef __STDC__
#include <stdarg.h>
#ifndef __P
#define __P(x) x
#endif
#else
#ifndef __P
#define __P(x) ()
#endif
#endif
void
_krb5_crc_init_table __P((void));
u_int32_t
_krb5_crc_update __P((
char *p,
size_t len,
u_int32_t res));
int
_krb5_extract_ticket __P((
krb5_context context,
krb5_kdc_rep *rep,
krb5_creds *creds,
krb5_keyblock *key,
krb5_const_pointer keyseed,
krb5_key_usage key_usage,
krb5_addresses *addrs,
unsigned nonce,
krb5_boolean allow_server_mismatch,
krb5_decrypt_proc decrypt_proc,
krb5_const_pointer decryptarg));
ssize_t
_krb5_get_int __P((
void *buffer,
unsigned long *value,
size_t size));
void
_krb5_n_fold __P((
const void *str,
size_t len,
void *key,
size_t size));
ssize_t
_krb5_put_int __P((
void *buffer,
unsigned long value,
size_t size));
#endif /* __krb5_private_h__ */

View File

@ -0,0 +1,10 @@
/* krb5-types.h -- this file was generated for i386-unknown-freebsd4.0 by
$Id: bits.c,v 1.15 1999/03/24 04:04:10 assar Exp $ */
#ifndef __krb5_types_h__
#define __krb5_types_h__
#include <sys/types.h>
#include <inttypes.h>
#endif /* __krb5_types_h__ */

201
kerberos5/include/roken.h Normal file
View File

@ -0,0 +1,201 @@
/* This is an OS dependent, generated file */
#ifndef __ROKEN_H__
#define __ROKEN_H__
/* -*- C -*- */
/*
* Copyright (c) 1995, 1996, 1997, 1998, 1999 Kungliga Tekniska Högskolan
* (Royal Institute of Technology, Stockholm, Sweden).
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* 3. Neither the name of the Institute nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*/
/* $Id: roken.h.in,v 1.133 1999/12/30 02:22:54 assar Exp $ */
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <signal.h>
#include <sys/param.h>
#include <sys/types.h>
#include <unistd.h>
#include <sys/socket.h>
#include <sys/uio.h>
#include <grp.h>
#include <sys/stat.h>
#include <netinet/in.h>
#include <netinet6/in6.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <syslog.h>
#include <fcntl.h>
#include <errno.h>
#include <err.h>
#include <termios.h>
#include <sys/ioctl.h>
#include <sys/time.h>
#include <time.h>
#include <paths.h>
#define ROKEN_LIB_FUNCTION
#include <roken-common.h>
int asnprintf (char **ret, size_t max_sz, const char *format, ...)
__attribute__ ((format (printf, 3, 4)));
int vasnprintf (char **ret, size_t max_sz, const char *format, va_list ap)
__attribute__((format (printf, 3, 0)));
char * strndup(const char *old, size_t sz);
char * strlwr(char *);
size_t strnlen(const char*, size_t);
char * strupr(char *);
#include <pwd.h>
struct passwd *k_getpwnam (const char *user);
struct passwd *k_getpwuid (uid_t uid);
const char *get_default_username (void);
time_t tm2time (struct tm tm, int local);
int unix_verify_user(char *user, char *password);
void mini_inetd (int port);
int roken_concat (char *s, size_t len, ...);
size_t roken_mconcat (char **s, size_t max_len, ...);
int roken_vconcat (char *s, size_t len, va_list args);
size_t roken_vmconcat (char **s, size_t max_len, va_list args);
ssize_t net_write (int fd, const void *buf, size_t nbytes);
ssize_t net_read (int fd, void *buf, size_t nbytes);
int issuid(void);
int get_window_size(int fd, struct winsize *);
extern const char *__progname;
extern char **environ;
struct hostent *
copyhostent (const struct hostent *h);
int
getnameinfo_verified(const struct sockaddr *sa, socklen_t salen,
char *host, size_t hostlen,
char *serv, size_t servlen,
int flags);
/*
* kludges and such
*/
int roken_gethostby_setup(const char*, const char*);
struct hostent* roken_gethostbyname(const char*);
struct hostent* roken_gethostbyaddr(const void*, size_t, int);
#define roken_getservbyname(x,y) getservbyname(x,y)
#define roken_openlog(a,b,c) openlog(a,b,c)
void set_progname(char *argv0);
#endif /* __ROKEN_H__ */

View File

@ -0,0 +1,5 @@
/* $FreeBSD$ */
char *krb4_long_version = "@(#)$Version: krb4-1.0 by root on greenpeace.grondar.za (i386-unknown-freebsd4.0) Sat Jan 8 19:34:57 SAST 2000 $";
char *krb4_version = "krb4-1.0";
char *heimdal_long_version = "@(#)$Version: heimdal-0.1l by root on greenpeace.grondar.za (i386-unknown-freebsd4.0) Sat Jan 8 20:56:02 SAST 2000 $";
char *heimdal_version = "heimdal-0.1l";

5
kerberos5/lib/Makefile Normal file
View File

@ -0,0 +1,5 @@
# $FreeBSD$
SUBDIR= libroken libasn1 libhdb libkrb5 libkafs5 libkadm5clnt libkadm5srv libsl
.include <bsd.subdir.mk>

View File

@ -0,0 +1,6 @@
# $FreeBSD$
SHLIB_MAJOR?= 3
SHLIB_MINOR?= 0
.include "../Makefile.inc"

View File

@ -0,0 +1,73 @@
# $FreeBSD$
LIB= asn1
CFLAGS+=-I${KRB5DIR}/include \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/roken \
-I${INCLUDEOBJDIR} \
-I${.OBJDIR}
SRCS= der_get.c der_put.c der_free.c der_length.c der_copy.c \
timegm.c asn1_err.c asn1_err.h asn1.h ${GEN:S/.x/.c/g}
GEN= asn1_APOptions.x asn1_AP_REP.x asn1_AP_REQ.x asn1_AS_REP.x \
asn1_AS_REQ.x asn1_Authenticator.x asn1_AuthorizationData.x \
asn1_Checksum.x asn1_EncAPRepPart.x asn1_EncASRepPart.x \
asn1_EncKDCRepPart.x asn1_EncKrbCredPart.x \
asn1_EncKrbPrivPart.x asn1_EncTGSRepPart.x \
asn1_EncTicketPart.x asn1_EncryptedData.x \
asn1_EncryptionKey.x asn1_ETYPE_INFO.x asn1_ETYPE_INFO_ENTRY.x \
asn1_HostAddress.x asn1_HostAddresses.x asn1_KDCOptions.x \
asn1_KDC_REP.x asn1_KDC_REQ.x asn1_KDC_REQ_BODY.x \
asn1_KRB_CRED.x asn1_KRB_ERROR.x asn1_KRB_PRIV.x \
asn1_KRB_SAFE.x asn1_KRB_SAFE_BODY.x asn1_KerberosTime.x \
asn1_KrbCredInfo.x asn1_LastReq.x asn1_METHOD_DATA.x \
asn1_PA_DATA.x asn1_PA_ENC_TS_ENC.x asn1_Principal.x \
asn1_PrincipalName.x asn1_Realm.x asn1_TGS_REP.x \
asn1_TGS_REQ.x asn1_Ticket.x asn1_TicketFlags.x \
asn1_TransitedEncoding.x
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/asn1
.PATH: ${KRB5DIR}/lib/roken
beforedepend all:
.for I in ${GEN}
${I:S/.x/.c/}: ${I}
cmp -s ${.OODATE} ${.TARGET} 2> /dev/null || cp ${.OODATE} ${.TARGET}
.endfor
CLEANFILES+= ${GEN:S/.x/.c/g} asn1.h asn1_files
${GEN} asn1.h: asn1_compile k5.asn1
./asn1_compile ${KRB5DIR}/lib/asn1/k5.asn1
build-tools: make-print-version asn1_compile
asn1_compile: parse.o lex.o main.c hash.c symbol.c gen.c \
gen_encode.c gen_decode.c gen_free.c gen_length.c \
gen_copy.c gen_glue.c getarg.c warnerr.c print_version.o \
get_window_size.c strupr.c
${CC} ${CFLAGS} ${.OODATE} -o ${.TARGET}
parse.o: parse.c
parse.h parse.c: parse.y
${YACC} -d ${.OODATE}
mv y.tab.c parse.c
mv y.tab.h parse.h
lex.o: lex.l
print_version.o: print_version.h print_version.c
${CC} ${CFLAGS} -c -o ${.TARGET} ${KRB5DIR}/lib/roken/print_version.c
print_version.h: make-print-version
./make-print-version print_version.h
make-print-version: make-print-version.c
${CC} ${CFLAGS} -o ${.TARGET} ${.OODATE}
CLEANFILES+= ${GEN} asn1_compile lex.o parse.o parse.c parse.h \
hdb_asn1.h make-print-version print_version.h print_version.o

View File

@ -0,0 +1,58 @@
# $FreeBSD$
LIB= hdb
CFLAGS+=-I${KRB5DIR}/include \
-I${INCLUDEOBJDIR} \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/roken \
-I${.OBJDIR} \
-I${ASN1OBJDIR}
SRCS= keytab.c hdb.c common.c db.c ndbm.c print.c hdb_err.c \
hdb_asn1.h hdb_err.h krb5_err.h heim_err.h ${GEN:S/.x/.c/g}
GEN= asn1_Key.x asn1_Event.x asn1_HDBFlags.x asn1_hdb_entry.x asn1_Salt.x
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/hdb
.PATH: ${KRB5DIR}/lib/asn1
.PATH: ${KRB5DIR}/lib/roken
.for I in ${GEN}
${I:S/.x/.c/}: ${I}
cmp -s ${.OODATE} ${.TARGET} 2> /dev/null || cp ${.OODATE} ${.TARGET}
.endfor
CLEANFILES+= ${GEN:S/.x/.c/g} asn1.h asn1_files
${GEN} hdb_asn1.h: asn1_compile hdb.asn1
./asn1_compile ${KRB5DIR}/lib/hdb/hdb.asn1 hdb_asn1
asn1_compile: parse.o lex.o main.c hash.c symbol.c gen.c \
gen_encode.c gen_decode.c gen_free.c gen_length.c \
gen_copy.c gen_glue.c getarg.c warnerr.c print_version.o \
get_window_size.c strupr.c
${CC} ${CFLAGS} ${.OODATE} -o ${.TARGET}
parse.o: parse.c
parse.h parse.c: parse.y
${YACC} -d ${.OODATE}
mv y.tab.c parse.c
mv y.tab.h parse.h
lex.o: lex.l
print_version.o: print_version.h print_version.c
${CC} ${CFLAGS} -c -o ${.TARGET} ${KRB5DIR}/lib/roken/print_version.c
print_version.h: make-print-version
./make-print-version print_version.h
make-print-version: make-print-version.c
${CC} ${CFLAGS} -o ${.TARGET} ${.OODATE}
CLEANFILES+= ${GEN} asn1_compile lex.o parse.o parse.c parse.h \
hdb_asn1.h make-print-version print_version.h print_version.o

View File

@ -0,0 +1,19 @@
# $FreeBSD$
LIB= kadm5clnt
CFLAGS+=-I${KRB5DIR}/include \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/kadm5 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
SRCS= chpass_c.c common_glue.c create_c.c delete_c.c destroy_c.c \
flush_c.c free.c get_c.c get_princs_c.c init_c.c kadm5_err.c \
marshall.c modify_c.c privs_c.c randkey_c.c rename_c.c \
send_recv.c client_glue.c kadm5_err.h
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/kadm5

View File

@ -0,0 +1,20 @@
# $FreeBSD$
LIB= kadm5srv
CFLAGS+=-I${KRB5DIR}/include \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/kadm5 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
SRCS= acl.c chpass_s.c common_glue.c context_s.c create_s.c \
delete_s.c destroy_s.c ent_setup.c error.c flush_s.c \
free.c get_princs_s.c get_s.c init_s.c kadm5_err.c kadm5_err.h \
log.c marshall.c modify_s.c privs_s.c randkey_s.c rename_s.c \
set_keys.c set_modifier.c password_quality.c server_glue.c \
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/kadm5

View File

@ -0,0 +1,15 @@
# $FreeBSD$
LIB= kafs5
CFLAGS+=-I${KRB5DIR}/lib/kafs \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/include \
-I${KRB5OBJDIR} \
-I${ASN1OBJDIR}
SRCS= afssys.c afskrb.c afskrb5.c common.c
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/kafs

View File

@ -0,0 +1,42 @@
# $FreeBSD$
LIB= krb5
CFLAGS+=-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/des \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/include \
-I${KRB5OBJDIR} \
-I${ASN1OBJDIR}
SRCS= add_et_list.c addr_families.c address.c aname_to_localname.c \
asn1_glue.c auth_context.c build_ap_req.c build_auth.c \
cache.c changepw.c codec.c config_file.c config_file_netinfo.c \
convert_creds.c constants.c context.c copy_host_realm.c \
crc.c creds.c crypto.c data.c expand_hostname.c fcache.c \
free.c free_host_realm.c generate_seq_number.c \
generate_subkey.c get_addrs.c get_cred.c get_default_principal.c \
get_default_realm.c get_for_creds.c get_host_realm.c \
get_in_tkt.c get_in_tkt_pw.c get_in_tkt_with_keytab.c \
get_in_tkt_with_skey.c get_port.c init_creds.c init_creds_pw.c \
keyblock.c keytab.c keytab_file.c keytab_memory.c \
keytab_krb4.c keytab_keyfile.c krbhst.c kuserok.c log.c \
mcache.c misc.c mk_error.c mk_priv.c mk_rep.c mk_req.c \
mk_req_ext.c mk_safe.c net_read.c net_write.c n-fold.c \
padata.c principal.c prog_setup.c prompter_posix.c \
rd_cred.c rd_error.c rd_priv.c rd_rep.c rd_req.c rd_safe.c \
read_message.c recvauth.c send_to_kdc.c sendauth.c \
set_default_realm.c sock_principal.c store.c store_emem.c \
store_fd.c store_mem.c ticket.c time.c transited.c \
verify_init.c verify_user.c version.c warn.c write_message.c \
krb5_err.c krb5_err.h heim_err.c heim_err.h \
md4.c md5.c sha.c rc4_enc.c rc4_skey.c
INCLUDES=krb5.h
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/krb5
.PATH: ${KRB5DIR}/lib/des
beforedepend all: asn1_err.h krb5_err.h
CLEANFILES+= profile.h

View File

@ -0,0 +1,35 @@
# $FreeBSD$
LIB= roken
CFLAGS+= -I${KRB5DIR}/include \
-I${INCLUDEOBJDIR} \
-I${KRB5DIR}/lib/roken \
-I${.OBJDIR}
SRCS= base64.c concat.c emalloc.c eread.c erealloc.c estrdup.c \
ewrite.c get_default_username.c get_window_size.c getarg.c \
getnameinfo_verified.c issuid.c k_getpwnam.c k_getpwuid.c \
mini_inetd.c net_read.c net_write.c parse_bytes.c \
parse_time.c parse_units.c print_version.c resolve.c \
roken_gethostby.c signal.c simple_exec.c snprintf.c \
socket.c tm2time.c verify.c warnerr.c copyhostent.c \
strlwr.c strndup.c strnlen.c strupr.c get_default_username.c \
print_version.h
NOPIC= yes
install:
.include <bsd.lib.mk>
beforedepend all: print_version.h
.PATH: ${KRB5DIR}/lib/roken
build-tools: make-print-version
print_version.h: make-print-version
./make-print-version print_version.h
make-print-version: make-print-version.c
${CC} ${CFLAGS} -o ${.TARGET} ${.OODATE}
CLEANFILES+= make-print-version print_version.h

View File

@ -0,0 +1,15 @@
# $FreeBSD$
LIB= sl
CFLAGS+=-I${KRB5DIR}/lib/sl \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/include
SRCS= sl.c
NOPIC= yes
install:
.include <bsd.lib.mk>
.PATH: ${KRB5DIR}/lib/sl

View File

@ -0,0 +1,5 @@
# $FreeBSD$
SUBDIR= ipropd-master ipropd-slave hpropd kadmind kdc kpasswdd
.include <bsd.subdir.mk>

View File

@ -0,0 +1,5 @@
# $Id$
BINDIR= /usr/libexec
.include "../Makefile.inc"

View File

@ -0,0 +1,28 @@
# $FreeBSD$
PROG= hprop
SRCS= hprop.c hprop-common.c hdb_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/kdc \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs -lkdb
_krb4deps= ${LIBKRB} ${LIBKAFS} ${LIBKDB}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${HDBOBJDIR} -lhdb -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBHDB} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
MAN8= hprop.8
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kdc

View File

@ -0,0 +1,28 @@
# $FreeBSD$
PROG= hpropd
SRCS= hpropd.c hprop-common.c hdb_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/kdc \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs -lkdb
_krb4deps= ${LIBKRB} ${LIBKAFS} ${LIBKDB}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${HDBOBJDIR} -lhdb -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBHDB} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
MAN8= hpropd.8
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kdc

View File

@ -0,0 +1,29 @@
# $FreeBSD$
PROG= ipropd-master
SRCS= ipropd_master.c kadm5_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/kadm5 \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${HDBOBJDIR} -lhdb -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${KADM5COBJDIR} -lkadm5clnt -L${KADM5SOBJDIR} -lkadm5srv \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBHDB} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/lib/kadm5

View File

@ -0,0 +1,29 @@
# $FreeBSD$
PROG= ipropd-slave
SRCS= ipropd_slave.c kadm5_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/kadm5 \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${HDBOBJDIR} -lhdb -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${KADM5COBJDIR} -lkadm5clnt -L${KADM5SOBJDIR} -lkadm5srv \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBHDB} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/lib/kadm5

View File

@ -0,0 +1,47 @@
# $FreeBSD$
PROG= kadmind
SRCS= kadmind.c server.c version4.c \
kadm5/private.h kadm5/admin.h kadm5/kadm5_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/sl \
-I${KRB5DIR}/kadmin \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${KADM5COBJDIR} -lkadm5clnt -L${KADM5SOBJDIR} -lkadm5srv \
-L${HDBOBJDIR} -lhdb \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBROKEN} ${_krb4deps} \
${LIBKADM5CLNT} ${LIBKADM5SRV} ${LIBHDB} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kadmin
kadm5/private.h: kadm5
cp ${KRB5DIR}/lib/kadm5/private.h ${.TARGET}
kadm5/admin.h: kadm5
cp ${KRB5DIR}/lib/kadm5/admin.h ${.TARGET}
kadm5/kadm5_err.h: kadm5 kadm5_err.h
cd ${.OBJDIR}/kadm5 && ln -sf ../kadm5_err.h
kadm5:
mkdir ${.TARGET}
CLEANFILES+= kadm5/private.h kadm5/admin.h kadm5/kadm5_err.h
CLEANDIRS+= kadm5

View File

@ -0,0 +1,36 @@
# $FreeBSD$
PROG= kpasswdd
SRCS= kpasswdd.c krb5_err.h heim_err.h hdb_err.h kadm5/admin.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kpasswd \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${KADM5SOBJDIR} -lkadm5srv -L${HDBOBJDIR} -lhdb \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
MAN8= kpasswdd.8
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kpasswd
kadm5/admin.h: kadm5
cp ${KRB5DIR}/lib/kadm5/admin.h ${.TARGET}
kadm5:
mkdir ${.TARGET}
CLEANFILES+= kadm5/admin.h
CLEANDIRS+= kadm5

View File

@ -0,0 +1,29 @@
# $FreeBSD$
PROG= kdc
SRCS= 524.c config.c connect.c kaserver.c kerberos4.c kerberos5.c \
log.c main.c misc.c
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/kdc \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS} ${LIBKDB}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${HDBOBJDIR} -lhdb -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBHDB} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
MAN8= kdc.8
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kdc

View File

@ -0,0 +1,5 @@
# $FreeBSD$
SUBDIR= kadmin kauth kdestroy kinit klist kpasswd
.include <bsd.subdir.mk>

View File

@ -0,0 +1,5 @@
# $FreeBSD$
BINDIR= /usr/bin
.include "../Makefile.inc"

View File

@ -0,0 +1,51 @@
# $FreeBSD$
PROG= kadmin
SRCS= kadmin.c ank.c cpw.c del.c del_enctype.c get.c rename.c util.c \
ext.c mod.c init.c dump.c load.c random_password.c \
krb5_err.h heim_err.h hdb_err.h \
kadm5/private.h kadm5/admin.h kadm5/kadm5_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/hdb \
-I${KRB5DIR}/lib/sl \
-I${KRB5DIR}/kadmin \
-I${ASN1OBJDIR} \
-I${HDBOBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${KADM5COBJDIR} -lkadm5clnt -L${KADM5SOBJDIR} -lkadm5srv \
-L${HDBOBJDIR} -lhdb \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err \
-L${SLOBJDIR} -lsl -lreadline
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBROKEN} ${_krb4deps} \
${LIBKADM5CLNT} ${LIBKADM5SRV} ${LIBHDB} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR} ${LIBSL} \
${LIBREADLINE}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kadmin
kadm5/private.h: kadm5
cp ${KRB5DIR}/lib/kadm5/private.h ${.TARGET}
kadm5/admin.h: kadm5
cp ${KRB5DIR}/lib/kadm5/admin.h ${.TARGET}
kadm5/kadm5_err.h: kadm5 kadm5_err.h
cd ${.OBJDIR}/kadm5 && ln -sf ../kadm5_err.h
kadm5:
mkdir ${.TARGET}
CLEANFILES+= kadm5/private.h kadm5/admin.h kadm5/kadm5_err.h
CLEANDIRS+= kadm5

View File

@ -0,0 +1,21 @@
# $FreeBSD$
PROG= kauth
SRCS= kauth.c rkinit.c encdata.c marshall.c
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/appl/kauth
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/appl/kauth

View File

@ -0,0 +1,24 @@
# $FreeBSD$
PROG= kdestroy
SRCS= kdestroy.c krb5_err.h heim_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kuser

View File

@ -0,0 +1,24 @@
# $FreeBSD$
PROG= kinit
SRCS= kinit.c kinit_options.c asn1_err.h krb5_err.h heim_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kuser

View File

@ -0,0 +1,24 @@
# $FreeBSD$
PROG= klist
SRCS= klist.c krb5_err.h heim_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/kuser \
-I${ASN1OBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${KAFS5OBJDIR} -lkafs5 \
-L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBKAFS5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kuser

View File

@ -0,0 +1,23 @@
# $FreeBSD$
PROG= kpasswd
SRCS= kpasswd.c krb5_err.h heim_err.h
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/asn1 \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/kpasswd \
-I${ASN1OBJDIR} \
-I${.OBJDIR}
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/kpasswd

View File

@ -0,0 +1,21 @@
# $FreeBSD$
PROG= kauth
SRCS= kauth.c rkinit.c encdata.c marshall.c
CFLAGS+= -I${KRB5DIR}/include \
-I${KRB5DIR}/lib/roken \
-I${KRB5DIR}/lib/krb5 \
-I${KRB5DIR}/appl/kauth
.if defined(KRB5_KRB4_COMPAT)
_krb4libs= -lkrb -lkafs
_krb4deps= ${LIBKRB} ${LIBKAFS}
.endif
LDADD= -L${KRB5OBJDIR} -lkrb5 -L${ROKENOBJDIR} -lroken ${_krb4libs} \
-L${ASN1OBJDIR} -lasn1 -ldes -lcrypt -lcom_err
DPADD= ${LIBKRB5} ${LIBROKEN} ${_krb4deps} \
${LIBASN1} ${LIBDES} ${LIBCRYPT} ${LIBCOM_ERR}
NOMAN= yes
.include <bsd.prog.mk>
.PATH: ${KRB5DIR}/appl/kauth