Commit Graph

183 Commits

Author SHA1 Message Date
Asanka C. Herath
880d728e02 Un-const as necessary to silence compiler warnings 2010-11-24 15:33:07 -05:00
Asanka C. Herath
809eccb682 Windows: Add an API for reading a multistring from registry
The _krb5_parse_reg_value_as_string() used to concatenate
multi-strings using a space to be compatible with
krb5_config_get_strings() and friends.  Add a new function that can
read a multi-string with an arbitrary delimiter character
_krb5_parse_reg_value_as_multi_string().
2010-11-24 15:32:56 -05:00
Asanka C. Herath
d3582b56c6 Define and use a path separator string
A colon can't be used to separate paths on Windows since they are used
in drive sepecification.  Define a macro that can be used as a path
separator string.  On Windows, this is defined as ";".  It is a ":"
everywhere else.
2010-11-24 15:32:56 -05:00
Asanka C. Herath
0f853405fe Add missing export and calling convention annotations 2010-11-24 15:32:49 -05:00
Asanka C. Herath
c0b62e3204 Windows: Configuration file locations can be set in the registry 2010-11-24 15:32:42 -05:00
Asanka C. Herath
dd74713e22 Windows: _krb5_load_config_from_registry() is an internal API 2010-11-24 15:32:41 -05:00
Asanka C. Herath
d247242f63 Windows: Registry based configuration
Load configuration data in the registry into a krb5_config_section.
Each registry key corresponds to a krb5_config_section and each
registry value becomes a bound string value.

The set of values contained in the root Heimdal registry key is
treated as if they were defined in the [libdefaults] section.

E.g. the configuration file:

[libdefaults]
foo = bar

[Foo]
x = y
y = {
  baz = quux
}

is equivalent to the registry keys:

[HKEY_CURRENT_USER\Software\Heimdal]
"foo"="bar"

[HKEY_CURRENT_USER\Software\Heimdal\Foo]
"x"="y"

[HKEY_CURRENT_USER\Software\Heimdal\Foo\y]
"baz"="quux"
2010-11-24 15:32:08 -05:00
Love Hornquist Astrand
ba8fe4b799 load plugin once 2010-10-27 20:42:01 -07:00
Buck Huppmann
799956e9b7 Check if we should enable weak crypto before parsing enctypes list
This since the enctypes lists doesn't include weak crypto alg in the
resulting list.

Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
2010-10-02 11:28:20 -07:00
Asanka C. Herath
cad554ad3d Generalize MSLSA ccache type to a plug-in based ccache type 2010-09-18 23:50:38 -04:00
Asanka Herath
9db9b146fb Windows: Add support for MSLSA: cache type using a plug-in 2010-09-14 08:04:11 -04:00
Love Hornquist Astrand
ba5c014af0 add krb5_get_permitted_enctypes 2010-09-08 22:04:03 -07:00
Love Hornquist Astrand
d893207413 add check-rd-req-server 2010-09-01 21:56:17 -07:00
Love Hornquist Astrand
f26d6c2398 (krb5_set_default_in_tkt_etypes): filter out unwanted enctypes
Needed for Samba that tries really hard to use DES encryption types.

Reported by Natanael Copa on heimdal-discuss
2010-03-17 09:30:11 -07:00
Love Hornquist Astrand
711ef346a0 move krb5_set_home_dir_access() group krb5 2010-02-10 18:26:46 -08:00
Love Hornquist Astrand
1f4bb75eef Only free hx509ctx if its actually allocated 2010-01-12 17:47:54 -08:00
Love Hornquist Astrand
c24a7d2d80 fix const-ifyier on cc-ops 2010-01-08 13:07:27 +01:00
Asanka Herath
16faee892e Use correct socket glue and try to maintain constness 2009-12-21 18:05:39 -05:00
Asanka Herath
a0ae9f5a0e Merge remote branch 'h-github/master' into win32-port2
* h-github/master: (64 commits)
  refix socket wrappers with rk_
  Patch from Secure Endpoints/Asanka Herath for windows support
  unset KRB5CCNAME
  its really just LIBADD more most of them
  correct quoting
  Use -lpthread for modern freebsd instead
  clean KRB5CCNAME and KRB5_CONFIG, require test to reset them
  more up ${env_setup}
  use PTHREADS_LIBADD for freebsd6 and newer
  add PTHREAD_LIBADD
  add PTHREAD_LIBADD
  add PTHREAD_LIBADD
  switch to PTHREADS_LIBADD
  log what the error string say too
  More debug logging
  sprinkle more 'echo "test failed"'
  sprinkle 'echo "test failed"'
  use calloc(), indent more prettier
  in sh, equal compare is really = for strings, not ==
  Check for duplicates, already loaded mechs
  ...

