summaryrefslogtreecommitdiffstats
path: root/source/libsmb
Commit message (Collapse)AuthorAgeFilesLines
...
* clientgen.c: Added cli_ulogoff() call.Jeremy Allison1998-04-211-0/+19
| | | | | password.c: Added call to cli_ulogoff on successfull sessionsetup. Jeremy.
* Makefile: Added genrand.oJeremy Allison1998-04-201-1/+6
| | | | | | | | | | | | | | | clientgen.c: Changed to fill change password buffer with random stuff. password.c: Changed to get challenge from genrand.c server.c: Added #ifdef around O_SYNC. version.h: Changed to 1.9.19prealpha. genrand.c: New code to generate (hopefully) good random numbers for use in crypto challenges/session keys etc. PLEASE REVIEW THIS CODE AND SUGGEST IMPROVEMENTS !!!!!! Jeremy.
* clientgen.c: Changes 'cli_xxx_' calls to use the followingJeremy Allison1998-04-171-53/+99
| | | | | | | | | | | | | | | | | | | | | | | | | | | regularized parameter syntax: setup, setup_count, max_setup_count, params, params_count, max_params_count, data, data_count, max_data_count, (and if a reply is needed) *reply_params, *reply_data_len *reply_data, *reply_data_len This allows the pointers and the lengths that relate to these pointers to be next to each other in the parameter list. This makes seeing what you are passing to these functions much easier to see. Getting ready for adding the lib/rpc/client functions needed to do security=domain. torture.c: Fixed it so it uses / rather than \\ internally for the //machine/share syntax. Jeremy.
* Changing of machine passwords now works !!!!!!Jeremy Allison1998-04-171-0/+9
| | | | | | | | smbdes.c: Added cred_hash3. smbpasswd.c: Fixes for adding a machine account (needs more work). lib/rpc/server/srv_netlog.c: Turn on the machine password changing code by default (calls cred_hash3). Jeremy.
* Changes to allow Samba to be compiled with -Wstrict-prototypesJeremy Allison1998-04-131-4/+3
| | | | | | with gcc. (Not a big change although it looks like it :-). Jeremy.
* if the resolve order is blank then assume "host"Andrew Tridgell1998-04-121-0/+2
|
* support O_SYNC in opens for smbtortureAndrew Tridgell1998-04-121-0/+4
|
* chgpasswd.c, ipc.c, loadparm.c: Added boolean "unix password sync"Jeremy Allison1998-03-271-4/+4
| | | | | | | | parameter which allows the new change password code to change the unix password also. Defaults to OFF. includes.h: Added termios.h to FreeBSD to allow password changing. namequery.c: Fixed missing name parameters to debug statements. Jeremy.
* RFC1002 says we must put compressed name pointers in the followingJeremy Allison1998-03-251-2/+40
| | | | | | | | | | | | | outgoing packets : NMB_NAME_REG_OPCODE, NMB_NAME_RELEASE_OPCODE, NMB_NAME_REFRESH_OPCODE, NMB_NAME_MULTIHOMED_REG_OPCODE. A WINS server written by Shadow Software was rejecting our packets as we weren't using name pointers in those requests (talk about picky :-). Jeremy.
* clientgen.c ipc.c smbpasswd.c: Fixes for warnings (from Herb).Jeremy Allison1998-03-241-1/+1
| | | | | | | | | | | quotas.c: Linux quota fix. util.c: Ensure smb_read_error is zero in all calls that can set it. lib/rpc/include/rpc_misc.h lib/rpc/include/rpc_netlogon.h lib/rpc/parse/parse_misc.c lib/rpc/parse/parse_net.c lib/rpc/server/srv_netlog.c : Modify Luke's code to call SamOEMhash(). Jeremy.
* Adding the same changes to HEAD as were added to BRANCH_1_9_18.Jeremy Allison1998-03-192-3/+107
| | | | | | | | | | | | | Changed smbpasswd to be client-server for a normal user, rather than accessing the private/smbpasswd file directly (it still accesses this file directly when run as root, so root can add users/change a users password without knowing the old password). A shakeout of this change is that smbpasswd can now be used to change a users password on a remote NT machine (yep - you heard that one right - we can now change a NT password from UNIX !!!!!). Jeremy.
* Added SamOEMChangePassword functionality.Jeremy Allison1998-03-181-0/+40
| | | | Jeremy.
* Fixes for the static data bugs & incorrect use of strtokJeremy Allison1998-03-171-7/+11
| | | | | that Andrew pointed out. Jeremy.
* Adding the same change as was added to 1.9.18 branch to add theJeremy Allison1998-03-162-7/+266
| | | | | | | | | | | | | | | | | | | | | | | "name resolve order" parameter. source/Makefile: Re-ordered link for name resolve order code. source/clientgen.c: source/clientutil.c: Added calls to resolve_name(). source/includes.h: Added HPUX zombie fix. source/loadparm.c: Added new name resolve order parameter. source/namequery.c: Re-wrote to include parsing of lmhosts file, new resolve_name() function requested by John. source/nmbd.c: Tell resolve_name not to do WINS lookups if we are the WINS server. source/nmbd_lmhosts.c: Call lmhosts parsing functions in namequery.c source/password.c: Call resolve_name() to lookup security=server name. source/reply.c: source/time.c: source/trans2.c: "fake directory create times" fix from Jim Hague - hague@research.canon.com.au. source/util.c: Removed isalnum() test in Get_Hostname() that seems to cause problems on many systems. Jeremy.
* This is *not* a big change (although it looks like one).Jeremy Allison1998-01-227-7/+7
| | | | | | | This is merely updating the Copyright statements from 1997 to 1998. It's a once a year thing :-). NO OTHER CHANGES WERE MADE. Jeremy.
* charcnv.c: Added codepage 866 support onto the file system. PatchJeremy Allison1998-01-171-0/+6
| | | | | | | | | | | | | from Max Khon <max@iclub.nsu.ru>. chgpasswd.c: Allow old RAP change password to work with encrypted passwords. Samba can now allow Windows 95/NT clients to securely change the Lanman password ! (But not the NT hash - that gets lost). ipc.c: smbdes.c: smbpass.c: Support for the above. server.c: #ifdef'ed out fix for NT redirector bug. util.c: Fix NIS bug with server name. Jeremy.
* reply.c:Jeremy Allison1998-01-161-13/+13
| | | | | | | server.c: Test fix for NT worstation SMBmv oplock bug. smbdes.c: Addition of 'forward' parameter in preparation of allowing password change. Jeremy.
* client.c:Jeremy Allison1997-12-201-20/+20
| | | | | | | | | | | | | | | | clientgen.c: clientutil.c: clitar.c: Changed usage of receive_smb to new function client_receive_smb except for one use of receive_smb in client.c. This is the receive_smb used to discard packets received whilst in a keyboard wait state. util.c: Created new function client_receive_smb that ignores session keepalives just as the old receive_smb used to do. Created internal function read_smb_length_return_keepalive that is used internally by the changed receive_smb call. Changed read_smb_len to not use an internal buffer - it is never called with a null buffer so such code is redundant. Jeremy.
* This is it ! The mega-merge of the JRA_NMBD_REWRITE branchJeremy Allison1997-12-132-27/+170
| | | | | | | | back into the main tree. For the cvs logs of all the files starting nmbd_*.c, look in the JRA_NMBD_REWRITE branch. That branch has now been discontinued. Jeremy.
* add the null string to SMBsetatr callsAndrew Tridgell1997-12-021-1/+3
|
* clientgen.c: Added cli_mv() (used in a recent torture test).Jeremy Allison1997-11-301-0/+37
| | | | | | | | | | reply.c: Changed reply_open_and_X to split out the oplock request bits from core and extended and if an oplock was granted only set the corresponding bit on reply. server.c: Added code to dynamically allocate i/o buffers in oplock_break (prevents recursion problems) , also made reset of sent_oplock_break explicit. Jeremy.
* added cli_rmdir and cli_mkdirAndrew Tridgell1997-11-241-1/+65
| | | | | | | added test in smbtorture for the server updating the directory modify time when a file is added to a directory cleanup in smbtorture so no garbage files are left on the server
* added a SMB_QUERY_FILE_ALL_INFO test into smbtortureAndrew Tridgell1997-11-231-0/+56
| | | | W95 doesn't seem to support this call.
* added some QPATHINFO and QFILEINFO tests into smbtorture.Andrew Tridgell1997-11-231-5/+111
| | | | | This tests for things like midnight access times, sticky create times and word reversed INFO_STANDARD returns
* test SMBsetatr as wellAndrew Tridgell1997-11-231-6/+51
|
* added a test for the NT SMBgetatr bug in smbtortureAndrew Tridgell1997-11-231-19/+59
| | | | | | | | added support for choosing the protocol level in smbtorture (-m option) use -1 for null date in cli_close() get the attributes right in cli_open()
* changed nmblookup to only set recursion_desired in queries if the -RAndrew Tridgell1997-11-191-1/+1
| | | | option is used.
* fixed a bug which caused nmbd to core dump. The problem was incorrectAndrew Tridgell1997-11-111-2/+2
| | | | parameters to cli_NetServerEnum()
* Rolled back tree state to 11:59pm 8th November 1997 EST toJeremy Allison1997-11-104-149/+75
| | | | | remove problems. Jeremy
* attempting to mark up 32 bit error codes, needed for NT domains.Luke Leighton1997-11-094-75/+149
| | | | | | | | | | | | separated out smb server-mode password validation into a separate file. added called and calling netbios names to client gen state: referenced section in rfc1002.txt. created workstation trust account checking code in ntclient.c there might be a bug in reply_session_setup_andX. i indented and added { } around single-line if statements: the lm password checking code now doesn't look right (around the GUEST_SESSSETUP bits). *no code semantics have been changed by the indentation process*.
* added two more sets of tests to the smbtorture test. The tests I addedAndrew Tridgell1997-11-081-0/+10
| | | | | | | | | | | | | | | | | are ones that I know Samba fails. They are: 1) correct support for retaining locks over a close (ie. the server must not use posix semantics) 2) support for lock timeouts 3) the server supports multiple locking contexts on the one SMB connection, distinguished by PID. 4) the server correctly fails overlapping locks made by the same PID (this goes against POSIX behaviour, which is why it is tricky to implement) 5) the server denies unlock requests by an incorrect client PID I've been discussing with Jeremy ways that we can re-implement the locking code to handle these correctly. This test code will be useful to see that we have got it right.
* fix some uchar/char conflictsAndrew Tridgell1997-11-021-2/+2
|
* convert the credentials code back to uchar[8] from uint32[2]Andrew Tridgell1997-11-021-43/+41
| | | | This should fix the byte order problems (maybe!)
* a simple SMB torture tester. This will allow us to evaluate lockingAndrew Tridgell1997-11-012-3/+513
| | | | techniques more accurately.
* hooray. hooray some more. hooray a lot. got the client-side working.Luke Leighton1997-10-261-59/+39
| | | | | | | | Q/R LSA_REQ_CHAL; Q/R LSA_AUTH2; Q/R LSA_SAMLOGON; Q/R LSA_SAMLOGOFF. the last (non-essential right now) bit is the LSA_SRV_PWSET. the next stage is to do LSA_OPENPOLICY; add the pipe binds (missing right now); then we can test against an NT Server.
* fix some casting errors in smbencrypt and some multiply-defined errorsAndrew Tridgell1997-10-262-10/+5
| | | | | | in clientutil.c (Luke, you can't just copy a global variable declaration from one file to another, you need to declare one of them extern)
* The browse synchronisation code in nmbsync.c now uses the clientgen.cAndrew Tridgell1997-10-261-0/+73
| | | | | | | | | | | | code, which means we don't have to link with a fake getpass routine and we don't have a whole pile of global variables that really have nothing to do with nmbd and were there to keep the client code happy. The code should function identically to what it did before (hopefully it was correct) The only thing that now uses the horrible clientutil.c code is smbclient.
* Makefile :Luke Leighton1997-10-253-0/+136
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | adding bits for new nt domain code byteorder.h : trying to get macros right, and not to crash on SUNOS5... client.c : added #ifdef NTDOMAIN, and created do_nt_login() function. don't want to have to recompile client.c unless absolutely necessary. credentials.c : moved deal_with_creds() [possibly inappropriately] into credentials.c ipc.c reply.c server.c uid.c : attempting to make (un)become_root() functions calleable from smbclient. this is a little tricky: smbclient might have to be another setuid root program, immediately setuid'ing to non-root, so that we can reset-uid to root to get at the smbpasswd file. or, have a secure pipe mechanism to smbd to grab smbpasswd entries. or the like. smbdes.c smbencrypt.c : created a function to generate lm and nt owf hashes. lsaparse.c ntclient.c smbparse.c : added nt client LSA_AUTH2 code. it works, too! pipenetlog.c pipentlsa.c pipesrvsvc.c : simplification. code-shuffling. getting that damn offset right for the opcode in RPC_HDR. smb.h : changed dcinfo xxx_creds to DOM_CRED structures instead of DOM_CHAL. we might need to store the server times as well. proto.h : the usual.
* nmblib.c :Luke Leighton1997-10-241-0/+1
| | | | | | | | | | adding some debug info pipenetlog.c pipentlsa.c pipesrvsvc.c : using unistrn2 instead of unistr2 in the SAM logon username. wrong offset for command in request (use "reserved" field not cancel_count. AGH i'll get there)
* nterr.c :Luke Leighton1997-10-241-0/+514
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | added a structure that wraps nt errors as strings and enums, so we can do a smb_nt_error() function. Makefile ntclient.c : added ntclient.c, broken out nt domain stuff into a separate file. getting fed up of compile-times and size of client.c. fixed the do_lsa_req_chal() function. made it read the response, and return the challenge credentials received from the server. next stop: do_lsa_auth_2(). client.c : removed nt domain logon functions into a separate file. pipenetlog.c pipentlsa.c pipesrvsvc.c smbparse.c : i'd broken the offsets of the RPC_HDR while trying to sort out the nt client code. fixed it again. added some robustness stuff. util.c : the unistrn2() function was null-terminating the string at one character too many.
* renamed static cli_setup_pkt() to static cli_setup_packet() because itLuke Leighton1997-10-231-7/+7
| | | | clashed with the currently-used cli_setup_pkt() in clientutil.c
* Implemented asynchronous DNS lookups in nmbd.Andrew Tridgell1997-10-221-3/+6
| | | | | | | | | | | | | | | | | | | | | I realised this afternoon just how easy it is to add this, so I thought I'd implement it while the idea was fresh. nmbd forks at startup and uses a pipe to talk to its child. The child does the DNS lookups and the file descriptor of the child is added to the main select loop. While I was doing this I discovered a bug in nmbd that explains why the dns proxy option has been so expensive. The DNS cache entries in the WINS list were never being checked, which means we always did a DNS lookup even if we have done it before and it is in cache. I'm sure this used to work (I tested the DNS cache when I added it) so someone broke it :-( Anyway, the async DNS gets rid of the problem completely. I'll commit just the fix to the DNS cache bug to the 1.9.17 tree. You can disable async DNS by adding -DSYNC_DNS to the compile flags.
* This is a set of generic SMB client routines. I needed this in a hurryAndrew Tridgell1997-10-211-0/+673
| | | | | | to fix the password server code, so I didn't use SMBlib. This code is fairly generic and uses a "struct cli_state" to hold the client state.
* casting cleanupsAndrew Tridgell1997-10-202-12/+12
|
* move calls to smbhash() inside smbdes.c (for legal reasons)Andrew Tridgell1997-10-202-10/+20
|
* pipenetlog.c lsaparse.c smb.h :Luke Leighton1997-10-171-1/+10
| | | | | | SAM logon sorting. too many buffer pointers. added in the missing switch value (value of 3). dealing with the buffer pointers to the user info structure in a slightly different way.
* smb.h smbparse.c pipenetlog.c :Luke Leighton1997-10-151-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | whoops, the SAM Logon structure was wrong. updated this, and cifsntdomain.txt. more debug info in pipenetlog.c. the crash is somewhere around deal_with_credentials(). byteorder.h : put in uint8, uint16 and uint32 typecasts around debug info, because sign extending was resulting in ffffffe8 being displayed instead of e8. credentials.c : some debugging info, because i'm tracking a coredump. without gdb. nothing like making things difficult. reply.c : whoops, missed this (important) bit from paul's code, which tells the NT workstation that the MACHINE$ entry doesn't already exist, and we're going to create a default entry with a password "machine" right now. proto.h: the usual.
* add the port number to a debug statementAndrew Tridgell1997-10-151-2/+2
|
* fixed a stack overflow bug in api_lsa_req_chal()Andrew Tridgell1997-10-151-4/+4
| | | | | | | | | | changed the order of arguments to smbhash() in credentials.c. Luke, when you changed from E1() to smbhash() you didn't notice that the arguments are in a different order. This is why your new code was failing. NT logon still fails, but now gets to SAMLOGON. It shouldn't take much to get it working now.
* credentials, query info reply.Luke Leighton1997-10-141-36/+32
|