summaryrefslogtreecommitdiffstats
path: root/src/lib/krb5/krb/preauth.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix multiple memory leaks in obtain_sam_padataGreg Hudson2009-05-061-23/+29
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22320 dc483132-0cff-0310-8789-dd5450dbe970
* Fix a memory leak in krb5_obtain_padataGreg Hudson2009-05-051-1/+1
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22316 dc483132-0cff-0310-8789-dd5450dbe970
* Simplify cleanup in obtain_sam_padata slightlyGreg Hudson2009-05-041-5/+3
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22308 dc483132-0cff-0310-8789-dd5450dbe970
* Start to phase out krb5_xfree macro, which just casts its argument toKen Raeburn2009-01-281-5/+5
| | | | | | | | | | | char* and calls free. Replace most uses, outside of the LDAP KDB plugin, which doesn't build on my test system of the moment because of version dependencies. Add one explicit cast to make the change warning-neutral (under gcc 4.0.1 on Mac OS X 10.5.6). git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@21812 dc483132-0cff-0310-8789-dd5450dbe970
* Rename krb5int_buf_cstr to krb5int_buf_data, since k5bufs can be usedGreg Hudson2008-11-051-1/+1
| | | | | | | | | | | for binary data as well as C string data. The buffer will always have a null byte at krb5int_buf_len bytes regardless of whether it contains C string data. ticket: 6200 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@21003 dc483132-0cff-0310-8789-dd5450dbe970
* Use the k5buf module instead of strcpy/strcat in several placesGreg Hudson2008-10-301-16/+9
| | | | | | | ticket: 6200 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@20941 dc483132-0cff-0310-8789-dd5450dbe970
* * get_in_tkt.c (conf_yes, conf_no): Now const. References updated.Ken Raeburn2002-10-281-6/+6
| | | | | | | | * preauth.c (preauth_systems): Now const. References updated. * preauth2.c (pa_types): Now const. (krb5_do_preauth): Local array paorder now const. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14943 dc483132-0cff-0310-8789-dd5450dbe970
* protoizeKen Raeburn2002-09-031-69/+8
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14812 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c: Don't include syslog.hKen Raeburn2002-06-121-1/+0
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14502 dc483132-0cff-0310-8789-dd5450dbe970
* Use const instead of krb5_const.Ken Raeburn2002-02-231-4/+4
| | | | | | Use stdarg always, never varargs. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14162 dc483132-0cff-0310-8789-dd5450dbe970
* Danilo also says we can get rid of _MSDOS (Win16) tests, and explicit ↵Ken Raeburn2001-10-061-4/+0
| | | | | | FAR/NEAR specs git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13786 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c (krb5_obtain_padata): Don't dereference a NULL pointerTom Yu2001-01-301-0/+4
| | | | | | | | | | | if we receive an empty ETYPE_INFO preauth. [krb5-libs/903 from craziboy77@hotmail.com] * preauth2.c (krb5_do_preauth): Don't dereference a NULL pointer if we receive an empty ETYPE_INFO preauth. [krb5-libs/903 from craziboy77@hotmail.com] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12977 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c: Don't use PROTOTYPE macro, just always use the prototypesKen Raeburn2001-01-201-10/+10
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12923 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c: Remove uses of KRB5_NPROTOTYPE() macroTom Yu2001-01-201-44/+44
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12922 dc483132-0cff-0310-8789-dd5450dbe970
* * bld_pr_ext.c, bld_princ.c (krb5_build_principal_ext,Ezra Peisach2000-10-171-8/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | krb5_build_principal_va, krb5_build_principal): Take an unsigned int realm length. * get_in_tkt.c (krb5_get_init_creds): Use SALT_TYPE_AFS_LENGTH instead of -1. * gic_pwd.c (krb5_get_as_key_password): Use SALT_TYPE_AFS_LENGTH instead of -1. * in_tkt_pwd.c (pwd_keyproc): Argument to krb5_read_password is unsigned int. * pr_to_salt.c (krb5_principal2salt_internal): Declare as static. Unsigned int fix. * preauth.c (krb5_obtain_padata): Use SALT_TYPE_AFS_LENGTH instead of -1. * preauth2.c (pa_salt): Use SALT_TYPE_AFS_LENGTH instead of -1. * conv_princ.c, copy_auth.c, copy_princ.c, gc_frm_kdc.c, parse.c, send_tgs.c, srv_rcache.c: Unsigned/signed int cleanup. * unparse.c (krb5_unparse_name_ext): size parameter changed to unsigned int *. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12782 dc483132-0cff-0310-8789-dd5450dbe970
* Frank Cusack changes, set 1, diffs 1-3 of 4Ken Raeburn2000-02-071-4/+4
| | | | | | | | Rename "sam_passcode" field to "sam_sad". Add data to predicted-sam-response structure, in part to (prepare to) help with replay detection. Fix some memory allocation problems. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12005 dc483132-0cff-0310-8789-dd5450dbe970
* copyright notice updates from 1.1 branchKen Raeburn1999-09-241-1/+4
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11853 dc483132-0cff-0310-8789-dd5450dbe970
* pull up 3des implementation from the marc-3des branchMarc Horowitz1998-10-301-5/+11
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@11001 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c (handle_sam_labels):Tom Yu1998-01-031-0/+10
| | | | | | | | | (obtain_sam_padata): Check return of malloc. [krb5-libs/518] * chpw.c (krb5_mk_chpw_req): Check return of malloc. (krb5_rd_chpw_rep): Check return of malloc. [krb5-libs/518] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10346 dc483132-0cff-0310-8789-dd5450dbe970
* * Makefile.in: Add files chpw.c, gic_*, preauth2.c, vfy_increds.c,Tom Yu1997-12-061-4/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | vic_opt.c. * chpw.c: New file; implement Cygnus chpw. * get_in_tkt.c: Implement support for Cygnus initial credentials API. * gic_keytab.c: New file; Cygnus initial creds. * gic_opt.c: New file; Cygnus initial creds. * gic_pwd.c: New file; Cygnus initial creds. * preauth.c: Add more SAM support (from Cygnus). * preauth2.c: New file; additional SAM support from Cygnus. * send_tgs.c: Account for additional parameter to sendto_kdc. * vfy_increds.c: New file; Cygnus initial creds. * vic_opt.c: New file; Cygnus initial creds. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10321 dc483132-0cff-0310-8789-dd5450dbe970
* Fix handling of the sam-timestamp and sam-usec fields, which shouldTheodore Tso1997-03-251-10/+8
| | | | | | | always be set if the nonce is not available, not just SAM_USE_SAD_AS_KEY is being used. [krb5-libs/325] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10025 dc483132-0cff-0310-8789-dd5450dbe970
* Change type of first argument to be krb5_preauthtype, to eliminateTheodore Tso1996-07-241-3/+2
| | | | | | compiler warnings under Windows. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@8802 dc483132-0cff-0310-8789-dd5450dbe970
* preauth.c: Add const and casts as needed to handle warnings..Ezra Peisach1996-05-051-7/+7
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7901 dc483132-0cff-0310-8789-dd5450dbe970
* preauth.c: add SAM supportMark Eichin1996-04-091-2/+250
| | | | | | | | | str_conv.c: add AFS3 support init_ctx.c: add processing for default_tkt_enctypes, matching default_tgs_enctypes but client-side (so as not to hard code it, since hard coded values are usually wrong :-) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7773 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c: Ultrix is broken. Prototype obtain_enc_ts_padata()Tom Yu1995-11-271-2/+34
| | | | | | | | and process_pw_salt() explicitly rather than using the typedef in k5-int.h becaus that typedef is to a function pointer now. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7123 dc483132-0cff-0310-8789-dd5450dbe970
* get_in_tkt.c (decrypt_as_reply):Theodore Tso1995-11-181-1/+1
| | | | | | | | | | | preauth.c (process_pw_salt): When fetching the key to decrypting the encrypted kdc reply, use the etype associated with the etype reply, not the etype associated with the included ticket. encode_kdc.c: Remove eblock argument from krb5_encode_kdc_rep; set the eblock type from the client_key's enctype. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7117 dc483132-0cff-0310-8789-dd5450dbe970
* * preauth.c (krb5_process_padata): Added generalized processing forTheodore Tso1995-11-131-46/+84
| | | | | | | | | | | | | | | preauth information which is returned by the KDC. This should be general enough to support the AFS3_SALT preauth type, the SNK4 preauth type, and the public-key mods to Kerberos. (process_pw_salt): New function for processing the KRB5_PW_SALT preauthentication type. * get_in_tkt.c (decrypt_as_reply): Removed temporary kludge for processing the PW_SALT preauth type; that's now done in preauth.c (krb5_get_in_tkt): Call krb5_process_padata with new arguments so that the preauth code can set the decryption_key if necessary. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7102 dc483132-0cff-0310-8789-dd5450dbe970
* * get_in_tkt.c (krb5_get_in_tkt): Remove the etype_info argument fromTheodore Tso1995-11-091-6/+18
| | | | | | | | | | the call to krb5_obtain_padata. * preauth.c (krb5_obtain_padata): Use the PADATA_ETYPE_INFO preauth, if it exists, to determine which salt type to use when encrypting the preauthentication data. Remove the etype_info argument. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7071 dc483132-0cff-0310-8789-dd5450dbe970
* * encrypt_tk.c (cleanup_scratch): Changed interface to no longer requireTheodore Tso1995-11-081-393/+192
| | | | | | | | | | | an eblock; we can use our own and figure out the enctype from the passed-in key. * get_in_tkt.c (krb5_get_in_tkt): Added calls to krb5_obtain_padata(). * preauth.c: Completely restructured file to support preauthentication. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7056 dc483132-0cff-0310-8789-dd5450dbe970
* Reintegrate Macintosh changesEzra Peisach1995-09-121-2/+2
| | | | | | | | t_ser.c: Work around an optimizer bug in gcc under OSF/1 2.1. The timeofday calls were left in the stage as described in the ChangeLog git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6766 dc483132-0cff-0310-8789-dd5450dbe970
* Mac Beta 1 submissionKeith Vetter1995-09-111-2/+2
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6749 dc483132-0cff-0310-8789-dd5450dbe970
* * auth_con.c, decrypt_tk.c, encode_kdc.c, encrypt_tk.c,Chris Provenzano1995-09-061-2/+2
| | | | | | | | | | | * gc_frm_kdc.c, gen_seqnum.c, get_creds.c, get_in_tkt.c, * in_tkt_ktb.c, in_tkt_pwd.c, in_tkt_sky.c, init_ctx.c, * kdc_rep_dc.c, mk_cred.c, mk_priv.c, mk_rep.c, mk_req._ext.c, * preauth.c, rd_cred.c, rd_priv.c, rd_rep.c, rd_req_dec.c, * send_tgs.c, sendauth.c, ser_actx.c, ser_ctx.c, ser_eblk.c, * ser_key.c, t_ser.c : s/keytype/enctype/g, s/KEYTYPE/ENCTYPE/g git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6727 dc483132-0cff-0310-8789-dd5450dbe970
* Clean up gcc -Wall flamesTheodore Tso1995-06-081-3/+3
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5981 dc483132-0cff-0310-8789-dd5450dbe970
* Rearrange #include files so that krb5.h gets included first, so thatTheodore Tso1995-05-231-1/+1
| | | | | | | the debugging information can be more efficiently collapsed since the type numbers will be the same. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5853 dc483132-0cff-0310-8789-dd5450dbe970
* Windows global stuff:Keith Vetter1995-04-141-7/+7
| | | | | | | | | o removed INTERFACE from non-api functions o add FAR to pointers visible to the world o made the tests for __STDC__ also check for _WINDOWS o creates GSSAPI.DLL & GSSAPI.LIB as per spec. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5354 dc483132-0cff-0310-8789-dd5450dbe970
* A few small changes for 16 vs 32 bit, pulling in winsock for network byteKeith Vetter1995-03-021-6/+10
| | | | | | ordering and removed some unused local variables. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5058 dc483132-0cff-0310-8789-dd5450dbe970
* * *.c: Avoid <krb5/...> includes.John Gilmore1995-02-281-5/+1
| | | | | | * parse.c: Exdent #ifndef to left margin for old compilers. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5015 dc483132-0cff-0310-8789-dd5450dbe970
* Converted the krb5/krb directory to work under windows. Mostly added theKeith Vetter1995-02-271-8/+8
| | | | | | windows INTERFACE keyword to functions. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5002 dc483132-0cff-0310-8789-dd5450dbe970
* Removed all references to DECLARG and OLDDECLARG.Chris Provenzano1995-01-131-35/+41
| | | | | | Added krb5_context to all krb5_routines. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4810 dc483132-0cff-0310-8789-dd5450dbe970
* Add magic number placeholder to statically initialized structuresTheodore Tso1994-10-011-0/+2
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4421 dc483132-0cff-0310-8789-dd5450dbe970
* stamp out rcs keywordsMark Eichin1994-08-181-2/+0
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4191 dc483132-0cff-0310-8789-dd5450dbe970
* Changed preauthentication names to match those which Cliff and I agreed uponTheodore Tso1994-08-091-46/+7
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@4078 dc483132-0cff-0310-8789-dd5450dbe970
* Declare statically used procedure (previously and incorrectly defined in .hTheodore Tso1993-12-011-1/+4
| | | | | | files) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@3059 dc483132-0cff-0310-8789-dd5450dbe970
* Change export warning notice from "is assumed to require an export license"Theodore Tso1993-09-011-2/+2
| | | | | | to "may require..." git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@2638 dc483132-0cff-0310-8789-dd5450dbe970
* Merged in sandia's new secuireid codeTheodore Tso1993-02-261-51/+103
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@2514 dc483132-0cff-0310-8789-dd5450dbe970
* *** empty log message ***Theodore Tso1992-09-301-0/+460
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@2449 dc483132-0cff-0310-8789-dd5450dbe970