Commit Graph

63 Commits

Author SHA1 Message Date
Love Hörnquist Åstrand
c0e76182db Set error string when there is no KDC for a realm.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21457 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-07-10 12:53:25 +00:00
Love Hörnquist Åstrand
8ab80e3238 Host is static memory, don't free.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21131 ec53bebd-3082-4978-b11e-865c3cabbd6b
2007-06-18 20:48:09 +00:00
Love Hörnquist Åstrand
31c6637aca (plugin_get_hosts): be more paranoid and pass in a NULLed plugin list
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19198 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-30 17:23:08 +00:00
Love Hörnquist Åstrand
feca1fb894 Fill in hints for picky getaddrinfo()s.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19010 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-13 05:06:08 +00:00
Love Hörnquist Åstrand
35ac6d4651 Use plugin for the other realm locate types too.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19008 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-13 04:46:37 +00:00
Love Hörnquist Åstrand
51bdcbd088 Use the resolve plugin interface.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19000 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-12 20:05:20 +00:00
Love Hörnquist Åstrand
7a2077bff3 (common_init): don't try DNS when there is realm w/o a dot.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@18272 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-10-06 17:11:02 +00:00
Love Hörnquist Åstrand
cf9efd9db1 (fallback_get_hosts): limit the fallback lookups to 5.
Patch from Wesley Craig, umich.edu


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17958 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-09-01 10:16:28 +00:00
Love Hörnquist Åstrand
d9b82bea73 fix spelling
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16958 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-02 10:32:20 +00:00
Love Hörnquist Åstrand
d579ee0dc9 (_krb5_krbhost_info_move): replace a strcpy with a memcpy
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16943 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-02 01:28:42 +00:00
Love Hörnquist Åstrand
66baee8800 (_krb5_krbhost_info_move): new function
(_krb5_free_krbhst_info): expose to internal use


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16155 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-10-08 15:40:50 +00:00
Love Hörnquist Åstrand
ab5d515651 (krb5_krbhst_init_flags): rename variable to avoid shadowing
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15467 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-06-17 04:23:26 +00:00
Love Hörnquist Åstrand
429998ed6e (srv_get_hosts): if srv_get_hosts failes, return and ignore the error
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15201 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-20 09:09:42 +00:00
Love Hörnquist Åstrand
ea49018330 (srv_find_realm): make sure res' and count' have good values
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15200 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-20 09:07:18 +00:00
Luke Howard
d3251a6794 Set KD_CONFIG after calling config_get_hosts() in kpasswd_get_next()
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14581 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-02-20 06:50:26 +00:00
Love Hörnquist Åstrand
91351971f7 add KRB5_LIB_FUNCTION to all exported functions
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13863 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-05-25 21:46:46 +00:00
Love Hörnquist Åstrand
f1d3b2660d also lookup _kpasswd._tcp SRV-rr
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13662 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-03-31 14:04:57 +00:00
Love Hörnquist Åstrand
9f1541abe3 (krb5_krbhst_init_flags): new function, use it and adapt callers
(krbhst_get_default_proto): new function, returns udp, or in case
large_msg was requested for the krb5_krbhst_data, use tcp.
(*): if the flag KD_LARGE_MSG was set on the krb5_krbhst_data, avoid
using udp, use krbhst_get_default_proto


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12928 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-30 17:38:18 +00:00
Love Hörnquist Åstrand
d14cfe3866 update copyright
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12106 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-22 15:08:05 +00:00
Love Hörnquist Åstrand
51d5c694e3 copy NUL too, from janj@wenf.org via openbsd
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12101 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-22 14:48:20 +00:00
Love Hörnquist Åstrand
c30d73e07e add missing variable from last commit
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12045 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-16 16:06:00 +00:00
Love Hörnquist Åstrand
80371a04ce (srv_find_realm): use strlcpy, from openbsd
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12044 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-16 16:04:32 +00:00
Jacques A. Vidrine
4f91789b25 If krbhst fails to find an entry for `kpasswd_server', it will
fallback to `admin_server'.  This will wind up returning address
info with SOCK_STREAM type, which will cause the password change to
mysteriously fail (since kpasswd is UDP only).

