Tom Yu [Sat, 4 Aug 2007 00:02:42 +0000 (00:02 +0000)]
krb5_fcc_generate_new() doesn't work with mkstemp()
If mkstemp() is available, the new ccache file gets created but the
subsequent open(O_CREAT|O_EXCL) call fails because the file was
already created by mkstemp(). Apply patch from Apple to keep the file
descriptor open.
ticket: new
tags: pullup
target_version: 1.6.3
component: krb5-libs
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19749
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Fri, 3 Aug 2007 21:16:19 +0000 (21:16 +0000)]
Based on Apple's patch, during the referrals loop, check to see if the
session key enctype of a returned credential for the final service is
among the enctypes explicitly selected by the application, and retry
with old_use_conf_ktypes if it is not.
ticket: 4950
tags: pullup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19748
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 3 Aug 2007 13:22:23 +0000 (13:22 +0000)]
NIM: apply does not update saved values of general identities cfg page
The general identities configuration panel failed to update the saved values
of the DefaultMonitor, DefaultAllowAutoRenew, and DefaultSticky options after
the "Apply" button was pressed. This resulted in the subsequent value changed
states being incorrect.
This patch saves the values.
ticket: new
component: windows
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19747
dc483132-0cff-0310-8789-
dd5450dbe970
Ezra Peisach [Fri, 3 Aug 2007 02:36:26 +0000 (02:36 +0000)]
Add internal prototype for krb5_preauth_supply_preauth_data(). Clean up
some shadow variable warnings, make depend...
ticket: 5617
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19746
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Coffman [Wed, 1 Aug 2007 22:09:13 +0000 (22:09 +0000)]
Add PKINIT support
Pull up PKINIT support onto the trunk.
Changes from the version in branch users/coffman/pkinit are:
- Update the preauth plugin interface version to avoid
conflict with any existing plugins.
- Add a pkcs11.h locally to the pkinit code rather than
depending on opensc being installed.
ticket: new
Target_Version: 1.6.3
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19745
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 1 Aug 2007 00:01:31 +0000 (00:01 +0000)]
Define snprintf along with vsnprintf for Windows
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19742
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 1 Aug 2007 00:00:25 +0000 (00:00 +0000)]
Don't define vsnprintf for Windows here
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19741
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Tue, 31 Jul 2007 20:23:02 +0000 (20:23 +0000)]
Implemented and tested cc_ccache_wait_for_change()
ticket: 4644
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19740
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:39:48 +0000 (04:39 +0000)]
Set KTFILEP field to null any time we close the file
ticket: 3099
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19739
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:39:21 +0000 (04:39 +0000)]
Debugged version of patch worked up with Luke
Adds a callback to krb5int_sendto to examine the response and indicate
whether to quit the loop or not. For sendto_kdc, keep going if the
returned error is "service unavailable". Updated all other callers to
pass a null function pointer, which means to always break out of the
loop on any response (the old behavior).
ticket: 3334
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19738
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:39:05 +0000 (04:39 +0000)]
make depend
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19737
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:38:46 +0000 (04:38 +0000)]
Check for null file handle in get_next.
Patch from Luke Howard.
ticket: 5471
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19736
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:38:32 +0000 (04:38 +0000)]
Provide {,v}asprintf prototypes if needed
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19735
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:38:18 +0000 (04:38 +0000)]
Check whether a prototype for vasprintf is needed
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19734
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 27 Jul 2007 04:37:50 +0000 (04:37 +0000)]
If no salt is included with the key data, set the salt length field to 0.
Bug report and patch from Nalin Dahyabhai.
ticket: 5545
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19733
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Wed, 25 Jul 2007 19:50:37 +0000 (19:50 +0000)]
Updated API version to 7 because we added the wait_for_change functions
ticket: 4644
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19732
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Wed, 25 Jul 2007 19:29:39 +0000 (19:29 +0000)]
Added callback support for wait_for_change functions
ticket: 4644
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19731
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Sun, 22 Jul 2007 09:17:20 +0000 (09:17 +0000)]
Include k5-platform.h
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19729
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 20 Jul 2007 08:51:58 +0000 (08:51 +0000)]
Pull out code for looking up the current time, comparing the offset of
a supplied timestamp against the configured maximum clock skew, and
possibly generating an error message, into a separate routine.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19722
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 20 Jul 2007 07:59:38 +0000 (07:59 +0000)]
declare xasprintf
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19721
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 20 Jul 2007 03:20:36 +0000 (03:20 +0000)]
provide more useful error message when running kpropd on command line
The way kpropd indicates that it's supposed to be connected to the network
is by printing out a socket error:
kpropd: getpeername: Socket operation on non-socket
With this patch, it's a bit more friendly:
./kpropd: Standard input does not appear to be a network socket.
(Not run from inetd, and missing the -S option?)
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19720
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 19 Jul 2007 21:13:01 +0000 (21:13 +0000)]
Made callback code generic so that change time callbacks can use it as well
ticket: 4644
status: open
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19719
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 19 Jul 2007 21:10:57 +0000 (21:10 +0000)]
Added new autogenerated file to generate-files-mac target
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19718
dc483132-0cff-0310-8789-
dd5450dbe970
Alexandra Ellwood [Thu, 19 Jul 2007 18:32:44 +0000 (18:32 +0000)]
ccs_pipe_t needs copy and release functions
On Windows it is an allocated type.
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19717
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 13 Jul 2007 00:12:52 +0000 (00:12 +0000)]
make depend
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19710
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:35:24 +0000 (23:35 +0000)]
Use [v]snprintf or asprintf instead of unchecked sprintf and separate allocation size calculations
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19709
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:35:09 +0000 (23:35 +0000)]
Create and use xasprintf akin to xmalloc, returns pointer on success or exits on error
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19708
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:34:55 +0000 (23:34 +0000)]
Recommend snprintf/asprintf. Specify 'static inline'. Use @code for in6addr_any
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19707
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:34:41 +0000 (23:34 +0000)]
Missed a sprintf->snprintf switch
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19706
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:34:21 +0000 (23:34 +0000)]
Avoid unchecked sprintf in some KDC-side programs
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19705
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:34:04 +0000 (23:34 +0000)]
Avoid unchecked sprintf in some more support code
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19704
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:33:25 +0000 (23:33 +0000)]
Avoid use of unchecked sprintf in libraries. Use asprintf if the
output buffer is allocated according to the size of data to be
written, or snprintf otherwise.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19703
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 12 Jul 2007 23:32:45 +0000 (23:32 +0000)]
Nuke disabled support for ancient .klogin syntax
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19702
dc483132-0cff-0310-8789-
dd5450dbe970
Justin Anderson [Thu, 12 Jul 2007 17:57:37 +0000 (17:57 +0000)]
Filled in dummy descriptions. Also, no longer errors out of test with ccIteratorEnd
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19701
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Koch [Thu, 12 Jul 2007 17:55:06 +0000 (17:55 +0000)]
Add #ifdef WIN32 section
TargetVersion: 1.7
Component: krb5-libs
Ticket: 5594
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19700
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Koch [Thu, 12 Jul 2007 17:52:52 +0000 (17:52 +0000)]
#include of Kerberos.h removed. It can't work on Windows and looks like its not needed on the Mac, either
TargetVersion: 1.7
Component: krb5-libs
Ticket: 5594
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19699
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Koch [Thu, 12 Jul 2007 14:46:56 +0000 (14:46 +0000)]
Added dummy Description arguments where needed. Compiles on Windows now
TargetVersion: 1.7
Component: krb5-libs
Ticket: 5594
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19694
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Koch [Thu, 12 Jul 2007 14:45:47 +0000 (14:45 +0000)]
Added dummy Description arguments where needed. Compiles on Windows now
TargetVersion: 1.7
Component: krb5-libs
Ticket: 5594
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19693
dc483132-0cff-0310-8789-
dd5450dbe970
Kevin Koch [Wed, 11 Jul 2007 20:31:54 +0000 (20:31 +0000)]
TargetVersion: 1.7
Component: krb5-libs
Ticket: new
Subj: Work on compiling the CCAPI test suite on Windows.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19692
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 10 Jul 2007 07:02:08 +0000 (07:02 +0000)]
make depend
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19688
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 10 Jul 2007 06:55:08 +0000 (06:55 +0000)]
Get rid of .o files when cleaning
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19687
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 5 Jul 2007 19:10:52 +0000 (19:10 +0000)]
Set PERL
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19677
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 05:58:12 +0000 (05:58 +0000)]
Make error_map.h depend on ktemplate.pm too
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19675
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 05:57:30 +0000 (05:57 +0000)]
Add a note at the start of the output reminding the reader that it's a generated file
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19674
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 05:47:49 +0000 (05:47 +0000)]
Handle 'Credentials cache file <path> not found'
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19673
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 05:46:24 +0000 (05:46 +0000)]
gss krb5 mech enhanced error messages
Save detailed error messages (usually from the krb5 library) in
per-thread storage, mapping each error code to the most recently
produced message for it. Return the message from display_status.
Currently not implemented for a few cases where the krb5 mechanism
returns a minor status code of 0, or another value different from the
libkrb5 error code.
Other functions are available to store a generic string or formatted
message, but aren't used much at present.
Tested with these errors in context establishment:
* missing ccache (libkrb5 shows pathname if FILE: type)
* missing keytab (libkrb5 shows pathname if FILE: type)
* server principal unknown (libkrb5 shows server principal)
ticket: new
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19672
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 04:27:32 +0000 (04:27 +0000)]
Use strdup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19671
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 04:26:14 +0000 (04:26 +0000)]
Use global spawn_id
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19670
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 04:06:54 +0000 (04:06 +0000)]
Perl code for generating "map" routines from a common template with
supplied type info.
* ktemplate.pm: Code for parsing a command line and writing out a
supplied template with substitutions.
* gen-map.pl: Parameter info and template for "map" type.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19669
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 04:03:44 +0000 (04:03 +0000)]
Add a new per-thread datum for error message info in gssapi krb5 mech
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19668
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 04:00:36 +0000 (04:00 +0000)]
Some handy debugging code for gssapi errors in credential acquisition; currently disabled
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19667
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 03:51:45 +0000 (03:51 +0000)]
If error is KDC_ERR_S_PRINCIPAL_UNKNOWN, report the server name
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19666
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 03:49:52 +0000 (03:49 +0000)]
In file-not-found case, report the filename sought
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19665
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 01:58:06 +0000 (01:58 +0000)]
Remove debugging message accidentally left in
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19664
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 01:49:17 +0000 (01:49 +0000)]
Save a detailed message for FCC_NOFILE including the file name
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19663
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 4 Jul 2007 01:04:13 +0000 (01:04 +0000)]
When skipping debugging '-->' data, only take through the end of the line
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19662
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 3 Jul 2007 22:51:53 +0000 (22:51 +0000)]
Report in make output when updating OBJS.ST/SH/PF
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19661
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 3 Jul 2007 19:09:20 +0000 (19:09 +0000)]
Tell Emacs to use C mode for this file
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19660
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 2 Jul 2007 19:13:05 +0000 (19:13 +0000)]
Test for va_copy should be a link test, not a compile test
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19659
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Mon, 2 Jul 2007 19:11:53 +0000 (19:11 +0000)]
Include k5-platform.h
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19658
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 02:37:57 +0000 (02:37 +0000)]
Check for error indication from localtime.
In a few cases this means changing internal function signatures to
allow for passing back the error indication up the call stack.
Thanks to Domagoj Babic for pointing out the possible null pointer
dereferences that would result if localtime fails.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19656
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 02:32:02 +0000 (02:32 +0000)]
Define a localtime_r wrapper around localtime if the system doesn't
provide localtime_r, instead of handling it in-line. Check for error
indication from localtime_r. Call localtime_r only once instead of
each time around the loop.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19655
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 01:55:08 +0000 (01:55 +0000)]
Under gcc, declare k5_v?asprintf with format attribute
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19654
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 01:01:24 +0000 (01:01 +0000)]
Attach format attributes to declarations of various message-formatting
routines under gcc. In a couple of routines, hard-code the preference
for using the vsnprintf paths instead of list-of-int-arguments hacks
now that we're assuming vsnprintf is available in other places.
Installed headers affected:
com_err.h (com_err, com_err_va)
ss.h (ss_error)
krb5.h (krb5_set_error_message, krb5_vset_error_message)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19653
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 00:31:10 +0000 (00:31 +0000)]
Even though the passed string never has a %, use an explicit %s format string in fprintf call to make analysis simpler
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19652
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Fri, 29 Jun 2007 00:28:32 +0000 (00:28 +0000)]
Ignore __attribute__
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19651
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 28 Jun 2007 23:36:51 +0000 (23:36 +0000)]
Check for null pointer returns when allocating storage.
Clean up some memory leaks in out-of-memory error paths.
Use strdup and asprintf when appropriate.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19650
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 28 Jun 2007 00:09:34 +0000 (00:09 +0000)]
Update mkstemp and export-list handling for Windows
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19646
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Thu, 28 Jun 2007 00:08:21 +0000 (00:08 +0000)]
Implement S_ISDIR from S_IFMT or _S_IFMT if necessary (e.g., on Windows)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19645
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 27 Jun 2007 23:43:04 +0000 (23:43 +0000)]
For Win32 environment, define CAN_COPY_VA_LIST, and define an inline
version of vsnprintf using the MS versions. (Apparently no need for
plain snprintf just yet.)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19644
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 27 Jun 2007 23:22:36 +0000 (23:22 +0000)]
If mkstemp is missing, define the mkstemp macro is k5-platform.h, not autoconf.h
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19643
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 26 Jun 2007 23:04:09 +0000 (23:04 +0000)]
* v4rcp.c (error): Use stdarg version always. Call vsnprintf instead of vsprintf.
(strsave): Call strdup.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19642
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 26 Jun 2007 22:58:46 +0000 (22:58 +0000)]
* v4rcp.c (kstream_write): Allocate buffer space if it hasn't been
allocated, in the encrypting case, even if outlen is zero. While I
don't believe this can ever happen, it requires careful examination of
lots of code paths to figure it out. This change doesn't fix a
serious bug, but makes the analysis simple. Also, don't bother with
separate code paths for malloc vs realloc depending on the previous
values; we can just use realloc always.
Thanks to Domagoj Babic for pointing out the (false but
understandable) null-pointer problem.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19641
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Tue, 26 Jun 2007 22:50:36 +0000 (22:50 +0000)]
Check malloc return for null in kstream_create_* instead of
unconditionally dereferencing. Thanks to Domagoj Babic for finding
the bug.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19640
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Tue, 26 Jun 2007 18:08:35 +0000 (18:08 +0000)]
fix MITKRB5-SA-2007-005 [CVE-2007-2798/VU#554257]
Truncate the principal names when logging a rename operation to avoid
a stack buffer overflow.
ticket: new
target_version: 1.6.2
tags: pullup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19637
dc483132-0cff-0310-8789-
dd5450dbe970
Tom Yu [Tue, 26 Jun 2007 18:08:20 +0000 (18:08 +0000)]
fix MITKRB5-SA-2007-004 [CVE-2007-2442/VU#356961, CVE-2007-2443/VU#365313]
CVE-2007-2442/VU#356961: The RPC library can free an uninitialized
pointer. This may lead to execution of arbitrary code.
CVE-2007-2443/VU#365313: The RPC library can write past the end of a
stack buffer. This may (but is unlikely to) lead to execution of
arbitrary code.
ticket: new
target_version: 1.6.2
tags: pullup
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19636
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:06:44 +0000 (19:06 +0000)]
Update configuration schema in ui\uiconfig.csv to include additional
documentation for settings and and remove unused values.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19635
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:05:44 +0000 (19:05 +0000)]
The new credentials window now applies Windows XP theme settings to
dialog panels that are hosted within tab controls.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19634
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:04:54 +0000 (19:04 +0000)]
1. Add a '--minimized' option to start NIM in minimized mode
2. If the NIM window is requested to open in a minimized state, keep
the window hidden until there's a request to show it.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19633
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:03:57 +0000 (19:03 +0000)]
1. Use the debug CRT versions of the memory allocation functions in
util\perfstat.c. These functions allow associating file and line
numbers with each allocation.
2. Perform a heap verification periodically to check for heap
corruption in the debug build when using util\perfstat.c to manage
memory allocations.
3. Change wcscmp() to _wcscmp() for compatibility in util\perfstat.h
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19632
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:02:50 +0000 (19:02 +0000)]
1. Fix a malformed line in ui\lang\en_us\khapp.rc in a TEXTINCLUDE
section.
2. Update the dialog template for the "About" dialog to change the
size of the dialog box and sort the modules list.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19631
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:01:51 +0000 (19:01 +0000)]
NetIDMgr:
Product version => 1.3.0.0
API version => 9
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19630
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 19:00:27 +0000 (19:00 +0000)]
Be more aggressive about forcing the new credentials dialog to the
top.
Many applications call GSSAPI functions from the main GUI thread.
Doing so blocks the window message pump for that application. When
the GSSAPI call results in the new credentials dialog being displayed,
it will be unable to bring itself to the top and grab the user input
focus because the foreground window is not responding. This patch
makes the new credentials window a top-most window at creation time
that results in it being created at the top of the Z-order. It can
then flash the window to indicate that it requires user attention.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19629
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:59:35 +0000 (18:59 +0000)]
If the new credentials window is in the advanced mode and the user
tries to switch back to basic mode, we should set the active panel to
the identity selector before switching since the basic mode only
supports the identity selector panel.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19628
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:58:09 +0000 (18:58 +0000)]
Don't assume that WM_DESTROY is the last message to be received by a
window. Since the child windows are still alive and kicking by the
time the parent receives WM_DESTROY, it's still possible to receive
other messages after WM_DESTROY.
If we free any window specific data when handling WM_DESTROY, we
should reset the window data field as well, and check if we have a
valid pointer when retrieving the window data field later.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19627
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:56:56 +0000 (18:56 +0000)]
The clean:: target of plugins\common\Makefile should reference the
target directories using the symbolic names rather than hard coded
paths.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19626
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:55:46 +0000 (18:55 +0000)]
1. When freeing a message type object, it should also be removed from
the all_msg_types list.
2. When a type handler is being removed from a message type, we
shouldn't re-create the message type object if it has already been
destroyed.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19625
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:54:49 +0000 (18:54 +0000)]
. Fix formatting in kherr.c
2. The FormatMessage() call needs special handling for 64 bit
platforms. Add a compile time check for now until we figure out
what to do.
3. Remove unused code from kherr.c.
4. Correct bad references to typedefs. kherr_severity and
kherr_suggestion were sometimes referenced as 'enum kherr_severity'
and 'enum kherr_suggestion' even though they are typedefs.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19624
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:53:45 +0000 (18:53 +0000)]
Add new notification flags KHERR_CTX_NEWCHILD, KHERR_CTX_FOLDCHILD,
KHERR_CTX_PROGRESS for listeners of error context events to enable
them to listen for child context events and progress updates.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19623
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:52:40 +0000 (18:52 +0000)]
Error context objects should be verified by checking the magic number
in addition to checking if the pointer to the object is valid.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19622
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:51:34 +0000 (18:51 +0000)]
Each error context in NIM can maintain a progress counter to indicate
the progress of the operation. The progress counter for a context
that contains child contexts should be computed by adding the progress
counters of its children. This update corrects the behavior of
kherr_get_progress() and kherr_get_progress_i() to take child contexts
into account.
In addition, since the progress counter of a context now depend on the
progress counters of its children, kherr_set_progress() will send
progress change notifications for any parent context as well.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19621
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:50:26 +0000 (18:50 +0000)]
Update developer documentation
These updates reflect changes that were made to the new credentials
acquisition process and add information to incomplete API
documentation.
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19620
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:49:30 +0000 (18:49 +0000)]
Remove unused file Makefile.w2k from the uilib directory
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19619
dc483132-0cff-0310-8789-
dd5450dbe970
Jeffrey Altman [Fri, 22 Jun 2007 18:47:16 +0000 (18:47 +0000)]
All exports in nidmgr32.dll are declared as __declspec(dllexport)
using the KHMEXP macro in the header files. However, since the same
header files are used to declare imports when building applications
and plug-ins that use nidmgr32.dll, the KHMEXP macro should switch to
__declspec(import) so that the relevant import table entries are
created.
To make this switch, the source files that go into nidmgr32.dll are
compiled with the special macro _NIMLIB_ defined that indicates that
the KHMEXP should expand to __declspec(dllexport). In the absence of
this macro, KHMEXP will expand to __declspec(dllimport).
ticket: 5584
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19618
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 22:00:05 +0000 (22:00 +0000)]
Fix typo in yesterday's change (u_int_8_t -> u_int8_t)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19609
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 06:54:59 +0000 (06:54 +0000)]
Fix typo and add verbosity in function-capable shell test
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19608
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 06:11:54 +0000 (06:11 +0000)]
Remove check-ac-syms rules
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19607
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 05:47:59 +0000 (05:47 +0000)]
Configure libdb2 in top-level configure script
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19606
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 05:18:59 +0000 (05:18 +0000)]
Add the libdb2 type-existence tests to the top-level configure script.
Replace the generated header files in db2 with static ones that
include autoconf.h and make decisions based on the macros defined
there. Omit some tests that test for things we assume now, like
"const" working and "size_t" being defined. Update dependencies.
The libdb2 configure script now generates no header files.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19605
dc483132-0cff-0310-8789-
dd5450dbe970
Ken Raeburn [Wed, 20 Jun 2007 04:29:06 +0000 (04:29 +0000)]
Use k5-platform.h instead of local configure to find mkstemp
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@19604
dc483132-0cff-0310-8789-
dd5450dbe970