summaryrefslogtreecommitdiffstats
path: root/src/lib/krb5/os
Commit message (Collapse)AuthorAgeFilesLines
* * locate_kdc.c (make_srv_query_realm): Punt if strdup fails. Always returnKen Raeburn2003-06-052-24/+34
| | | | | | | | | | | | | what data we can, even if memory allocation or other problems prevent us from returning more. (krb5_locate_srv_dns_1): Always return what data we can. Fix memory leak. Free up temporary storage as quickly as possible, while building up address list to return. ticket: 1549 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15574 dc483132-0cff-0310-8789-dd5450dbe970
* Put krb5int_locate_server back in the accessor "export" listKen Raeburn2003-06-042-0/+4
| | | | | | | ticket: 1549 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15561 dc483132-0cff-0310-8789-dd5450dbe970
* Handle SRV RR target of "." by returning a new error code.Ken Raeburn2003-06-042-29/+65
| | | | | | | | | | | | | | | | May have memory leaks -- needs checking before pullup. * locate_kdc.c (struct srv_dns_entry): Move to top level. (make_srv_query_realm): Separate from krb5_locate_srv_dns_1; just do query and return results. (krb5_locate_srv_dns_1): Call it, and build addlist entries. Check for one RR with a target of ".", and return an error. (krb5_locate_srv_dns): Deleted. ticket: 1549 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15560 dc483132-0cff-0310-8789-dd5450dbe970
* * t_locate_kdc.c (main): Call krb5_locate_srv_dns_1Ken Raeburn2003-06-042-1/+3
| | | | | | | ticket: 1549 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15559 dc483132-0cff-0310-8789-dd5450dbe970
* * locate_kdc.c (get_port): Revert last changeKen Raeburn2003-06-042-7/+3
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15558 dc483132-0cff-0310-8789-dd5450dbe970
* * changepw.c (krb5_locate_kpasswd): Check specifically for certain errorsKen Raeburn2003-06-042-1/+4
| | | | | | | | | before using fallback heuristics. ticket: 1549 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15557 dc483132-0cff-0310-8789-dd5450dbe970
* * locate_kdc.c (get_port): Replace function with macroKen Raeburn2003-06-032-3/+9
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15554 dc483132-0cff-0310-8789-dd5450dbe970
* * init_os_ctx.c: Included header to get __KLAllowHomeDirectoryAccess()Alexandra Ellwood2003-06-032-0/+8
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15547 dc483132-0cff-0310-8789-dd5450dbe970
* Rename interface to krb5_524_convert_creds, export it from krb5 library.Ken Raeburn2003-05-282-1/+6
| | | | | | | | | | | | Provide old names as functions for UNIX/MacOS binary compatibility, and deprecated macros for source code compatibility. (For Windows, we'll still need a krb524.dll, and it can worry about providing the old names.) Enable support on Windows always. ticket: 1491 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15513 dc483132-0cff-0310-8789-dd5450dbe970
* Big step towards integrating libkrb524 into libkrb5:Ken Raeburn2003-05-245-6/+140
| | | | | | | | | | | | | | | | | | | | | | | Move libkrb524 code, including error table, into libkrb5. Now libkrb5 initialization pulls in the krb524 error table, so krb524_init_ets is gone; all calls deleted. Move krb4 life/time conversion functions into libkrb5 under new names, using accessor hooks to get at them from libkrb4. Move declarations from krb524.h into krb5.h, k5-int.h, or krb524d.h; the last doesn't get copied into the include directory. Changed inclusions of krb524.h to the appropriate files, if any were needed. Rebuilt dependencies in Makefiles. These changes are likely to break the Windows build; I'll look into that soon. ticket: 1491 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15491 dc483132-0cff-0310-8789-dd5450dbe970
* make-depend updatesKen Raeburn2003-05-241-117/+117
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15490 dc483132-0cff-0310-8789-dd5450dbe970
* * init_os_ctx.c: Added support for KLL's __KLAllowHomeDirectoryAccess() ↵Alexandra Ellwood2003-05-072-1/+12
| | | | | | function so that krb4, krb5 and gssapi will not access the user's homedir if the application forbids it git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15398 dc483132-0cff-0310-8789-dd5450dbe970
* set-change password breaks kpasswdSam Hartman2003-04-282-1/+7
| | | | | | | | | | | | In some cases a null realm argument was passed into the function for locating the kpasswd server. This ended up causing segfaults in kpasswd. Fix to use the right realm. ticket: new Tags: pullup Target_Version: 1.3 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15379 dc483132-0cff-0310-8789-dd5450dbe970
* Incorporate krb5_os_context directly into krb5_context, since they're alwaysKen Raeburn2003-04-282-15/+7
| | | | | | allocated and freed at the same time, even if in different files. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15378 dc483132-0cff-0310-8789-dd5450dbe970
* krb5_setpw_result_string should be internalSam Hartman2003-04-272-1/+6
| | | | | | | | | | | | | Make krb5_setpw_result_string a krb5int_ function prototyped in k5-int.h. The prototype was already there, but the code did not match the function name. This needs to be pulled up to the release branch to fix Windows build because of a KRB5_CALLCONV issue. ticket: new Tags: pullup Target_Version: 1.3 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15375 dc483132-0cff-0310-8789-dd5450dbe970
* Implementation of Microsoft set password client library code providedSam Hartman2003-04-252-15/+113
| | | | | | | | | | by Paul Nelson. Ticket: 1377 Status: open Tags: pullup git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15373 dc483132-0cff-0310-8789-dd5450dbe970
* memory leak in krb5_read_passwordKen Raeburn2003-04-132-6/+8
| | | | | | | | | | | * read_pwd.c (krb5_read_password): Always free temporary storage used for verification version of password. ticket: new target_version: 1.3 tags: pullup git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15348 dc483132-0cff-0310-8789-dd5450dbe970
* * c_ustime.c: Removed Mac OS 9 code. * ccdefname.c: Conditionalize on ↵Alexandra Ellwood2003-03-066-123/+29
| | | | | | USE_CCAPI and not TARGET_OS_MAC so Darwin builds work. * init_os_ctx.c: Modified to use DEFAULT_SECURE_PROFILE_PATH and DEFAULT_PROFILE_PATH for KfM homedir-relative config files. * read_pwd.c: Cast to remove const warnings. * timeofday.c: Do the same thing on the Mac as on Unix git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15259 dc483132-0cff-0310-8789-dd5450dbe970
* Don't call shutdown after finishing writingSam Hartman2003-03-042-1/+6
| | | | | | to TCP socket as doing so causes interop problems. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15220 dc483132-0cff-0310-8789-dd5450dbe970
* * prompter.c (krb5_prompter_posix): Kill echo before printingTom Yu2003-02-082-6/+10
| | | | | | prompt to avoid possible race conditions in test suite. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15170 dc483132-0cff-0310-8789-dd5450dbe970
* * prompter.c (krb5_prompter_posix, setup_tty, restore_tty): Fix toTom Yu2003-02-072-12/+22
| | | | | | | | use the actual file descriptor we dup()'ed to in case tcsetattr() doesn't actually change the underlying device modes and instead only affects the specific file descriptor. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15164 dc483132-0cff-0310-8789-dd5450dbe970
* * locate_kdc.c (translate_ai_error): Handle EAI_ADDRFAMILY like EAI_NONAME.Ken Raeburn2003-02-062-7/+11
| | | | | | | | | | (krb5int_add_host_to_list): Translate errors returned from the second getaddrinfo call. ticket: 1339 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15160 dc483132-0cff-0310-8789-dd5450dbe970
* * prompter.c (krb5_prompter_posix): Rewrite to no longer useTom Yu2003-02-052-87/+166
| | | | | | | | | | | | | longjmp(), as well as to get a non-buffered stdio stream on stdin to avoid passwords staying around in stdio buffers. This does have the side effect of possibly losing pre-buffered input from an application that reads from stdin using stdio functions prior to calling the prompter, but hopefully those are rare. ticket: 673 ticket: 680 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15151 dc483132-0cff-0310-8789-dd5450dbe970
* Use markers in Makefile.in rather than rules in configure.in to indicate whenKen Raeburn2003-01-102-0/+7
| | | | | | | | to use the lib.in and libobj.in makefile fragments. Pushing this per-directory info into Makefile.in will make it a little easier to work on combining configure scripts for multiple directories. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15107 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (state_strings): Now constKen Raeburn2003-01-082-1/+5
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15095 dc483132-0cff-0310-8789-dd5450dbe970
* Fix some KRB5_CALLCONV botches that were causing trouble for Windows buildTom Yu2002-12-078-25/+60
| | | | | | | | | | | | | | Update send_to_kdc() to use various krb5 internals to talk to the krb4 KDC. Add a new internal function to optionally return the local address used to talk to the KDC. Many changes to lib/krb5/os to support this. Fix bug in krb5int_sendto() that prevented correct UDP length from being returned. Update callers of internal locate_* and sendto_* functions. ticket: 1189 status: open git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15038 dc483132-0cff-0310-8789-dd5450dbe970
* * changepw.c: Remove reference to adm_err.hTom Yu2002-11-143-2/+5
| | | | | | Update dependencies as well. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@15001 dc483132-0cff-0310-8789-dd5450dbe970
* * Makefile.in (t_locate_kdc): Use normal CC_LINK rule for linking test programKen Raeburn2002-11-132-2/+7
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14994 dc483132-0cff-0310-8789-dd5450dbe970
* * localaddr.c (print_addr) [TEST]: Don't mix size_t and socklen_t, just assumeKen Raeburn2002-10-282-7/+9
| | | | | | | socklen macro will return a socklen_t value. Cast buffer size to socklen_t in getnameinfo call. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14944 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (service_tcp_fd): If DEBUG defined, ensure thatEzra Peisach2002-10-222-1/+7
| | | | | | initialization of variable not bypassed by goto. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14934 dc483132-0cff-0310-8789-dd5450dbe970
* Thanks, (corrected) patch appliedTom Yu2002-10-153-2/+10
| | | | | | | | | | | | * hst_realm.c (krb5_try_realm_txt_rr): Apply patch from Nalin Dahyabhai to bounds-check return value from res_search(). * locate_kdc.c (krb5_locate_srv_dns_1): Apply patch from Nalin Dahyabhai to bounds-check return value from res_search(). ticket: 1216 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14928 dc483132-0cff-0310-8789-dd5450dbe970
* implement krb5_read_password, des_read_password via krb5_prompter_posixTom Yu2002-10-112-5/+15
| | | | | | | | | | | | | | | | | | This commit fixes one incompatibility introduced when krb5_read_password was reimplemented in terms of krb5_prompter_posix. There is a remaining incompatibility, which is krb5_prompter_posix's appending of the string ": " following a prompt. Callers of krb5_read_password and of des_read_password don't expect this behavior, which results in a double colon prompt, which breaks the libkadm5 test suite. * read_pwd.c (krb5_read_password): Restore name of size_return. Set *size_return after successful call to krb5_prompter_posix, since some callers were actually checking, e.g. kadm5. ticket: new git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14922 dc483132-0cff-0310-8789-dd5450dbe970
* Implement krb5_read_password an des_read_pw_stringSam Hartman2002-10-102-109/+37
| | | | | | | | | in terms of krb5_prompter_posix. Change motivated by the desire for echo foo |kinit -4 bar to work in test scripts, but having one implementation of password read functions on unix is good anyway git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14921 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (krb5int_cm_call_select): Fix last changeKen Raeburn2002-09-272-2/+5
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14902 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (krb5int_cm_call_select): If timeout value has tv_sec==0, treatKen Raeburn2002-09-192-14/+28
| | | | | | | it as meaning "no timeout". (krb5int_debug_fprint): Handle null timeval pointer. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14884 dc483132-0cff-0310-8789-dd5450dbe970
* update dependenciesKen Raeburn2002-09-181-1/+1
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14879 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c: Include cm.h.Ken Raeburn2002-09-182-48/+87
| | | | | | | | | | | | | | | (struct select_state, SSF_READ, SSF_WRITE, SSF_EXCEPTION): Moved to cm.h. (DEBUG): Define. (krb5int_debug_sendto_kdc): Initialize to zero. (default_debug_handler, put, putstr): New functions. (krb5int_sendtokdc_debug_handler): New variable. (krb5int_debug_fprint): Don't write to stderr; instead, pass strings to the debug output handlers above. (struct incoming_krb5_message): Broken out from struct conn_state. (krb5int_cm_call_select): Renamed from call_select; callers updated. Now extern. Display max fd number in debugging call, not nfds. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14875 dc483132-0cff-0310-8789-dd5450dbe970
* Return errno not retval from getpeername failureSam Hartman2002-09-172-1/+6
| | | | | | ticket: 1164 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14871 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (service_fds): Fix bug in last change.Ken Raeburn2002-09-142-30/+36
| | | | | | | | | | (krb5int_debug_fprint): Use 'out' consistently, minimize explicit references to stderr. Flush output before returning. (dperror) [_WIN32]: Shorten message. (start_connection, service_tcp_fd, service_fds, krb5int_sendto): Use dprint instead of dfprintf. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14863 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (struct conn_state): Add new function pointer field 'service'Ken Raeburn2002-09-142-44/+41
| | | | | | | | | | | | | for the fd service routine. (setup_connection): Initialize it. (service_fd): Deleted. (service_fds): Incorporate debug output from service_fd. Call service routine indicated in connection info. Decrement select fd count for each flag set for a file descriptor. Ensure that the index into the conns array doesn't run off the end. (krb5int_debug_fprint): Fetch correct type for %E. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14862 dc483132-0cff-0310-8789-dd5450dbe970
* * t_locate_kdc.c(main):Add new argument -m for looking up master KDC addressesKen Raeburn2002-09-112-2/+8
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14844 dc483132-0cff-0310-8789-dd5450dbe970
* * locate_kdc.c (get_port): Skip service name lookup, just use the suppliedKen Raeburn2002-09-112-8/+44
| | | | | | | | | | numbers. (add_host_to_list): If a second port number is supplied, look up AF_INET addresses only, and only for SOCK_DGRAM type entries. Ignore errors in the second address lookup. (krb5_locate_srv_conf_1) [TEST]: More debugging code. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14843 dc483132-0cff-0310-8789-dd5450dbe970
* whitespaceKen Raeburn2002-09-111-1/+3
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14842 dc483132-0cff-0310-8789-dd5450dbe970
* revert init change to flock_zero in krb5_lock_fileKen Raeburn2002-09-032-2/+1
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14819 dc483132-0cff-0310-8789-dd5450dbe970
* protoizeKen Raeburn2002-09-0346-320/+124
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14816 dc483132-0cff-0310-8789-dd5450dbe970
* * Makefile.in: Revert $(S)=>/ change, for Windows supportKen Raeburn2002-08-292-1/+5
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14786 dc483132-0cff-0310-8789-dd5450dbe970
* Ignore a bunch of files generated by building in the source tree, excludingKen Raeburn2002-08-291-0/+2
| | | | | | | | | those covered by CVSROOT/cvsignore patterns. Static UNIX build only, at the moment, may need updates for other configurations. (Second try; this time, deal with the cases where "cvs add"/"cvs ci" choked on previously deleted versions numbered 5.x.) git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14785 dc483132-0cff-0310-8789-dd5450dbe970
* * sendto_kdc.c (merge_addrlists): Truncate source address list after copyingKen Raeburn2002-08-242-0/+4
| | | | | | its data into the destination list. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14762 dc483132-0cff-0310-8789-dd5450dbe970
* Change $(S)=>/ and $(U)=>.. globallyKen Raeburn2002-08-232-1/+5
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14761 dc483132-0cff-0310-8789-dd5450dbe970
* * locate_kdc.c (krb5_locate_kdc): Don't look up kerberos-sec for TCP serviceKen Raeburn2002-08-232-5/+10
| | | | git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14748 dc483132-0cff-0310-8789-dd5450dbe970