Jeffrey Altman [Fri, 20 Aug 2004 23:46:39 +0000 (23:46 +0000)]
ChangeLogs for WiX MSI installer
ticket: 2675
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16676
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 20 Aug 2004 23:42:59 +0000 (23:42 +0000)]
New WiX based MSI installer for KFW
Requires WiX 2.0.1927.1 patched by Asanka.
http://prdownloads.sourceforge.net/wix/sources-2.0.1927.1.zip
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16675
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Fri, 20 Aug 2004 18:45:30 +0000 (18:45 +0000)]
renamed acl_* functions to kadm5int_acl_*
ticket: 2674
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16673
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Fri, 20 Aug 2004 18:38:00 +0000 (18:38 +0000)]
Added kadmin code to project to make searches easier
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16672
dc483132-0cff-0310-8789-
dd5450dbe970
Sam Hartman [Thu, 19 Aug 2004 20:04:49 +0000 (20:04 +0000)]
* shlib.conf: Add support for gnu hurd and for BSD kernels with
glibc; use the Linux shared library procedure
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16671
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 19 Aug 2004 00:56:53 +0000 (00:56 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Check for pthread_rwlock_init, with and
without the thread library.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16670
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Tue, 17 Aug 2004 23:57:16 +0000 (23:57 +0000)]
* svc.c (svc_getreqset): Allocate cred and verf memory to
temporary pointers, and free the temporary pointers on exit.
Freeing the actual cred and verf pointers can cause corruption
because auth mechanisms can reassign the pointers.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16669
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Tue, 17 Aug 2004 01:14:58 +0000 (01:14 +0000)]
* svc_auth_gss.c (gssrpc__svcauth_gss): Add some debug messages
* svc.c (svc_getreqset): Don't allocate either raw or cooked
credentials on the stack using the cred_area char array; use
mem_alloc() instead. This avoids alignment problems.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16668
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 16 Aug 2004 01:27:41 +0000 (01:27 +0000)]
* cc_file.c (struct _krb5_fcc_data): Add new mutex disk_file_lock and flag
file_is_locked.
(krb5_fcc_close_file): Unlock the mutex and clear the flag.
(krb5_fcc_open_file): Acquire the mutex before locking the file, and set the
flag after.
(krb5_fcc_resolve): Initialize the new mutex and flag.
(krb5_fcc_generate_new): Initialize both mutexes and the flag.
(dereference): Destroy the new mutex.
Also, get rid of some unused variables.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16667
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 15 Aug 2004 23:56:00 +0000 (23:56 +0000)]
* cc_file.c: Add buffering on reading.
(FCC_BUFSIZ): New macro.
(struct _krb5_fcc_data): Add new fields buf, valid_bytes, cur_offset.
(krb5_fcc_resolve, krb5_fcc_generate_new): Initialize valid_bytes.
(invalidate_cache): New function.
(krb5_fcc_write, krb5_fcc_open_file, krb5_fcc_destroy): Call invalidate_cache.
(fcc_lseek): New function.
(krb5_fcc_skip_header, krb5_fcc_destroy, krb5_fcc_start_seq_get,
krb5_fcc_next_cred, krb5_fcc_store): Use fcc_lseek instead of lseek.
(fcc_read): Use and maybe refill the buffer.
(dereference): Zap the contents of the buffer before freeing it.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16666
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 15 Aug 2004 23:18:24 +0000 (23:18 +0000)]
* run.test (getnwords): Rewrite to drop blank lines before counting lines, not after
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16665
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 15 Aug 2004 23:10:35 +0000 (23:10 +0000)]
* cc_file.c (dereference): Lock mutex around call to krb5_fcc_close_file
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16664
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 15 Aug 2004 03:37:24 +0000 (03:37 +0000)]
Fix Tru64 build:
* k5-thread.h (k5_os_nothread_mutex_assert_locked,
k5_os_nothread_mutex_assert_unlocked, k5_os_mutex_assert_locked,
k5_os_mutex_assert_unlocked): Assertion macros should always have type void.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16663
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 13 Aug 2004 04:02:35 +0000 (04:02 +0000)]
Only open a credential cache file once, even if multiple krb5_ccache objects
refer to it. (This does NOT yet take care of the problem of multiple threads
wanting to use OS-level advisory locks, which at least on UNIX are per-process
and not per-thread.)
* cc_file.c (krb5_fcc_close_file): Change first argument to be an fcc-data
pointer, not a krb5_ccache. All calls changed.
(struct fcc_set): Add a refcount member. (Definition accidentally introduced
without comment in an earlier patch.)
(krb5int_cc_file_mutex, fccs): New variables, for managing a global list of
open credential cache files.
(dereference): New function, with most of old close/destroy operations.
Decrements reference count and only frees the object and removes it from the
global list if the refcount hits zero.
(krb5_fcc_close, krb5_fcc_destroy): Call dereference.
(krb5_fcc_resolve): If a file cache is already open with the same file name,
increment its reference count and don't create a new one. When a new one is
created, add it to the global list.
* cc-int.h (krb5int_cc_file_mutex): Declare.
* ccbase.c (krb5int_cc_initialize): Initialize it.
(krb5int_cc_finalize): Destroy it, and krb5int_mcc_mutex.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16662
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 13 Aug 2004 02:41:34 +0000 (02:41 +0000)]
* k5-thread.h (k5_os_nothread_mutex_finish_init, k5_os_nothread_mutex_init,
k5_os_nothread_mutex_destroy, k5_os_nothread_mutex_lock,
k5_os_nothread_mutex_unlock) [!DEBUG_THREADS]: Replace macros with inline
functions, to gain type checking and eliminate gratuitous compiler warnings.
(k5_pthread_assert_unlocked, k5_pthread_assert_locked): Likewise.
(k5_os_mutex_finish_init) [HAVE_PTHREAD && !USE_PTHREAD_LOCK_ONLY_IF_LOADED]:
Likewise.
(return_after_yield): New inline function.
(k5_os_mutex_lock) [HAVE_PTHREAD]: Change back to a macro, calling
return_after_yield.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16661
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Aug 2004 23:00:20 +0000 (23:00 +0000)]
* run.test (getnwords): New function. Uses sed to get N words from $DICT as
other functions did before, but discards blank lines.
(test1, test2, test12, test13, test20): Call getnwords.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16660
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 12 Aug 2004 19:10:54 +0000 (19:10 +0000)]
get_in_tkt.c (get_init_creds): Support ticket_lifetime libdefault. Made aware of 32 bit min and max for times. Allow renew_until time < expiration time
ticket: 2654
ticket: 2655
ticket: 2656
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16656
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 12 Aug 2004 18:57:38 +0000 (18:57 +0000)]
ccdefname.c (krb5_cc_set_default_name, krb5_cc_default_name): Look up the default ccache name in krb5_cc_default_name, not krb5_cc_set_default_name so that krb5_init_context doesn't have to do work it might never use
ticket: 2657
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16655
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Tue, 10 Aug 2004 00:47:14 +0000 (00:47 +0000)]
* configure.in: Solaris getpwnam_r returns struct passwd*, not
struct pwd*.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16654
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 9 Aug 2004 00:20:05 +0000 (00:20 +0000)]
* ftpd.c (main): Use socklen_t for the size of the address from accept
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16653
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 9 Aug 2004 00:18:22 +0000 (00:18 +0000)]
* krb524d.c (do_connection): Use socklen_t for the size of the address from recvfrom
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16652
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 22:53:20 +0000 (22:53 +0000)]
* aclocal.m4 (WITH_CC): Log messages when adding AIX compiler options
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16651
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 22:38:07 +0000 (22:38 +0000)]
* libkrb5.exports: Remove memory ccache symbols except ops table
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16650
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 22:35:02 +0000 (22:35 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Clear PTHREAD_CFLAGS and PTHREAD_LIBS
after adding them to CFLAGS and LIBS respectively, to avoid duplicating the
options later.
(WITH_CC): Add -O on AIX also. Don't add options if similar options are
already present.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16649
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 21:22:41 +0000 (21:22 +0000)]
* threads.c (GET_NO_PTHREAD_TSD) [!HAVE_PRAGMA_WEAK_REF]: Macro result type
should be pointer to tsd_block.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16648
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 21:10:46 +0000 (21:10 +0000)]
* configure.in: If getpwnam_r is available, determine its return type
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16647
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 8 Aug 2004 21:09:38 +0000 (21:09 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): On AIX and OSF/1, always add
$PTHREAD_CFLAGS to CFLAGS for use in later tests.
(WITH_CC): If on AIX and not using gcc, add -qhalt=e to CFLAGS.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16646
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sat, 7 Aug 2004 15:52:52 +0000 (15:52 +0000)]
* configure.in: Look for sched.h and sched_yield.
* k5-thread.h: Only include sched.h if it's available.
(MAYBE_SCHED_YIELD): Only use sched_yield if sched.h and sched_yield are
available; if weak references are supported and sched_yield isn't available by
default, check for it at run time.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16645
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Fri, 6 Aug 2004 20:41:13 +0000 (20:41 +0000)]
updated for new files
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16644
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 5 Aug 2004 20:26:42 +0000 (20:26 +0000)]
* cc_file.c: Remove USE_STDIO support
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16643
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 5 Aug 2004 07:42:46 +0000 (07:42 +0000)]
* k5-thread.h [HAVE_PTHREAD]: Include sched.h if DEBUG_THREADS_SLOW is defined.
(MAYBE_SCHED_YIELD) [HAVE_PTHREAD]: Define, to call sched_yield or not,
depending on DEBUG_THREADS_SLOW.
(k5_os_mutex_lock, k5_os_mutex_unlock) [HAVE_PTHREAD]: Use MAYBE_SCHED_YIELD.
(DEBUG_THREADS_SLOW): Define.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16642
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Aug 2004 06:59:37 +0000 (06:59 +0000)]
* srv_rcache.c (krb5_get_server_rcache): Call krb5_rc_recover_or_initialize
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16641
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Aug 2004 06:58:17 +0000 (06:58 +0000)]
* rc-int.h (struct _krb5_rc_ops): Add new member, recover_or_init.
* rc_dfl.c (krb5_rc_dfl_init_locked): New function, with most of the content of
old krb5_rc_dfl_init.
(krb5_rc_dfl_init): Call it.
(krb5_rc_dfl_recover_or_init): New function.
* rc_dfl.h (krb5_rc_dfl_recover_or_init): Declare.
* rcdef.c (krb5_rc_dfl_ops): Initialize new field.
* rc_none.c (krb5_rc_none_recover_or_init): New macro.
(krb5_rc_none_ops): Initialize new field.
* rcfns.c (krb5_rc_recover_or_initialize): New function.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16640
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Aug 2004 06:53:03 +0000 (06:53 +0000)]
* k5-int.h (krb5_rc_recover_or_initialize): Declare
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16639
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Aug 2004 06:46:15 +0000 (06:46 +0000)]
* configure.in: Actually check for pthread_mutex_lock
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16638
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 3 Aug 2004 20:56:25 +0000 (20:56 +0000)]
* configure.in: Build makefile for new "threads" subdirectory
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16637
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 3 Aug 2004 20:55:32 +0000 (20:55 +0000)]
* Makefile.in, t_rcache.c: New files
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16636
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sat, 31 Jul 2004 08:34:16 +0000 (08:34 +0000)]
* threads.c (krb5int_thread_support_init): Do finish initialization after key creation in POSIX case
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16635
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 30 Jul 2004 21:10:45 +0000 (21:10 +0000)]
Implement new replay cache type "none"
* rc_none.c: New file.
* Makefile.in (SRCS, STLIBOBJS, OBJS): Build it.
* rc-int.h (krb5_rc_none_ops): Declare.
* rc_base.c (none): New variable.
(krb5_rc_typelist_dfl): Add it into the linked list.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16634
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Fri, 30 Jul 2004 19:52:36 +0000 (19:52 +0000)]
* configure.in: Only sanity-check setutent() API if there is no
utmpx.h, since some setutent() implementations aren't sysV-derived,
e.g., NetBSD.
ticket: 2432
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16633
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 30 Jul 2004 03:55:07 +0000 (03:55 +0000)]
* gssapi_krb5.c (kg_ccache_name): Variable deleted.
(kg_sync_ccache_name, kg_get_ccache_name, kg_set_ccache_name): Get and set
thread-specific values instead.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16632
dc483132-0cff-0310-8789-
dd5450dbe970
Sam Hartman [Thu, 29 Jul 2004 15:29:21 +0000 (15:29 +0000)]
Export lucid context functions and gss_krb5_set_allowable_enctypes
Ticket: 2587
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16631
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 29 Jul 2004 02:26:43 +0000 (02:26 +0000)]
Add a mutex to the GSSAPI krb5 mechanism credential structure. Lock it while
frobbing the contents.
Also added krb5_gss_validate_cred_1, which is like krb5_gss_validate_cred but
for internal use. It lets the caller supply the krb5_context instead of
creating yet another one locally, and leaves the new credential mutex locked on
a successful return so that the caller doesn't have to reacquire it. More
functions should be changed to use this internally, but it's a performance
issue; I don't think it's a correctness or thread-safety issue.
* gssapiP_krb5.h (struct _krb5_gss_cred_id_rec): Add a mutex.
(krb5_gss_validate_cred_1): Declare.
* accept_sec_context.c (rd_and_store_for_creds): Initialize mutex.
* acquire_cred.c (krb5_gss_acquire_cred): Initialize mutex.
* add_cred.c (krb5_gss_add_cred): Create the krb5 context earlier. Call
krb5_gss_validate_cred_1. Make sure the mutex is locked.
* copy_ccache.c (gss_krb5_copy_ccache): Lock the mutex in the source
credential.
* init_sec_context.c (get_credentials, new_connection): Check that the mutex is
locked.
(mutual_auth): Delete unused credential argument.
(krb5_gss_init_sec_context): Lock the mutex.
* inq_cred.c (krb5_gss_inquire_cred): Lock the mutex.
* rel_cred.c (krb5_gss_release_cred): Destroy the mutex.
* set_allowable_enctypes.c (gss_krb5_set_allowable_enctypes): Lock the mutex.
* val_cred.c (krb5_gss_validate_cred_1): New function.
(krb5_gss_validate_cred): Use it.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16630
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 29 Jul 2004 01:50:02 +0000 (01:50 +0000)]
* set_ccache.c (gss_krb5_ccache_name): Don't make a copy of the string returned
by kg_get_ccache_name. Simplify some calls using a temporary error code
variable.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16629
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 29 Jul 2004 01:48:05 +0000 (01:48 +0000)]
* gssapi_krb5.c (kg_get_ccache_name): Make the copy always, not just
in the local-context case. Check for errors in making the copy.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16628
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 28 Jul 2004 23:48:05 +0000 (23:48 +0000)]
* gssapi_krb5.c (kg_get_ccache_name): Make a copy of the default ccache name,
because calling krb5_free_context will destroy it.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16627
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 28 Jul 2004 23:45:27 +0000 (23:45 +0000)]
* tcl_kadm5.c (parse_flags, parse_keysalts, parse_key_data, parse_tl_data,
parse_principal_ent, parse_policy_ent): Use Tcl_Free, not free, to release
storage allocated by Tcl_SplitList.
* tcl_ovsec_kadm.c (parse_flags, parse_principal_ent, parse_policy_ent):
Likewise.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16626
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 28 Jul 2004 23:38:54 +0000 (23:38 +0000)]
* k5-thread.h [HAVE_PRAGMA_WEAK_REF]: Declare the pthread mutex functions as
weak.
(USE_PTHREAD_LOCK_ONLY_IF_LOADED): Define if pthread_mutex_lock isn't available
by default.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16625
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Mon, 26 Jul 2004 07:04:18 +0000 (07:04 +0000)]
cc_mslsa.c: fix is_windows_xp not to return true for windows 2000
ticket: 2645
tags: pullup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16624
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Sat, 24 Jul 2004 00:40:18 +0000 (00:40 +0000)]
another krb4 ticket backdating fix
* kerberos_v4.c (kerberos_v4): Duplicate backdating fix for
APPL_REQUEST as well. Fix comments.
ticket: new
version_reported: 1.3.3
target_version: 1.3.5
tags: pullup
component: krb5-kdc
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16623
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 23 Jul 2004 15:29:53 +0000 (15:29 +0000)]
Add a mutex to protect the per-process fake-getaddrinfo data cache.
Currently it gets locked while a name lookup is in progress, which is not very
efficient. That should be changed, after the code is fixed up so that the
cache works on other platforms.
* include/fake-addrinfo.h: Include k5-thread.h.
(struct fac): Add a mutex.
(plant_face, find_face): Check that mutex is already locked.
(krb5int_lock_fac, krb5int_unlock_fac): Declare.
(fai_add_hosts_by_name): Use them to lock and unlock the mutex.
* util/support/fake-addrinfo.c (krb5int_fac): Initialize the mutex.
(krb5int_init_fac, krb5int_fini_fac): New functions; finish initializing or
destroy the mutex.
(krb5int_lock_fac, krb5int_unlock_fac): New functions; lock the mutex after
calling krb5int_call_thread_support_init, or unlock it.
* util/support/threads.c (krb5int_call_thread_support_init): New function.
(krb5int_init_fac, krb5int_fini_fac): Declare.
(krb5int_thread_support_init, krb5int_thread_support_fini): Call them.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16622
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 22 Jul 2004 22:03:52 +0000 (22:03 +0000)]
[needs the include/configure.in checkin of a few minutes ago, too]
* localaddr.c (get_lifconf): Define only if "struct lifconf" is available.
(foreach_localaddr): Use get_lifconf only if "struct lifconf" is available.
ticket: 2598
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16621
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 22 Jul 2004 21:50:22 +0000 (21:50 +0000)]
* configure.in: Look for "struct lifconf" and maybe define HAVE_STRUCT_LIFCONF
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16620
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 21 Jul 2004 03:29:46 +0000 (03:29 +0000)]
* implementor.texinfo (Compiler and OS Requirements): New section
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16619
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 21 Jul 2004 03:05:06 +0000 (03:05 +0000)]
* implementor.texinfo (Thread Safety): Rewrite; add subsections.
(Advanced Shared Library Requirements): Use @defmac where appropriate. Make
sure return types are specified where needed. Mention export lists. Indicate
last-update date.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16618
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 21 Jul 2004 00:29:24 +0000 (00:29 +0000)]
* implementor.texinfo: Changed @code to @file where files are referenced.
(Advanced Shared Library Requirements): New section.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16617
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 20 Jul 2004 23:20:35 +0000 (23:20 +0000)]
* implementor.texinfo (NetBSD Shared Library Support, Solaris Shared Library
Support): Outdated sections deleted.
(Shared Library Theory): Fixed typo.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16616
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 19 Jul 2004 20:51:38 +0000 (20:51 +0000)]
* fake-addrinfo.h (struct face, struct fac): Always declare.
(krb5int_fac): Renamed from fac, and made extern. Always declare.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16615
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 19 Jul 2004 20:47:12 +0000 (20:47 +0000)]
* fake-addrinfo.c: New file.
* Makefile.in (STLIBOBJS, LIBOBJS, SRCS): Add it.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16614
dc483132-0cff-0310-8789-
dd5450dbe970
Ezra Peisach [Sun, 18 Jul 2004 04:10:22 +0000 (04:10 +0000)]
* cc_memory.c (krb5_mcc_store): When allocating krb5_mcc_link
memory - allocate sizeof() - not sizeof(sizeof()).
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16613
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sat, 17 Jul 2004 00:37:28 +0000 (00:37 +0000)]
zap remaining bits of macsock.h support
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16612
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 22:15:14 +0000 (22:15 +0000)]
update dependencies
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16611
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 21:56:10 +0000 (21:56 +0000)]
update dependencies
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16610
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 21:55:12 +0000 (21:55 +0000)]
* pty-int.h: Include port-sockets.h instead of netdb.h and netinet/in.h
ticket: 2379
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16609
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 21:12:30 +0000 (21:12 +0000)]
* fake-addrinfo.h: Don't include netdb.h, since port-sockets.h already does.
* port-sockets.h: Define _XOPEN_SOURCE_EXTENDED around inclusion of netdb.h if
it's not defined and not Windows, as fake-addrinfo.h used to do; otherwise just
include it normally.
ticket: 2379
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16608
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 21:07:42 +0000 (21:07 +0000)]
* kadmin.M: Put space after ".B" directive
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16606
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 20:53:46 +0000 (20:53 +0000)]
* compat_recv.c: Only include sys/select.h if it's available
ticket: 2592
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16605
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 16 Jul 2004 20:50:40 +0000 (20:50 +0000)]
* port-sockets.h (inet_ntop): Cast NULL to desired return pointer type
ticket: 2592
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16604
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 15 Jul 2004 20:05:06 +0000 (20:05 +0000)]
Added thread support code to project
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16603
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 15 Jul 2004 17:45:04 +0000 (17:45 +0000)]
Remove use of client principal from krb5_context (default_ccprincipal) and default principal from v4 CCAPI glue code
ticket: 2634
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16602
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Thu, 15 Jul 2004 07:39:14 +0000 (07:39 +0000)]
fix previous commit
ticket: 2637
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16601
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Thu, 15 Jul 2004 07:38:09 +0000 (07:38 +0000)]
* k5-int.h: define for WIN32 the macro krb5int_zap_data to
utilize the Win32 API SecureZeroMemory which is guaranteed
by Microsoft not to be optimized out by the compiler.
Both memset and ZeroMemory will be optimized out by the
compiler when possible.
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16600
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 15 Jul 2004 01:12:26 +0000 (01:12 +0000)]
* Makefile.in (MLIBS): Add $(LIBS)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16599
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 15 Jul 2004 01:11:24 +0000 (01:11 +0000)]
* libprofile.exports: Don't try to export krb5int_profile_shared_data
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16598
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 15 Jul 2004 01:00:54 +0000 (01:00 +0000)]
Get rid of the global krb5 context used by the GSSAPI Kerberos mechanism. I
*think* I've gotten all the places where a ccache or keytab name that's been
stored gets applied to whichever context needs it.
* gssapi_krb5.c (kg_sync_ccache_name): Add context argument instead of calling
kg_get_context.
(kg_get_ccache_name): Use a locally created krb5 context instead of calling
kg_get_context.
(kg_get_context): Deleted.
* acquire_cred.c (acquire_init_cred): Pass current context.
(krb5_gss_acquire_cred): Use a locally created krb5 context instead of calling
kg_get_context.
* add_cred.c (krb5_gss_add_cred): Call kg_sync_ccache_name.
* init_sec_context.c (krb5_gss_init_sec_context): Likewise.
* gssapiP_krb5.h (kg_sync_ccache_name): Update prototype.
(kg_get_context): Delete declaration.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16597
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 21:14:51 +0000 (21:14 +0000)]
* t_cc.c (cc_test): Rename one of the "resolve" cases so the messages can be
distinguished.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16596
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 21:06:22 +0000 (21:06 +0000)]
* recvauth.c (krb_recvauth): Initialize cp and tmp_buf. Check length of data
read before evaluating the value.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16595
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:54:16 +0000 (01:54 +0000)]
* set_ccache.c (gss_krb5_ccache_name): Check thread-specific data for the saved
"old" name to free. Save the new old name in thread-specific data.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16594
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:46:36 +0000 (01:46 +0000)]
* gssapiP_krb5.h (gssint_krb5_keytab_lock): Declare
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16593
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:45:12 +0000 (01:45 +0000)]
* gss_libinit.c (gssint_lib_init): Initialize new keytab-name mutex, and
register two new key values.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16592
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:44:50 +0000 (01:44 +0000)]
* Makefile.in (SHLIB_EXPDEPS): Use _DEPLIB variables.
(SHLIB_EXPLIBS): Add $(SUPPORT_LIB).
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16591
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:40:52 +0000 (01:40 +0000)]
* acquire_cred.c: Include gss_libinit.h.
(gssint_krb5_keytab_lock): New mutex.
(krb5_gss_register_acceptor_identity, acquire_accept_cred): Lock the mutex
while manipulating krb5_gss_keytab.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16590
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:33:35 +0000 (01:33 +0000)]
* k5-platform.h (k5_call_init_function) [DELAY_INITIALIZER] [__GNUC__]: Use a
statement expression so any line number info printed by assertion failures is
useful.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16589
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 01:31:28 +0000 (01:31 +0000)]
* k5-thread.h (k5_key_t): Add a couple new values for GSSAPI ccache name manipulation
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16588
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 14 Jul 2004 00:15:23 +0000 (00:15 +0000)]
* k5-thread.h (k5_os_mutex_init, k5_os_mutex_destroy): If
USE_PTHREAD_LOCK_ONLY_IF_LOADED is defined, use pthread_mutex_init and _destroy
only if pthread support is loaded.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16587
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 12 Jul 2004 21:08:14 +0000 (21:08 +0000)]
* krb5-config.in: Substitute $(PTHREAD_CFLAGS)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16586
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 12 Jul 2004 01:41:27 +0000 (01:41 +0000)]
* shlib.conf (alpha*-dec-osf*): Use $(PTHREAD_CFLAGS) in CC_LINK_SHARED and
CC_LINK_STATIC.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16585
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 20:17:45 +0000 (20:17 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Fix typo that caused some code to be
omitted.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16584
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 17:28:15 +0000 (17:28 +0000)]
* configure.in: Use KRB5_AC_INET6
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16583
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 08:00:33 +0000 (08:00 +0000)]
* configure.in: Use KRB5_AC_INET6
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16582
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 07:44:24 +0000 (07:44 +0000)]
* klist.c: Include autoconf.h before network headers
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16581
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 07:00:03 +0000 (07:00 +0000)]
* k5-thread.h (k5_os_mutex_lock, k5_os_mutex_unlock, k5_os_mutex_assert_locked,
k5_os_mutex_assert_unlocked) [USE_PTHREAD_LOCK_ONLY_IF_LOADED]: Fix typo in
accessing non-pthread versions.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16580
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 06:55:16 +0000 (06:55 +0000)]
* fake-addrinfo.h (in6addr_any): If we need to define a static copy, rename it
with a macro first.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16579
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 06:53:32 +0000 (06:53 +0000)]
* configure.in: Check krb5_cv_inet6_with_dinet6 as well as krb5_cv_inet6 when
deciding whether to test for in6addr_any. If gcc is in use, suppress pedantic
warnings about "inline".
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16578
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 11 Jul 2004 06:05:24 +0000 (06:05 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Use PTHREAD_CFLAGS and PTHREAD_LIBS when
checking for pthread_mutexattr_setrobust_np availability with thread support
enabled.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16577
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 9 Jul 2004 23:50:35 +0000 (23:50 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Always include the thread library on
Tru64 UNIX.
(KRB5_AC_CHECK_INET6): If the first test fails, try adding -DINET6 and test
again; if it works, define INET6 for the build.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16576
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 9 Jul 2004 23:40:35 +0000 (23:40 +0000)]
* shlib.conf (alpha*-dec-osf*): Use $(PTHREAD_CFLAGS) in LDCOMBINE
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16575
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 9 Jul 2004 17:46:46 +0000 (17:46 +0000)]
* aclocal.m4 (KRB5_AC_ENABLE_THREADS): Don't test for pthread.h specifically
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16574
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 9 Jul 2004 17:45:33 +0000 (17:45 +0000)]
* k5-thread.h: Test HAVE_PTHREAD instead of HAVE_PTHREAD_H
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16573
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 9 Jul 2004 17:44:13 +0000 (17:44 +0000)]
* kdb_db2.c (krb5_db2_db_get_principal): Rename local variable "try"
to "trynum" because some systems (*cough*Tru64*cough*) turn on some
exception handling support when thread support is enabled.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16572
dc483132-0cff-0310-8789-
dd5450dbe970