Hack around the problem by explicitly requesting UDP when we
fallback to `admin_server'.


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11105 ec53bebd-3082-4978-b11e-865c3cabbd6b
2002-08-16 18:48:19 +00:00
Assar Westerlund
0f1b7c5a0e (srv_find_realm): handle port numbers consistenly in local byte order
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10363 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-07-19 16:57:15 +00:00
Assar Westerlund
3a29a65b2a remember the real port number when falling back from kpasswd ->
kadmin, and krb524 -> kdc


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10210 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-07-01 16:07:32 +00:00
Assar Westerlund
a81e5ce960 (fallback_get_hosts): do not copy trailing . of hostname
add some comments


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10159 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-21 14:37:09 +00:00
Assar Westerlund
789f49bc82 use getaddrinfo instead of dns_lookup when testing for
kerberos.REALM.  this allows reusing that information when actually
contacting the server and thus avoids one DNS lookup


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10149 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-21 04:05:28 +00:00
Johan Danielsson
6e224ff15f (config_get_hosts): free hostlist
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10117 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-18 16:41:18 +00:00
Assar Westerlund
67897d708b (admin_get_next): spell kerberos correctly
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10110 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-18 05:48:16 +00:00
Assar Westerlund
9714727c3b (krb5_krbhst_get_addrinfo): add
set def_port in krb5_krbhst_info
(krb5_krbhst_free): free everything


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10075 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-17 23:09:46 +00:00
Assar Westerlund
2e11d16160 remove some more memory leaks
do not try any dns operations if there is local configuration
admin: fallback to kerberos.REALM
524: fallback to kdcs
kpasswd: fallback to admin
add some comments


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10071 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-17 12:22:36 +00:00
Assar Westerlund
96b86526c4 (common_init): remove memory leak
(main): move test program into krbhst-test


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10056 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-16 22:53:11 +00:00
Johan Danielsson
79532c577a change void* to krb5_krbhst_handle
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10052 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-16 21:52:34 +00:00
Johan Danielsson
bcfa93ee74 implement a new api that looks up one host at a time, instead of
making a list of hosts


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10050 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-16 21:46:50 +00:00
Johan Danielsson
d616eba08c remove rfc2052 support
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10036 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-06-08 22:33:27 +00:00
Assar Westerlund
3b5897517e make it robust enough so that it actually works
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@10010 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-05-28 04:20:33 +00:00
Assar Westerlund
fdf9c7294d (krb5_get_krb524hst): add and restructure the support functions
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9999 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-05-24 23:51:37 +00:00
Assar Westerlund
d27aa3b62e add some krb5_{set,clear}_error_string
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9937 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-05-14 06:14:52 +00:00
Assar Westerlund
6cce09faf2 (krb5_get_krb_changepw_hst): preferably look at kpasswd_server before
admin_server


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@9486 ec53bebd-3082-4978-b11e-865c3cabbd6b
2001-01-19 04:30:54 +00:00
Assar Westerlund
2e584a1a59 (get_krbhst): only try SRV lookup if there are none in the
configuration file


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8540 ec53bebd-3082-4978-b11e-865c3cabbd6b
2000-07-04 10:35:07 +00:00
Assar Westerlund
f378fbc40f (krb5_get_krb_changepw_hst): add
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@7574 ec53bebd-3082-4978-b11e-865c3cabbd6b
1999-12-11 23:14:25 +00:00
Johan Danielsson
c5b916ca6f remove advertising clause
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@7464 ec53bebd-3082-4978-b11e-865c3cabbd6b
1999-12-02 17:05:13 +00:00
Assar Westerlund
439ad99768 do SRV lookups for admin server as well.
some clean-up.


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@6462 ec53bebd-3082-4978-b11e-865c3cabbd6b
1999-07-14 14:02:12 +00:00
Johan Danielsson
20ed3440e0 lookup SRV-records to find a kdc for a realm
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5928 ec53bebd-3082-4978-b11e-865c3cabbd6b
1999-04-11 00:37:44 +00:00
Assar Westerlund
77931c502f (krb5_get_krb_admin_hst, krb5_get_krbhst): fix typos
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5177 ec53bebd-3082-4978-b11e-865c3cabbd6b
1998-11-01 23:45:18 +00:00
Assar Westerlund
6c552ec325 (krb5_get_krb_admin_hst): new function
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5136 ec53bebd-3082-4978-b11e-865c3cabbd6b
1998-08-25 17:31:56 +00:00
Johan Danielsson
7a4adcd82c Use krb5_config_get_strings.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@4254 ec53bebd-3082-4978-b11e-865c3cabbd6b
1998-01-03 21:09:13 +00:00
Assar Westerlund
d294202b45 *** empty log message ***
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@4020 ec53bebd-3082-4978-b11e-865c3cabbd6b
1997-11-16 09:32:31 +00:00
Johan Danielsson
8eb312128d fix warnings
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@3588 ec53bebd-3082-4978-b11e-865c3cabbd6b
1997-10-13 16:30:09 +00:00
Johan Danielsson
a9dabaf1e8 rename STRING -> krb5_config_string, and LIST -> krb5_config_list
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@3386 ec53bebd-3082-4978-b11e-865c3cabbd6b
1997-09-05 12:21:26 +00:00