Conflicts (resolved):
	lib/krb5/auth_context.c
	lib/krb5/changepw.c
	lib/krb5/context.c
	lib/krb5/error_string.c
	lib/krb5/kuserok.c
	lib/krb5/libkrb5-exports.def.in
	lib/krb5/net_write.c
	lib/krb5/store_fd.c
	lib/krb5/test_cc.c
	lib/roken/strerror_r.c
2009-12-21 13:44:00 -05:00
Love Hornquist Astrand
687db64c56 Patch from Secure Endpoints/Asanka Herath for windows support 2009-12-21 08:45:28 +01:00
Kamen Mazdrashki
778df10ddc krb5: Fix leaked hx509_context pointer
Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
2009-12-07 09:07:07 -08:00
Asanka Herath
393a597858 SOCK_INIT/SOCK_EXIT -> rk_SOCK_INIT/rk_SOCK_EXIT and net_write_s() -> net_write() 2009-11-26 01:42:57 -05:00
Love Hornquist Astrand
f1c0c1bba3 prefix SOCKET symbols with rk_ 2009-11-25 05:29:18 +01:00
Asanka Herath
81b70c3488 Copy cc_ops and kt_types when copying a krb5_context in krb5_copy_context() 2009-11-24 10:20:19 -08:00
Asanka Herath
d6adaa775f No geteuid() on Windows 2009-11-24 10:16:49 -08:00
Asanka Herath
dc0b2b8648 Missing foo_LIB_FUNCTION fixes 2009-11-24 10:11:15 -08:00
Asanka Herath
b1063ea8fc Initial Windows port 2009-11-24 10:11:14 -08:00
Love Hornquist Astrand
bf1ecbd0ff wrap scc with have HAVE_SCC, enable running kcm as api cache 2009-11-22 11:56:43 -08:00
Love Hornquist Astrand
33002c449c deprecate krb5_get_err_text 2009-10-12 09:38:14 -07:00
Love Hornquist Astrand
a95f16503e load hx509 context 2009-09-29 11:29:02 -07:00
Love Hornquist Astrand
c0333682c6 Add logging if its specfied by the configuration file 2009-09-07 20:21:38 -07:00
Love Hornquist Astrand
13ba2956cc Check if COM_ERR_BINDDOMAIN_krb5 is defined, if it is, use bindtextdomain()
Older versions of compile_et doesn't support gettext/libintl support,
if they don't, there will be no such symbols and we can't load the
text domains for those symbols, so lets skip that.

Pointed out by Guillaume Rousse on heimdal-discuss
2009-08-26 09:02:25 -07:00
Love Hornquist Astrand
23c83fb6e3 move copy_etypes to HEIMDAL_SMALLER section 2009-08-19 16:58:29 -07:00
Love Hornquist Astrand
2f4ca1347f Don't include krb5_copy_context in a small heimdal 2009-08-19 16:53:03 -07:00
Love Hörnquist Åstrand
3f9631daaf remove RCSID
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@25172 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-05-04 06:17:52 +00:00
Love Hörnquist Åstrand
95ab53d314 unlock mutex instead of lock twice
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24953 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-03-26 01:40:19 +00:00
Love Hörnquist Åstrand
c4892701a6 make homedir work
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24952 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-03-26 01:09:43 +00:00
Love Hörnquist Åstrand
3f00119ea6 Add krb5_set_home_dir_access.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24936 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-03-25 15:35:53 +00:00
Love Hörnquist Åstrand
5684eb4435 running strsep_copy again, yield same result
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24845 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-02-27 03:28:50 +00:00
Love Hörnquist Åstrand
2dd9fc90d3 move krb5_init_etype here.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24293 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-01-11 21:50:39 +00:00
Love Hörnquist Åstrand
fe8ca9dfbf doxygen fixup
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24276 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-01-11 21:47:53 +00:00
Love Hörnquist Åstrand
6dd6406d82 allow NULL input to krb5_free_config_files
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24117 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-12-11 05:02:32 +00:00
Love Hörnquist Åstrand
c1a4666f81 mutex is always allocated, cid#142
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24106 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-12-11 05:00:39 +00:00
Love Hörnquist Åstrand
541c114033 always include SDB backend
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24032 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-11-12 04:19:20 +00:00
Love Hörnquist Åstrand
187bbfeb55 make sqlite optional
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23990 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-26 18:26:50 +00:00
Love Hörnquist Åstrand
eff9d3a6b4 Allocate the right size and init the right krb5_context
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23934 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-18 21:18:03 +00:00
Love Hörnquist Åstrand
5a7596fd02 allocate the right size
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23933 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-18 21:17:47 +00:00
Love Hörnquist Åstrand
8eb11663ce add copy config
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23928 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-18 21:16:19 +00:00
Love Hörnquist Åstrand
c708c7e9fb more working copy
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23926 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-18 21:15:46 +00:00
Love Hörnquist Åstrand
03babea1e3 switch to krb5_clear_error_message
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23911 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-14 02:55:39 +00:00