Love Hörnquist Åstrand
7bf56b0e3f
(free_paid): free the krb5_data structure too.
...
Bug report from Stefan Metzmacher.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19331 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-12-14 10:49:56 +00:00
Love Hörnquist Åstrand
7624883fb4
Make krb5_get_init_creds_opt_free take a context argument.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19080 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-20 18:41:57 +00:00
Love Hörnquist Åstrand
ece5f9603e
Make krb5_get_init_creds_opt_free take a context argument.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19078 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-11-20 18:12:41 +00:00
Love Hörnquist Åstrand
b110e33a3f
minimize layering and remove krb5_kdc_flags
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@18202 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-10-02 12:00:59 +00:00
Love Hörnquist Åstrand
204118e4d1
Always use the kdc_flags in the right bit order.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@18200 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-10-02 11:54:45 +00:00
Love Hörnquist Åstrand
88182a75ce
(init_cred_loop): try to catch the error when we actually have an
...
error to catch.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17995 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-09-04 13:46:45 +00:00
Love Hörnquist Åstrand
fe562592c6
Remove debug printfs.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17989 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-09-04 11:04:35 +00:00
Love Hörnquist Åstrand
03b6a76a85
use new addressless, convert pa-pac option to use the same tri-state
...
option as the new addressless option.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17985 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-09-04 10:57:02 +00:00
Love Hörnquist Åstrand
a65edfb82d
Save KRB-ERROR on error.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17672 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-06-22 02:40:25 +00:00
Love Hörnquist Åstrand
88a91a9441
(get_init_creds_common): drop cred argument, its unused
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17657 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-06-15 14:43:16 +00:00
Love Hörnquist Åstrand
4049e76902
make compile
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17199 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-24 08:49:08 +00:00
Love Hörnquist Åstrand
a49278a8b4
Pass down realm to _krb5_pk_rd_pa_reply
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17195 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-24 08:21:52 +00:00
Love Hörnquist Åstrand
fd1ea1cc54
(init_creds_init_as_req): in AS-REQ the cname must always be given,
...
don't avoid that fact and remove a cname == NULL case. Plugs a memory
leak found by IBM checker.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16940 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-02 01:20:15 +00:00
Love Hörnquist Åstrand
0c29fd2ed1
(default_s2k_func): avoid exposing free-ed memory on error. Found by
...
IBM checker.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16939 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-04-02 01:10:35 +00:00
Love Hörnquist Åstrand
e42d007ce9
Rename private to opt_private.
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16169 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-10-12 12:45:27 +00:00
Love Hörnquist Åstrand
ffa6f55bd4
Prepare to pass down a krb5_krbhst_info into the pre-auth mechs
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16152 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-10-08 15:34:53 +00:00
Love Hörnquist Åstrand
d78bed5eaa
Save the request buffer so that pre-auth mechanism that needs it can
...
verify the reply.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15933 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-08-13 08:25:32 +00:00
Love Hörnquist Åstrand
7b778a173b
(default_s2k_func): unconst password
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15464 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-06-17 04:15:20 +00:00
Love Hörnquist Åstrand
098ce70bd4
rename variable to avoid shadowing
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15390 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-06-15 02:57:09 +00:00
Love Hörnquist Åstrand
0ec6d0d363
(process_pa_data_to_md): add comment that the caller always free
...
out_md; remove comment about memory, it doesn't happen.
(init_cred_loop): free ctx->as_req.padata when its reset (From Wynn
Wilkes <wwilkes@vintela.com >), move a comment close the the code
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15178 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-19 07:42:06 +00:00
Love Hörnquist Åstrand
9f219c721d
Now that we fixed the signed-ness of nonce for windows, remove the
...
code that removed the signed bit. Instead add comment that they still
need to be the same (Kerberos protocol nonce and pk-init nonce) for Windows.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15055 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-05-02 14:52:57 +00:00
Love Hörnquist Åstrand
a8f9738a23
if we are using PKINIT, strip of the highest bit to make windows
...
PK-INIT happy. Also make the nonces the same, again for windows, they
are using pk-init-9.
XXX check if it isn't the that nonce is an unsigned variable so its
just a asn1 mismatch.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15043 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-30 16:24:00 +00:00
Love Hörnquist Åstrand
9dd70b312a
(process_pa_data_to_key): also check for KRB5_PADATA_PK_AS_REP_19,
...
From: Douglas Engert
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14757 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-07 20:15:18 +00:00
Luke Howard
4de42cbbbb
add krb5_get_init_creds_keyblock (for now - subject to change)
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14531 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-02-02 07:30:25 +00:00
Luke Howard
240da19de0
Allow NULL in_options to be passed to krb5_get_init_creds_password()
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14522 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-01-24 10:32:43 +00:00
Love Hörnquist Åstrand
69b55bfa0b
use private version of principalname
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14423 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-12-29 18:56:43 +00:00
Love Hörnquist Åstrand
ef868c62a1
(change_password): handle old_options being NULL
...
From Guenther Deschner on samba-technical.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14351 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-11-13 20:41:54 +00:00
Love Hörnquist Åstrand
993e8c9eea
make krb5_get_init_creds_keytab work again
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14347 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-11-11 17:50:43 +00:00
Love Hörnquist Åstrand
fbd7b2787a
fold init_init_creds_ctx into get_init_creds_common
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14338 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-11-09 16:10:57 +00:00
Love Hörnquist Åstrand
64482ff6ab
(krb5_get_init_creds): kdc_reply can be set in case of failure too,
...
free unconditionally on exit to avoid memory leak
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14179 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-08-30 23:28:10 +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
Johan Danielsson
26457b7135
replace krb5_free_creds_contents by krb5_free_cred_contents
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13790 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-04-25 19:25:35 +00:00
Love Hörnquist Åstrand
0161e447c4
make the pkinit nonce same os the plain nonce for now
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13763 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-04-24 15:17:32 +00:00
Love Hörnquist Åstrand
bfd4bb3a04
(pa_data_add_pac_request): don't increase md->len, krb5_padata_add
...
already does that
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13654 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-03-30 15:54:12 +00:00
Love Hörnquist Åstrand
8696c13a7f
(process_pa_data_to_key): spelling
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13388 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-02-19 12:41:19 +00:00
Love Hörnquist Åstrand
0d4320db0b
(change_password): handle that printf("%.*s", 0, (void*)NULL); doesn't
...
work on solaris
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13326 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-02-11 12:30:35 +00:00
Love Hörnquist Åstrand
1d9702acee
try handle ts preauth better, still not good, but at least it work
...
with older heimdal releases that doesn't send back
KRB5KDC_ERR_PREAUTH_REQUIRED when preauth was sent
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13226 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-12-17 20:44:37 +00:00
Love Hörnquist Åstrand
5c2a1917c0
(init_cred_loop): fix memory leak
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13134 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-11-23 21:17:52 +00:00
Love Hörnquist Åstrand
61cd5b101e
add support for pkinit
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13093 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-11-08 08:52:07 +00:00
Johan Danielsson
744bd74233
krb5_princ_realm -> krb5_principal_get_realm
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13022 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-10-20 16:14:02 +00:00
Love Hörnquist Åstrand
0c7a5a4563
add some help function that is common between ENC_TS and SAM2
...
free the etype{,2}-infos on failure
move the pa counter into krb5_get_init_creds_ctx
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12984 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-10-07 07:48:51 +00:00
Love Hörnquist Åstrand
d5acb83777
(*) send PA_PAC_REQUEST when the user have requested either use PAC or
...
not use PAC, if the option not set from the user, leave it up to the
kdc to decide.
(init_creds_loop): clear error string on success
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12956 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-10-03 11:53:48 +00:00
Love Hörnquist Åstrand
2b7e870bf4
(init_cred_loop): handle KRB5KRB_ERR_RESPONSE_TOO_BIG and loop again,
...
this time requesting LARGE_MSG from send to kdc, and if this is the
second time bail out; try to free memory
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12930 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-30 18:05:27 +00:00
Love Hörnquist Åstrand
d3c498eae5
use _krb5_get_init_creds_opt_copy
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12897 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-21 16:51:13 +00:00
Love Hörnquist Åstrand
332e117688
(init_init_creds_ctx): make void since it doesn't return an error,
...
update call sites
(krb5_get_init_creds_keytab): add out label again
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12874 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-18 22:20:50 +00:00
Love Hörnquist Åstrand
21554e0cbb
collect all init_creds context into a structure so it can easier be
...
passed around, also, while here, change nonce for every request
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12847 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-18 18:40:44 +00:00
Love Hörnquist Åstrand
646ee1b761
break out the encrypt timestamp preauth to its function
...
break out the pa_data_to_key_plain to its own function
make more variables const
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12766 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-04 05:30:48 +00:00
Love Hörnquist Åstrand
eb2c032414
(krb5_get_init_creds_password): handle password passed in though context
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12732 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-02 23:41:34 +00:00
Love Hörnquist Åstrand
aa3701f551
rewrite/implement krb5_get_init_creds_password with new preauth
...
handing, still it can only work with krb5-pa-enc-timestamp for
preauth, but now it can handle etype-info2
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12727 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-02 23:17:08 +00:00
Love Hörnquist Åstrand
b73e0996b7
(c) year update
...
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11895 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-03-20 18:07:31 +00:00