1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

12048 Commits

Author SHA1 Message Date
Jeremy Allison
e7e49a6e6a client.c: Made sure myhostname was initialised before substitutions.
status.c: Made sure myhostname was initialised before substitutions.
server.c
trans2.c: Moved OS/2 WPS fix.
Jeremy (jallison@whistle.com)
(This used to be commit 8a12b6a4f0)
1997-09-05 21:32:32 +00:00
Jeremy Allison
ab68ac375e Fix from Frank Varnavas <varnavas@ny.ubs.com>.
We cannot use the same name as the client to
the NT password server, as NT will drop client
connections if the same client name connects
twice. Instead, synthesize a name from our pid.
and the remote machine name.
Jeremy (jallison@whistle.com)
(This used to be commit ebf9487a9a)
1997-09-04 21:23:27 +00:00
Jeremy Allison
f5302af621 Fixed up determination of client type for PROTOCOL_NT1. Uses client
capabilities bits in session_setup_and_X to decide. Made remote_arch
an enum as well as a string, for easier use.
Jeremy (jallison@whistle.com)
(This used to be commit 99080705a2)
1997-09-04 20:26:07 +00:00
Jeremy Allison
82290216ad nameannounce.c
nameresp.c
nameserv.c
nameservreply.c
proto.h : Removed broadcast and recurse parameters in the
queue_netbios_pkt_wins() call - they are not needed as they
should always be 'false' and 'true' respectively.
Also fixed a bug with secure name registration (WINS
server code).
server.c: Finally fixed problem with error 267 being
returned to Win95. It is needed by NT. This is a horrid
fix and I would appreciate a better one :-).

Jeremy (jallison@whistle.com)
(This used to be commit fa1305d189)
1997-09-03 20:15:40 +00:00
Jeremy Allison
e1e4b37ac7 reply.c: Removed unused variables. Caught by gcc -Wall -Werror
server.c: Fix for old DOS clients not understanding ERRbaddirectory - map to ERRbadpath.
util.c: Fix for systems with no LOG_DAEMON facility.
Jeremy (jallison@whistle.com)
(This used to be commit dadb1ffb4c)
1997-09-02 22:21:38 +00:00
Luke Leighton
3fc24dc9ed added word count 3 support into reply_tcon_and_X (see cifs6.txt). the
only thing i couldn't do was get the chaining word count to point to
the end of the smb reply, for the next and_X (not that there is one).
(This used to be commit 54f11999d2)
1997-08-31 14:14:22 +00:00
Andrew Tridgell
f434139087 fixed a bug in the printjob encoding/decoding. We weren't doing it for
the print_ functions in reply.c, with the effect that you couldn't
cancel print jobs from smbclient or from older dos clients.

we now use a couple of utility functions printjob_encode() and
printjob_decode() rather than sticking the bitops inline in each
place.

also fixed a bunch of places that used foo%0xFF rather than foo&0xFF

Note that this isn't really me doing the commit, it can't be as I'm
working on my thesis ...
(This used to be commit 3556763be3)
1997-08-31 02:18:59 +00:00
Jeremy Allison
d95652780a Oops. Reversed mangled map change made in error. Testing
found this one. Jeremy (jallison@whistle.com)
(This used to be commit adf98469fc)
1997-08-28 22:54:41 +00:00
Jeremy Allison
45f9982930 mangle.c: Fixed bug that caused string to run off the end of the mangled map.
server.c: Changed comparison from dname to name2 - seems correct - don't know why
          I changed it originally. hmmmmm.
trans2.c: Made lanman2 code more similar to scan_directory(). I should
          make the trans2 code call scan_dir as they are so similar.
Jeremy(jallison@whistle.com).
(This used to be commit 3909576849)
1997-08-28 18:59:52 +00:00
Samba Release Account
38dc53828e doing that irritating compiler clash warning with the protos for standard_sub
and standard_sub_basic.  again.

lkcl
(This used to be commit b60ef755cf)
1997-08-27 19:27:25 +00:00
Samba Release Account
41bbc5e21f smb.h: Added error code used for OS2 WPS.
trans2.c: Added OS2 WPS fix - but ifdefed out for now. Will turn on
after 1.9.17 release.
Jeremy (jallison@whistle.com)
(This used to be commit 9d5d347686)
1997-08-26 01:28:27 +00:00
Samba Release Account
46dbd8c060 Changes to allow Samba to return the same error code as Windows NT.
Takes care of the cases where a Windows program is parsing a pathname
component by component and expects 2 different errors.
ERRbadpath - if a component in the path doesn't exist.
ERRbaddirectory - if a component in the path exists but is not a directory.
Extra error code added to smb.h to support this.
Code based on suggestions from "Christian Groessler" <chris@fast-ag.de>.

Jeremy (jallison@whistle.com)
(This used to be commit 28b3c6db8a)
1997-08-20 20:32:23 +00:00
Samba Release Account
c76dc7c296 Fix suggested by "Christian Groessler" <chris@fast-ag.de>
dir.c: Cause dptr_create to return -2 when failing on unix error.
reply.c: Use UNIXERROR in more cases.
server.c: Add ENOTDIR mapping to error table.
trans2.c: Correctly determine UNIX error on dptr_create.
Jeremy (jallison@whistle.com)
(This used to be commit de38a0b34f)
1997-08-20 01:22:05 +00:00
Samba Release Account
e9269c67a5 Makefile: Changed for HPUX10 tidyup.
includes.h:	Changed for HPUX10 tidyup.
ipc.c:		Fixed bug where getting local server list from NT browsers would
            fail.
nmbsync.c:	Fixed bug where getting local server list from NT browsers would
            fail.
proto.h:	Changed for crash bug on SCO with USE_MMAP.
quotas.c:	Added OSF quotas (patch from Bret Giddings <bret@essex.ac.uk>).
            Rolled back solaris uid change - I think it was wrong.
reply.c:	Changed for crash bug on SCO with USE_MMAP.
server.c:	Removed Lukes changes. Changed for crash bug on SCO with USE_MMAP.
smb.h:		Changed for crash bug on SCO with USE_MMAP.
smbpasswd.c:Fixed crash bug with Lukes changes.
uid.c:		Removed Lukes changes.
util.c:		Fixed I18N bug with extended char filenames and widelinks = no.
Jeremy (jallison@whistle.com)
(This used to be commit bf1c79f7fd)
1997-08-19 19:22:26 +00:00
Samba Release Account
ea4c7557dd connecting to IPC$ goes under the guest account. the IPC$ share should
be treated no differently than any other share (for any security setting:
user, server or share).

this will clear up a bug where, when clients connect to the IPC$ share, this
used to be done under the guest account.  the standard_sub_basic() macros
will substitute the _guest_ account for %U, causing the samba server to
look different from when the client then connects to any other share.

lkcl
(This used to be commit 3852656960)
1997-08-17 21:03:12 +00:00
Samba Release Account
b65fdef1ba includes.h: Fixed S_IFLNK for old DEC ultrix.
ipc.c:	Finally :-) fixed responses to NetServerEnum2 when SV_TYPE_ALL
        given.
Jeremy (jallison@whistle.com)
(This used to be commit 1dc37c8350)
1997-08-13 20:16:32 +00:00
Samba Release Account
9170cfd4b6 spelling.
lkcl
(This used to be commit 7e326450cf)
1997-08-11 18:06:44 +00:00
Samba Release Account
b5114b41f5 Makefile: Added IRIX 6 target.
loadparm.c: Fixed stupid static warnings with set_default_server_announce_type.
password.c:	Fixed char -> uchar cast warnings.
nameservreply.c: Fixed group fade out code.
Jeremy (jallison@whistle.com)
(This used to be commit a2dd5c5a55)
1997-08-05 01:31:55 +00:00
Samba Release Account
75bbf35a86 client.c: Minor change to cast parameters for DEC unix.
clientutil.c:	Minor change to cast parameters for DEC unix.
ipc.c:		Fixes to parameterise the stuff John wants.
loadparm.c:	Fixes to parameterise the stuff John wants.
nameannounce.c: Fixes to parameterise the stuff John wants.
namedbwork.c: Fixes to parameterise the stuff John wants.
nameserv.h:	Fixes to parameterise the stuff John wants.
proto.h: Fixes to parameterise the stuff John wants.
smb.h: Fixes to parameterise the stuff John wants.
util.c: tidy.
Jeremy (jallison@whistle.com)
(This used to be commit 9fbca2594b)
1997-07-30 19:17:51 +00:00
Samba Release Account
7314126d9e client.c: Added amanda fixes.
clitar.c:	Added amanda fixes.
nameannounce.c:	Removed redundent code.
nameelect.c:	Removed redundent code.
nameserv.h:		Removed redundent code.
nameservresp.c:	Removed redundent code.
namework.c:		Removed redundent code.
password.c:		Prevented crash if getpwnam fails.
Jeremy (jallison@whistle.com)
(This used to be commit 760fe30353)
1997-07-28 18:59:57 +00:00
Samba Release Account
834518eddd loadparm.c: Changed default create mask to 755 to support MAP_ARCHIVE.
server.c:	Added check for MAP_ARCHIVE before we set archive bit.
Jeremy (jallison@whistle.com)
(This used to be commit d21a166277)
1997-07-24 22:42:16 +00:00
Samba Release Account
15ae50ca52 Makefile: Added UNIXWARE 2.x with shadow passwords from fja@extratech.com
client.c:	Made prompt appear at debug level 0. Fixed strcasecmp redefinition.
            Caused client to use set_blocking rather than making fcntl calls itself.
dir.c:		Removed redundent snum parameters.
includes.h:	Added SCO fixes.
loadparm.c:	Made default 'files to hide' a null string.
nmbd.c:		Removed O_NONBLOCK from pid file open for platforms that dont have it.
proto.h:	Changed snum to cnum where needed. Changed is_xx_path to is_in_path
            (now called via MACRO).
quotas.c:	Swapped setuid/seteuid calls when restoring uid.
reply.c:	Removed redundent snum parameters.
server.c:	Changed snum to cnum where needed. Setup new veto_list, hide_list
            namelists. Added standard_sub changes from
            Stefaan A Eeckels <Stefaan.Eeckels@ecc.lu> and
            Paul Rippin <pr3245@nopc.eurostat.cec.be>
shmem.c:	Changed cast for sizeof to be int before negating.
smb.h:		Added new veto_list, hide_list entries to connections.
            Added IS_PRINT, IS_HIDDEN_PATH, IS_VETO_PATH macros.
trans2.c:	Removed redundent snum parameters.
util.c:		Added standard_sub_basic changes from
            Stefaan A Eeckels <Stefaan.Eeckels@ecc.lu> and
            Paul Rippin <pr3245@nopc.eurostat.cec.be>
            Fixed up veto/hidden path processing so the paths are
            pres-parsed and checked for wildcards (for speed).
Jeremy (jallison@whistle.com)
(This used to be commit 9afa36f787)
1997-07-24 17:25:11 +00:00
Samba Release Account
a3de6a813e charset.c: Fixed signed/unsigned issues.
password.c:	Fixed problem with MS-Exchange services.
Jeremy (jallison@whistle.com)
(This used to be commit e723dd3dee)
1997-07-22 19:04:40 +00:00
Samba Release Account
0cdc68332d Removed lp_killunused() call from server main loop. This
WAS A MAJOR BUG THAT CAN CAUSE IPC$ to be removed !!!!!
Not sure how this one got introduced (but I have my
suspicions :-). lp_killunused() MUST ONLY BE CALLED from
reload_services().
Jeremy (jallison@whistle.com)
(This used to be commit 937f0fbf87)
1997-07-22 18:35:44 +00:00
Samba Release Account
612111c7a1 charset.c: Split charset_initialise() into 2 - a charset_initialise() and
a codepage_initialise(). Fixes problem with initialising dos map
            twice.
charset.h:  Changes to support charset changes.
client.c:   Changes to support charset changes.
loadparm.c:	follow symlinks parameter from David Clerc <David.Clerc@cui.unige.ch>
nmbd.c:		Changes to support charset changes.
nmblookup.c:Changes to support charset changes.
proto.h:	Changes to support charset changes.
reply.c:	Don't call security=server with no user/no password guest. Fix from
            Stefaan A Eeckels <Stefaan.Eeckels@ecc.lu>
server.c:   follow symlinks code from David Clerc <David.Clerc@cui.unige.ch>
smbpasswd.c:Changes to support charset changes.
status.c:	Changes to support charset changes.
testparm.c: Changes to support charset changes.
testprns.c: Changes to support charset changes.
uid.c:		Fixed log message with no \n.
Jeremy (jallison@whistle.com)
(This used to be commit 2a28a6e5e4)
1997-07-18 20:21:32 +00:00
Samba Release Account
8b904f4ecc Makefile: Added krb5 option from Nathan Neulinger <nneul@umr.edu>
includes.h:	Added krb5 option from Nathan Neulinger  <nneul@umr.edu>, added SGI5 fix.
password.c: Added krb5 option from Nathan Neulinger  <nneul@umr.edu>
quotas.c: Added inode quote fix.
reply.c: removed redundent code.
server.c: Changed error debug to 0, removed redundent check.
util.c: Added close_low_fd() to become_daemon - fix for rsh from Johnathan Knight.
Jeremy (jallison@whistle.com)
(This used to be commit 256afb7648)
1997-07-17 20:11:58 +00:00
Samba Release Account
0776dea81f local.h: Removed ununsed SHARE_MODES_XXX defines. Upped SMBD_RELOAD_CHECK
from 10 to 60.
server.c:	Removed unused code (was If 0'ed out).
trans2.c:	Backed out Luke's ctime->mtime change. I don't think it
            is correct. Left the other fixes, though.
util.c:		Changed veto/hide files separator back to '/'.
Jeremy (jallison@whistle.com)
(This used to be commit b47121624c)
1997-07-14 19:45:34 +00:00
Samba Release Account
136732a6f4 counter loop % usage only worked if counters were an exact multiple of
SMBD_LOOP time.  used >= instead.

lkcl
(This used to be commit c881dff3bf)
1997-07-13 14:05:01 +00:00
Samba Release Account
9a8c54f51b trans2 query file/path info - unix change times being reported as dos create
times.  now reports unix modified times as dos create times: the alternative
is to report zero (unknown create time).

w95 reports the info level 0x101 (smb query file basic) as data size 40 bytes
not 36.  put 40 bytes data instead.

put in comments into trans2 set file/path info, showing which is the create
time, which is the mod time.

lkcl
(This used to be commit ff455e4059)
1997-07-12 14:41:26 +00:00
Samba Release Account
792771ecc9 interface.c: Fix for AIX4.x finding interfaces.
server.c:		Subtle fix for filenames containing ':'.
Jeremy (jallison@whistle.com)
(This used to be commit ee9f57bab2)
1997-07-11 00:54:45 +00:00
John Terpstra
cec799512d JHT ==> Added copyright notations for my works. This is regretably needed!
(This used to be commit c80111cdf5)
1997-07-09 11:04:45 +00:00
Samba Release Account
25eae02948 Makefile: Added AIX targets from Ole Holm Nielsen <Ole.H.Nielsen@uni-c.dk>
chgpasswd.c:	Added Samba/GPL notice (for obvious reasons).
clitar.c:		Updated Copyright date to include 1997 (for obvious reasons).
getsmbpass.c:	Updated Copyright date to include 1997 (for obvious reasons).
includes.h:		Added stropts for solaris.
loadparm.c:		Changed comment for hide files option.
nameconf.c:		Updated Copyright date to include 1997 (for obvious reasons).
nmbd.c:			Updated Copyright date to include 1997 (for obvious reasons).
pcap.c:			Updated Copyright date to include 1997 (for obvious reasons).
proto.h:		Re-added accidentaly deleted smb_shm_ calls.
quotas.c:		Added AIX quota patch from Ole Holm Nielsen <ohnielse@fysik.dtu.dk>
server.c:		Optimization on calling is_hidden_path. Updated Copyrights.
smb.h:			Changed DEFAULT_FILES_TO_HIDE from  "*/.*" to ".*".
smbpass.c:		Updated Copyright date to include 1997 (for obvious reasons).
ufc.c:			Updated Copyright date to include 1997 (for obvious reasons).
util.c:			Added last component code to is_in_path().
Jeremy (jallison@whistle.com)
(This used to be commit 9385ae1005)
1997-07-08 16:54:44 +00:00
Samba Release Account
bc4d8cb306 missed one OpenDir() and two is_vetoed_name() calls, both of which take
a service number as a parameter, in the rmdir code, when doing a recompile.

lkcl
(This used to be commit e095e339e6)
1997-07-06 14:07:00 +00:00
Samba Release Account
1fe89d0b71 added, tested and debugged new "hide files" option.
lkcl
(This used to be commit 60af320a43)
1997-07-06 13:48:10 +00:00
Samba Release Account
f6384eca67 Fix for deleting directories that contain only veto files.
Needed for interoperability with netatalk volumes.
Jeremy (jallison@whistle.com)
(This used to be commit e72a8513bc)
1997-07-03 19:44:06 +00:00
Samba Release Account
fc3901122d Fixes for UnixWare 2.x with shadow passwords from
Warren Young <tkennedy@cyberport.com>.
(This used to be commit 885b42b447)
1997-07-03 17:19:46 +00:00
Samba Release Account
594f8a4361 Fixed compile warnings for FreeBsd & Linux.
Jeremy (jallison@whistle.com).
(This used to be commit 93352e1aae)
1997-07-02 01:19:41 +00:00
Samba Release Account
1599e41ec4 Rolled back Lukes changes. Not quite ready for prime time.
Jeremy (jallison@whistle.com)
(This used to be commit ed04ec7ab8)
1997-07-01 20:50:57 +00:00
Samba Release Account
ce9baa3bac made "hide files" and "veto files" into per-service parameter sections,
instead of just [global].  this makes it easier to decide whether to
remove the "hide dot files" per-service parameter, and supercede it with
a default "hide files" value of ".*".

lkcl
(This used to be commit f3ee4620ea)
1997-07-01 19:42:42 +00:00
Samba Release Account
738d29667f added "hide files" option.
lkcl
(This used to be commit 6e594ce0e5)
1997-07-01 19:02:43 +00:00
Samba Release Account
fb1429c197 client.c: New print queue query code from Jeff C. Foster " <jfoste@wgc.woodward.com>
ipc.c:			Added code for returning restricted lists of servers.
loadparm.c:		Changed default for force create mode to 000.
				Changed default maxmux to 50 to comply with NT.
locking.c:		Fixed silly crash bug with slow share mode code.
nameannounce.c:	Added code for returning restricted lists of servers.
namedbserver.c:	Added code for returning restricted lists of servers.
nameelect.c:	Added code for returning restricted lists of servers.
namework.c:		Added code for returning restricted lists of servers.
nmbsync.c:		Added code for returning restricted lists of servers.
server.c:		Added quota fix Albrecht Gebhardt <albrecht.gebhardt@uni-klu.ac.at>
smb.h:			Added define for COPYBUF_SIZE.
system.c:		Rename across filesystems Patch from Warren Birnbaum
				<warrenb@hpcvscdp.cv.hp.com>
util.c:			Minor fix for warning.
(This used to be commit 1c6e433caa)
1997-07-01 01:19:13 +00:00
Samba Release Account
9e37076f2b shmem.c: Changed debug to higher level
uid.c:		Stop smbrun from deleting device files.
util.c:		Added EAGAIN to known error list.
Jeremy (jallison@whistle.com)
(This used to be commit c07db8d8e7)
1997-06-27 00:26:59 +00:00
Samba Release Account
434d26acfe loadparm.c: Added "force create mode" and "force directory mode" params.
proto.h:	Added lp_force_create_mode()and lp_force_dir_mode().
server.c:	Fixed application of mode bits to be regular across files
		and directories.
smb.h:		Removed unused CREATE_MODE macro.
Jeremy (jallison@whistle.com)
(This used to be commit 2c92821250)
1997-06-19 00:18:23 +00:00
Samba Release Account
16c87e9198 Fixed *really* stupid bug in register_vuid - only a problem
on multi-user NT systems.
Jeremy (jallison@whistle.com)
(This used to be commit 6ca5c8ca32)
1997-06-18 01:04:57 +00:00
Samba Release Account
2a33e58d18 charset.c: Dropped debug message to level 6.
loadparm.c:	Added "time server" parameter.
nameserv.h:	Added "time server" parameter.
proto.h:	Added lp_time_server().
server.c:	Removed incorrect | 0700 - this was a whistle specific change.
Jeremy (jallison@whistle.com).
(This used to be commit 54dcca1240)
1997-06-16 20:49:15 +00:00
Samba Release Account
c6e63aa896 Makefile: Added quoata changes for Linux from Thorvald Natvig
Makefile.RPM:	Added quoata changes for Linux from Thorvald Natvig
charset.c:	Large changes to add multiple client code pages.
charset.h:	Changed charset_initialise() proto.
client.c:	Fixed message sending bug. Changed charset_initialise().
ipc.c:		Fixed #ifdef compile problems.
loadparm.c:	Added "client code page" option.
nmbd.c:		Changed charset_initialise(). Fixed lmhosts read.
nmblookup.c:	Changed charset_initialise().
proto.h:	Added lp_client_code_page(void).
quotas.c:	Added quoata changes for Linux from Thorvald Natvig
reply.c:	Changed debug level. Made SMBecho ignore tid.
server.c:	Changed charset_initialise().
smb.h:		Added DEFAULT_CLIENT_CODE_PAGE as 850.
smbpasswd.c:	Changed charset_initialise().
status.c:	Changed charset_initialise().
testparm.c:	Changed charset_initialise().
testprns.c:	Changed charset_initialise().
Jeremy Allison (jallison@whistle.com)
(This used to be commit 957025bace)
1997-06-11 01:03:06 +00:00
Samba Release Account
548196362b loadparm.c: Made explicit max packet now ignored.
namedbwork.c:	Don't announce potential browser if local master = False.
nameelect.c:	Raise debug level of comment to 2.
proto.h:	Added reset_globals_after_fork().
server.c:	Call reset_globals_after_fork() after forking child.
util.c:		Added reset_globals_after_fork() - should stop problems
                with % substitutions in children.
(This used to be commit 77be0f710c)
1997-06-06 16:14:17 +00:00
Samba Release Account
3ab97ebe6d charcnv.c: Fixed silly bugs detected on IRIX.
client.c:	Fixed silly bugs detected on IRIX.
namedbname.c:	Stopped 1d names from being registered in WINS db.
namedbsubnet.c:	Only register 1e names on broadcast subnet.
nameelect.c:	Changed add_my_name entries. Forced host announces if we
                have less than 10 servers listed. Fixed registering 1b
                domain name issues.
namepacket.c:	Added error message when dgram discarded.
nameserv.c:	Added notion of 'direct' names that are not registered on
                the network. Needed to get around bugs in earlier nmbd
                handling of DOMAIN(1b) names.
nameservreply.c:Tidied up debug message.
nameservresp.c:	Added response_name_query_domain() code. Deals with
                re-registering DOMAIN(1b) name.
nmbd.c:		Fixed silly bugs detected on IRIX.
nmblib.c:	Added paranoia debugs.
proto.h:	Updated remove_name_entry(), add_my_name_entry().
server.c:	Fixed silly bugs detected on IRIX.
trans2.c:	Fixed silly bugs detected on IRIX.
uid.c:		Fixed silly bugs detected on IRIX.
version.h:	Updated to alpha3.
Jeremy (jallison@whistle.com).
(This used to be commit f08222bd8b)
1997-05-30 20:40:48 +00:00
Samba Release Account
ccf4314fe7 loadparm.c: Ensure printer services cannot be read only and don't use share mode locking.
locking.c:	Changed aborts to returns so not so drastic on PANIC errors.
proto.h:	Removed definition of open_file as this is now never externally called.
reply.c:	Changed reply_mknew, reply_ctemp, reply_printopen to go through open_file_shared.
server.c:	Modified open_file_shared to be more robust and be useful for printer & temp files.
		Removed truncate option from open_file (now all truncates are done in open_file_shared).
util.c:		Added EAGAIN to errors checked in open_socket_out().
version.h:	Updated to 1.9.17alpha2.
jallison@whistle.com
(This used to be commit d8471909b7)
1997-05-27 20:28:45 +00:00
Samba Release Account
71e5f97555 Added fix from Paul Nelson @ Thursby - smb_mid field could be
corrupted if security = server.
jallison@whistle.com
(This used to be commit 52da1897ce)
1997-05-21 01:09:51 +00:00
Samba Release Account
aa864415c5 dir.c: Fixed double slash issue.
includes.h: Changed to ifdef FAST_SHARE_MODES.
ipc.c:  Changed lp_workgroup() to myworkgroup.
loadparm.c:  Added new shared mem parameters. Added Luke's fix.
locking.c: Rewrite to do share modes better (both fast and slow modes).
nameannounce.c:  Changed lp_workgroup() to myworkgroup. Added Luke's fix.
nameconf.c:  Changed lp_workgroup() to myworkgroup.
namedbname.c:  Improved debug.
namedbserver.c:  Changed lp_workgroup() to myworkgroup.
namedbsubnet.c:  Added Luke's fix - rewritten somewhat.
namedbwork.c:  Changed lp_workgroup() to myworkgroup.
nameelect.c:  Added Luke's fix - rewritten somewhat.
nameresp.c:  Stoped shadowing global.
nameserv.c:  Added Luke's fix - Improved debug.
nameservreply.c:  Improved debug.
namework.c:  Changed lp_workgroup() to myworkgroup.
nmbd.c:  Added Luke's fix - Changed lp_workgroup() to myworkgroup.
pipes.c:   Changed lp_workgroup() to myworkgroup.
proto.h:   Added Luke's fix, added smb_shm_ proto's.
reply.c:  Changed lp_workgroup() to myworkgroup.
server.c:  Rewrite to do share modes better (both fast and slow modes).
shmem.c:  Rewrite to do share modes better (both fast and slow modes).
smb.h:  Rewrite to do share modes better (both fast and slow modes).
status.c:  Rewrite to do share modes better (both fast and slow modes).
trans2.c:  Fixed double slash issue.
util.c:  Tidied up, created myworkgroup.
Jeremy Allison (jallison@whistle.com).
(This used to be commit 2a1711eaaf)
1997-05-20 00:32:51 +00:00
Samba Release Account
0f1f0ceb95 'The mother of all checkins' :-). Jeremy Allison (jallison@whistle.com)
Wed May  7 1997: Update for 1.9.17alpha1 release - 'browsefix release'
designed to make browsing across subnets work.

byteorder.h:	Updated copyright to 1997.
charcnv.c:      Updated copyright to 1997.
charset.c 	Updated copyright to 1997.
charset.h	Updated copyright to 1997.
client.c	Updated copyright to 1997.
clientutil.c	Updated copyright to 1997.
dir.c		Updated copyright to 1997.
fault.c		Updated copyright to 1997.
includes.h	Updated copyright to 1997.
interface.c	Updated copyright to 1997.
ipc.c		Updated copyright to 1997.
kanji.c		Updated copyright to 1997.
kanji.h		Updated copyright to 1997.
loadparm.c	Updated copyright to 1997.
locking.c	Updated copyright to 1997.
mangle.c	Updated copyright to 1997.
message.c	Updated copyright to 1997.
nameannounce.c

	Made use of WINS subnet explicit.
Added reset_announce_timer() so announcement
can be made immediately when we become a master.
Expanded code to do sync with dmb.

namebrowse.c

	Removed redundent checks for AM_MASTER in
sync code. Made use of WINS subnet explicit.

namedbname.c	Made use of WINS subnet explicit.
namedbresp.c	Made use of WINS subnet explicit.
namedbserver.c	Made use of WINS subnet explicit.

namedbsubnet.c

	Explicitly add workgroup to WINS subnet
when we become a dmb. Made use of WINS subnet explicit.

namedbwork.c

	Made use of WINS subnet explicit. Removed
redundent check_work_servertype() function.

nameelect.c

	Explicitly add workgroup to WINS subnet
when we become a master browser. Made use of WINS subnet explicit.

namelogon.c	Updated copyright to 1997.
namepacket.c	Updated copyright to 1997.
namequery.c	Updated copyright to 1997.

nameresp.c

	Made use of WINS subnet explicit. Made nmbd fail if
configured as master browser and one exists already.

nameserv.c

	Made use of WINS subnet explicit. Remove redundent
logon server and domain master code.

nameserv.h	Add emumerate subnet macros.
nameservreply.c	Made use of WINS subnet explicit.
nameservresp.c	Updated copyright to 1997.

namework.c

	Made use of WINS subnet explicit. Updated code to
add sync browser entries to add subnet parameter.

nmbd.c

	Added sanity check for misconfigured nmbd.

nmblib.c	Updated copyright to 1997.
nmblookup.c	Updated copyright to 1997.
nmbsync.c

	Removed redundent AM_ANY_MASTER check.

params.c	Updated copyright to 1997.
password.c	Updated copyright to 1997.
pipes.c		Updated copyright to 1997.
predict.c	Updated copyright to 1997.
printing.c	Updated copyright to 1997.

proto.h

	Changed protos for new nmbd code.

quotas.c	Updated copyright to 1997.
replace.c	Updated copyright to 1997.
reply.c		Updated copyright to 1997.
server.c	Updated copyright to 1997.
shmem.c		Updated copyright to 1997.
smb.h		Updated copyright to 1997.
smbencrypt.c	Updated copyright to 1997.
smbpasswd.c	Updated copyright to 1997.
smbrun.c	Updated copyright to 1997.
status.c	Updated copyright to 1997.
system.c	Updated copyright to 1997.
testparm.c	Updated copyright to 1997.
testprns.c	Updated copyright to 1997.
time.c		Updated copyright to 1997.
trans2.c	Updated copyright to 1997.
trans2.h	Updated copyright to 1997.
uid.c		Updated copyright to 1997.
username.c	Updated copyright to 1997.
util.c		Updated copyright to 1997.
version.h

	Changed to 1.9.17alpha1.
(This used to be commit cf23a155a1)
1997-05-08 01:14:17 +00:00
Samba Release Account
121c81e3d6 added automount home directory support. contributed by simeon@bangor.co.uk
and a mini bug-fix by rob.nacarrato@sheridanc.on.ca

reads in an entry from the auto.home file for the user when they log in,
and mounts their home directory as the default path for the [homes] service.

i might add this as to the %substitution system, so that you can
specify subdirectories for the user profiles, mainly.

lkcl
(This used to be commit 0bb6acc358)
1997-05-07 17:56:46 +00:00
Samba Release Account
aaba4712c8 JHT ===> Moved MAJOR_VERSION and MINOR_VERSION defines to smb.h
Made version info consistent in ipc.c and nameannounce.c
	Added define for BROWSER_ELECTION_VALUE and BROWSER_CONSTANT
	(see do_announce_host() in nameannounce.c).

	Sniffing with the latest bloodhound I found that the byte range
	occupied by the BROWSER_ELECTION_VALUE is interpreted depending
	on the type of announcement being made.

	In a Local_Master_Announcement it is BROWSER_ELECTION_VALUE
	but in both Workgroup_Announcement and Host_Announcement
	this is seen as Comment_String_Pointer. What does this mean?
	We need to know?
(This used to be commit 86b0018cc7)
1997-03-15 14:47:00 +00:00
Samba Release Account
b581d03240 1) updated ipc.c NetUserGetInfo - load \\%L\%U instead of \\%L\HOMES
because the share must be browseable by a w95 client

2) send_mailslot_reply - unique or group datagram argument added.

3) netlogon.c - rewrote response packet to do the right thing for w95.

4) server.c reply_nt1() - added OEMDomainstring to the end.

5) (deep breath) reworked the nmbd-browsing code a little bit.
   i discovered two months ago that becoming a primary domain controller
   (and domain master browser) is done independently of becoming a
   backup domain controller (logon server) is done independently of
   becoming a local master browser.

   therefore, three sets of state-machines (instead of just one) are in
   place - each of which is responsible for taking samba through the
   required stages to become:  a logon server; a domain master browser;
   and a local master browser.

   each of these three things can occur independently on each interface,
   _including_ the wins pseudo-interface.  the only slight caveat is that
   the wins pseudo-interface, by virtue of _not_ being a broadcast
   interface, does _not_ register as a local master browser with the wins
   server, as this doesn't make sense.

lkcl
(This used to be commit 88c6a00c3c)
1997-03-09 14:58:22 +00:00
Samba Release Account
3e2f9c3dee quotas.c: Fixed typo in #ifdef'ed compile.
ufc.c: Added pre-declaration of _ufc_doit().
jra@cygnus.com
(This used to be commit 7c690e020f)
1997-03-07 17:24:22 +00:00
Samba Release Account
da0a56a278 Split maxxmit parameter into two : max_send (auto configured by the
connecting client, as per CIFS4) and max_recv, which can be configured
as the old maxxmit was. Fixes problems with NT directory listings when
maxxmit is set very small.
jra@cygnus.com
(This used to be commit c2d5d1040a)
1997-02-28 20:39:36 +00:00
Samba Release Account
df42b0a7bc Makefile: Added cleandir target.
chgpasswd.c: Added patch from Roland Haag <haag@think.de> to allow
             password changes to be done more than once.
loadparm.c: Added entries for the "directory mode/directory mask parameters".
            Changed default file mode to 644.
proto.h: Added sys_gethostbyname.
server.c: Added directory mode changes.
system.c: Added sys_gethostbyname.
trans2.c: Added NT_FILE_ATTRIBUTE_NORMAL patch from Roger Orr
          <rorr@csfp.csfb.com>
trans2.h: Defined NT_FILE_ATTRIBUTE_NORMAL for above patch.
util.c: Changes calls to gethostbyname to sys_gethostbyname.
jra@cygnus.com
(This used to be commit d8d8a7ee00)
1997-02-23 05:18:09 +00:00
Samba Release Account
e9a4f896bd Fixed problem with renaming folder on top level share.
jra@cygnus.com
(This used to be commit 7ba1cff934)
1997-02-18 17:20:14 +00:00
Samba Release Account
8bd0dbb1af Replaced YOST code with more functionally equivalent code that
changes a bit less. Also added fix to tricky reply_mv case.
jra@cygnus.com
(This used to be commit f22ac13b14)
1997-02-11 22:53:29 +00:00
Samba Release Account
c6311f4e0a Removed YOST code. Removal of leading ./ chars should
be done in unix_clean_name in util.c
jra@cygnus.com
(This used to be commit f9f1085c7d)
1997-02-10 19:27:27 +00:00
Samba Release Account
8839603f03 JHT ===> William Yost patches integrated to fix leading path on 8.3
filename problem.
	Problem conditions:
		case sensitive = no
		default case = lower
		mangle case = yes
		preserve case = yes
		short preserve case = yes
	Problem: Win95 still writes upper case file names.
	Patches supplied have been incorporated into mangle.c and server.c
	but needs YOSTW to be defined for it to take effect.

	Action:
	=======
	If we are happy with the patch, delete old code in mangle.c, then
	remove all YOSTW #ifdefs.
(This used to be commit 84fc674c89)
1997-02-10 13:54:29 +00:00
Samba Release Account
cc55a88ddc JHT ===> Fixed potential PAM Security hole and second chance syndrome
spurious warning message "Warning - no crypt available"
(This used to be commit dc559428b8)
1997-02-04 10:35:38 +00:00
Samba Release Account
1fe69a7dd9 Fixed my stupid typo in earlier fix.
jra@cygnus.com
(This used to be commit e9a8ccb36b)
1997-02-04 01:21:52 +00:00
Samba Release Account
f24c04fc77 Fixed up problems with CDROM filesystems (return EROFS) and
also compile issue with USE_MMAP code.
jra@cygnus.com
(This used to be commit 8e9fe58991)
1997-02-03 19:48:56 +00:00
Samba Release Account
30ae26ba42 Fixed bug with NT and large directories.
jra@cygnus.com
(This used to be commit f0aa5e3ff0)
1997-02-03 19:40:15 +00:00
Samba Release Account
98bf10bc5d util.c: StrCaseCmp and StrnCaseCmp terminated incorrectly, giving false
answers when a string was partially identical.  this issue is still
outstanding, and needs to be investigated further.

loadparm.c: added lp_logon_path() parameter.
ipc.c: in NetUserGetInfo, lp_logon_path() can be returned instead of always
specifying \\SAMBA_SERVER\HOMES (which may not necessarily exist).
it is now possible to specify lp_logon_path() as \\ARBITRARY_SERVER\%U,
just like NT server can.  the default is \\SAMBA_SERVER\HOMES, just like
it used to be.

lkcl
(This used to be commit d5b6ad7cb8)
1997-02-02 18:12:36 +00:00
Samba Release Account
2831c62774 line 1960 - call to atexit - address of higher order function killkids
not needed (address already specified).

lkcl
(This used to be commit c5ab2eb71a)
1997-02-02 16:03:51 +00:00
Samba Release Account
691632e555 Added fix for file descriptor re-use failing when
file_exists is false.
Jeremy (jra@cygnus.com).
(This used to be commit b587f18247)
1997-01-23 19:39:57 +00:00
Samba Release Account
869f24e0b1 locking.c proto.h shmem.c smb.h status.c :
Changed shm_ prefixes to smb_shm_ prefixes as shm_ is a POSIX.4
prefix. Updated fd code in FAST_SHARE_MODE code
to work with new fd indirection.
quotas.c: Fixed #ifdef not on position zero.
Jeremy. (jra@cygnus.com).
(This used to be commit c9a9d56642)
1997-01-15 01:53:25 +00:00
Samba Release Account
586c6276ec Added an extra parameter for unix_convert. If present this is the
last component of the modified pathname before modification. This
is needed due to an exceptional condition in reply_mv when the
filesystem is case preserving, but not case sensitive and the
user wants to change the case of a filename. Code for this is
also added to reply.c
Jeremy (jra@cygnus.com).
(This used to be commit cdafa35f9d)
1997-01-13 19:41:08 +00:00
Samba Release Account
8bc7d6bebd Makefile: Changes to split Solaris into Solaris2.3 and previous, and 2.4 and after from Paul Eggert.
Makefile: Added AMIGA changes from Rask Ingemann Lambertsen <rask@k4315.kampsax.dtu.dk>.
charset.c: Patch for Western European Languages from Josef Hinteregger <joehtg@joehtg.co.at>
charset.h: Patch for Western European Languages from Josef Hinteregger <joehtg@joehtg.co.at>
clitar.c: Patch to re-sync after read fail from (lost contributor name, sorry).
includes.h: Patch for AMIGA from Rask Ingemann Lambertsen <rask@k4315.kampsax.dtu.dk>
includes.h: Patch for SunOS atexit by Jeremy (jra@cygnus.com)
interface.c: Patch for AMIGA from Rask Ingemann Lambertsen <rask@k4315.kampsax.dtu.dk>
kanji.h: Patch for Western European Languages from Josef Hinteregger <joehtg@joehtg.co.at>
locking.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
locking.c: Patch to add granularity of lock files to usec by Jeremy (jra@cygnus.com)
pipes.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
proto.h: Patch to fix file locking from Jeremy (jra@cygnus.com)
reply.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
server.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
server.c: Patch for FAST_SHARE_MODE fix from (lost contributor name, sorry).
smb.h: Patch to fix file locking from Jeremy (jra@cygnus.com)
smb.h: Patch to add granularity of lock files to usec by Jeremy (jra@cygnus.com)
status.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
statuc.c: Patch to add granularity of lock files to usec by Jeremy (jra@cygnus.com)
system.c: Patch for Western European Languages from Josef Hinteregger <joehtg@joehtg.co.at>
trans2.c: Patch to fix file locking from Jeremy (jra@cygnus.com)
trans2.c: Patch to fix volume name reported to Win95 from Jeremy (jra@cygnus.com)
util.c: Patch for Western European Languages from Josef Hinteregger <joehtg@joehtg.co.at>
util.c: Patch to fix client_name from continuously returning UNKNOWN (from various contributors).
version.h: Update to 1.9.16p10.
(This used to be commit 03d28fa32e)
1997-01-09 18:02:17 +00:00
Samba Release Account
d613892674 JHT ==> Added extensions for PAM (Pluggable Authentication Module) support
for Linux and other little beasties that use PAM.
	Source: ftp.redhat.com/pub/Incoming/samba-1.9.16p9.src.rpm
	Originally from RedHat modifications to samba-1.9.15p8
(This used to be commit 79145bad56)
1997-01-02 04:04:49 +00:00
Samba Release Account
d68e27a3bc Added -f lockfile support.
jra@cygnus.com
(This used to be commit 84024a3df3)
1996-12-10 18:00:22 +00:00
Samba Release Account
53a9501444 Fixed quota support for FreeBsd.
jra@cygnus.com
(This used to be commit d1009c5351)
1996-12-10 17:58:11 +00:00
Samba Release Account
b719173ecb Added in veto files parameter create by Whistle.
jra@cygnus.com
(This used to be commit d5659df9c2)
1996-12-10 17:49:11 +00:00
Samba Release Account
b02557f80e Added Volkers fix for bundary condition. Needed as word
alignment wasn't being taken into account in space
calculations.
(This used to be commit 2fd77d66c0)
1996-12-03 19:05:27 +00:00
Samba Release Account
7da995a1dd Set num_validated_users to zero if Realloc fails.
(This used to be commit 57121e609e)
1996-11-09 01:56:20 +00:00
Samba Release Account
697e46373c Changed become_user to take a vuid as second arg.
Consistent with other changes to make smb_uid an index+offset
into the validated_users table.
jra@cygnus.com
(This used to be commit 89675f8ae8)
1996-10-25 20:50:31 +00:00
Samba Release Account
ddc18f4183 Modified all references to smb_uid to be vuid's.
jra@cygnus.com
(This used to be commit 5056672a3a)
1996-10-25 20:42:46 +00:00
Samba Release Account
2afda91963 Modified all references to uid to vuid.
jra@cygnus.com
(This used to be commit a2b07e5562)
1996-10-25 20:30:22 +00:00
Samba Release Account
8c5c55fea5 Core of the changes for returning smb_uid's. smb_uid's are now
returned as an index plus offset into the valudated_users table.
The offset (100) is added so that an smb_uid of zero becomes
an invalid value. All access into the validated_users table are
done by removing the offset and indexing into the table. Out of
ranges return NULL. Causes accesses into the validated_users table
to be more consistant and controlled.

This change made due to the fact that the uid field is only 16
bits in the smb header and we need for this not to be a unix
user id (which can ge 32 bits).

jra@cygnus.com
(This used to be commit ac265eff85)
1996-10-25 20:18:28 +00:00
Samba Release Account
9bc6d7f4d6 Changed definitions of prototypes to take uint16 vuid's not
int uid's. Part of the change for Samba to return an index+offset
into the registered users table rather than a raw unix uid.
Added casts to required prototypes for function pointers in
tables.
jra@cygnus.com
(This used to be commit ec2a3a1cf2)
1996-10-25 20:10:53 +00:00
Andrew Tridgell
08d00eb68e - added support for TMPDIR env variable
- fixed fault.c for linux 2.1
- put back in the FIND_SELF failing code
- cleaned up casts in encryption
(This used to be commit 3af04f1580)
1996-10-24 00:09:08 +00:00
Samba Release Account
dc0d4d2efb Jeremy <jra@cygnus.com>
Removed AS_USER requirement for SMBulogoff. A valid TID (cnum) is not
given for this call, which become_user needs if it is not to return
an error. This fixes a specific case with NT4.0 which stops users
attaching to a Samba server using a different account to the one they
are logged in under.
(This used to be commit c65a2cdd83)
1996-10-23 19:12:47 +00:00
Andrew Tridgell
6dc1fe06c1 - correctly handle non-encrypted share mode session-setup. We were
losing the username due to the recent "handle broken password lengths"
patch.
(This used to be commit b006cd6f91)
1996-10-09 15:08:29 +00:00
Andrew Tridgell
ec85f2e53d - revert to old idle dir code (marty pointed out a problem with the
new code)

- handle server level security in the new "detect NT password length
stuffups" code
(This used to be commit 7c135d4994)
1996-10-07 15:04:48 +00:00
Andrew Tridgell
dfa2b456c7 - continue when failing to load config file in nmblookup and smbclient
- fix important bug in nmbd where it set the return code for a
negative name response to 0 (which means success!)
(This used to be commit bfa816cc8f)
1996-10-07 11:06:34 +00:00
Andrew Tridgell
f3c79936d7 - replace the base36 function with one that works on more systems
(compiler bugs were the problem)

- minor password cleanups (catch WfWG bug where it sets the password
to a space instead of a NULL)

- fix printing problem for kanji users

- minor cleanups
(This used to be commit 92566ecc31)
1996-10-05 13:13:31 +00:00
Andrew Tridgell
e5893bdfbe I have fixed quite a few important bugs in this commit.
Luke, can you take special note of the bug fixes to nmbd so you can
propogate them to your new code.

- rewrote the code that used to use fromhost(). We now call
gethostbyaddr() only if necessary and a maximum of once per
connection. Calling gethostbyaddr() causes problems on some systems so
avoiding it if possible is a good thing :-)

- added the "fake oplocks" option. See the docs in smb.conf(5) and
Speed.txt

- fixed a serious bug in nmbd where it would try a DNS lookup on
FIND_SELF queries. This caused a lot of unnecessary (and incorrect)
DNS lookups to happen. FIND_SELF queries should only go to the
internal name tables.

- don't set FIND_SELF for name queries if we are a wins proxy, as we
are supposed to be answering queries for other hosts.

- fixed a bug in nmbd which had "if (search | FIND_LOCAL)" instead of
"if (search & FIND_LOCAL)". Luke, this was in nameservreply.c

- the above 3 bugs together meant that DNS queries were being cached,
but the cache wasn't being used, so every query was going to DNS, no
wonder nmbd has been chewing so much CPU time! Another side effect was
that queries on names in lmhosts weren't being answered for bcast
queries with "wins proxy" set.

- ignore the maxxmit for seconday session setups (see CIFS spec)

- close user opened files in a uLogoffX for user level security (see
CIFS spec)

- added uid into the files struct to support the above change
(This used to be commit ea472b7217)
1996-10-05 10:41:13 +00:00
Andrew Tridgell
38087ccb40 - use workgroup from smb.conf in smbclient
- change debug level on clitar stuff

- define MAP_FILE if not defined

- ensure we never set authoritative on queries in nmbd

- fake a positive response to SMBioctl, apparently this is needed for
some WfWg printer drivers

- deny file access for non-fcbopen queries when (access_allowed == AREAD && flags == O_RDWR)

- add sys_waitpid()
(This used to be commit 61e3116e57)
1996-10-05 02:54:37 +00:00
Andrew Tridgell
e23f2b9cef - changed the umask handling. We now set the umask to 0 and explicitly
set the mode on all created files. I think this is a better policy.

- change the debug levels on some items

- fix a charset handling bug which affected foreign and extended
charset users

- no longer switch back to the original directory when idle, instead
switch to / as the original directory may not be readable by ordinary
users.

- fix some bugs where the create mode of files was not being
explicitly set (it was relying on the umask and using fopen). Not a
big bug as it only affected obscure commands like the messaging ops.

- got rid of the lock code in the lpq cache as its no longer needed

- rewrote smbrun to be faster and to remove the security hole. We now
don't actually need a external smbrun binary, its all done by smbd.

- add a more explicit warning about uids and gids of -1 or 65535
(This used to be commit 5aa735c940)
1996-10-04 09:31:07 +00:00
Andrew Tridgell
986edc0146 - fix the EALREADY bug so connections to slow hosts with smbclient get
through

- add workarounds to handle the win95 and WinNT bugs in handling
password lengths in sessionsetup
(This used to be commit 671b3a3a77)
1996-10-02 16:16:16 +00:00
Andrew Tridgell
afd08462ad backout all the changes to nmbd.
The 1.9.16 tree is now back to 1.9.16p2 as far as nmbd is concerned
apart from a small change that fixes the announce type in two places.
(This used to be commit 45e66a69d3)
1996-10-02 15:41:30 +00:00
Andrew Tridgell
5a2f52b79e - a huge pile of changes from Luke which implement the browse.conf
stuff and also fix a pile of nmbd bugs. Unfortunately I found it very
hard to disentangle the new features from the bug fixes so I am
putting in the new code. I hope this is the last big pile of changes
to the 1.9.16 series!
(This used to be commit 20b6203dac)
1996-10-02 14:09:22 +00:00
Andrew Tridgell
11d9539d75 - accept either NT or lanman passwords in tconX
(This used to be commit b6c1c60d72)
1996-10-02 14:06:17 +00:00
Andrew Tridgell
908771bb0f added debug info
(This used to be commit 4a988021a2)
1996-08-24 01:46:47 +00:00
Samba Release Account
9ad5a3fe36 removed all of lukes recent changes. I need to do a p2 release but
can't test the multi group changes.

I also found that some of lukes changes wiped out some recent bug
fixes. Is your CVS tree ok luke?
(This used to be commit 8b7fe224bc)
1996-08-24 01:41:46 +00:00
Samba Release Account
8c41ad5614 fixed dircahe bug
(This used to be commit 050f941e21)
1996-08-24 01:32:51 +00:00
Samba Release Account
5945be9718 - fixed bugs in nmb response packet checking.
- added multiple workgroup code - samba can register under different
  (unique) NetBIOS aliases, one per workgroup it joins.

lkcl
(This used to be commit f24e341e7e)
1996-08-23 10:17:30 +00:00
Andrew Tridgell
9155889092 - add timeouts to connect() for password server connections. This
makes multiple password servers practical.
(This used to be commit 5c3e8326cc)
1996-08-22 06:32:03 +00:00
Andrew Tridgell
3d088fd65e - fix a bug handling readraw packets that caused the timeout to be 30
milliseconds instead of 30 seconds as was intended. Thanks to Paul
Nelson for finding this bug.
(This used to be commit 78f62c83be)
1996-08-21 14:15:09 +00:00
Andrew Tridgell
a782ffb5ed handle sigpipe better for server security
(This used to be commit d87fdb3ee9)
1996-08-21 12:36:01 +00:00
Samba Release Account
da0761ac0d JHT ==> Upgraded Samba to Windows NT Server version 4.1
Just to keep ahead of the pack.
	Note: Really only done to differntiate our version ID from
	existing SMB Servers.
(This used to be commit 6636c7b5b8)
1996-08-21 08:11:03 +00:00
Andrew Tridgell
b5a64bb740 - new handling of ST_TYPE bits, they are now consolidated much more in
DFLT_SERVER_TYPE in nameserv.h

- got rid of a lot of spurious domain controller stuff. Samba is not a
domain controller yet, but it can be a domain master. We were claiming
to be a domain controller in some packets which may have caused
problems

- don't do preferred master startups on the WINS pseudo-net

- don't do election requests on the WINS pseudo-net

- fix a nasty bug in become_non_master() which wiped out the bits in
remove_type before using them. The result was that samba didn't like
losing its master status.

- changed the logic in the election packet handling to enable us to
become a non-master whenever we receive a winning election frame, even
if we aren't expecting it

- get another packet from the socket in nmbd when we reject one of our
own packets, this stops us from going into the packet reading code too
often and makes nmbd much snappier

- always remove a name immediately when we try to release it, don't
wait for the lack of response from the network, otherwise we will end
up replying to name that we don't really own. We still send the dereg
packets, we just don't wait for them to time out.
(This used to be commit eb84f2f342)
1996-08-21 06:09:00 +00:00
Andrew Tridgell
748d65a4ac - fix a bug in NetServerEnum where counted and total were not counted
correctly if there were multiple instances of a name. This led to the
infamous "not enough memory" error when browsing (but this isn't the
only cause of that message)

- fix a triple-chaining bug which affected OpenX following a TconX

- fix a serious nmbd bug that meant nmdb would answer packets that it
wasn't supposed to, causing havoc with browse lists.

- never time out SELF packets. This is an interim fix until I find out
why nmbd thought they should be timed out.
(This used to be commit 2960c3908c)
1996-08-20 15:45:16 +00:00
Andrew Tridgell
241ecbe741 fix a bug in the new chaining code
(This used to be commit 50ed940451)
1996-08-19 13:54:58 +00:00
Andrew Tridgell
0c33046a0a - added "netbios name" option in smb.conf to make controlling the name
that samba uses possible

- added "socket address" option to allow virtual SMB servers (on
systems with IP aliasing line Linux)

- disabled FAST_SHARE_MODES by default in Linux as older Linux boxes
can't do shared writeable mappings. We really need autoconf ...

- added new option types in loadparm so a string type can be specified
ot be uppercase only, this is used for the workgroup and netbios name
options

- auto-create the lock directory if it doesn't exist in shared mem
startup

- get rid of announce_backup()

- change a few comments in nmbd code

- rewrote the chaining code completely. Hopefully it will handle any
depth chains now.

- added LPRng support
(This used to be commit e9eac6cd49)
1996-08-19 11:17:29 +00:00
Andrew Tridgell
efb8113d00 - made FAST_SHARE_MODES standard for Linux
- you can now press enter after a password prompt with "smbclient -L
hostname" and it will use a blank username and password, the same as
if you used -U%

- changed the wins.dat store code to not go via a string variable
(just use fprintf instead)

- removed a "unsigned long" that luke put back in, changing it to
uint32 to keep 64 bit machines happy. Naughtly luke!

- allow guest non-connnected print queue listings so ms client 3 can
work
(This used to be commit 917160dee6)
1996-08-17 14:27:12 +00:00
Andrew Tridgell
28177ca73b - added support for Amiga-unix (based on BSD I think)
- changed the order of PROGS and SPROGS in Makefile (SPROGS first)

- another 64 bit cleanup (for INADDR_NONE)

- added paranoia code in DirCacheAdd() to detect looping

- fixed important DirCache flush bug

- rewrote the NetServerEnum code after I found it could return servers
from multiple workgroups at once, and this could cause browsing
havoc. Now a null workgroup query is equivalent to a query for the
servers primary workgroup

- got rid of my_workgroup()

- got rid of "workgroup = *" comment in Makefile. We no longer support
a workgroup of *, users must set the workgroup explicitly

- the wins.dat file was being stored in a different format to what it
was being loaded in - this could cause havoc. fixed.

- uppercase our netbios name and the workgroup name at startup

- if accept fails in main loop when running as a daemon then continue,
don't just exit!

- don't use ./ on smbclient in smbtar

- better code to detect if a process exists
(This used to be commit ec3d539630)
1996-08-17 11:37:44 +00:00
Andrew Tridgell
47673b32ed - added FAST_SHARE_MODES code
- added some named pipe code from Jim
(This used to be commit c94866e9e4)
1996-08-15 15:11:34 +00:00
Andrew Tridgell
6475a91574 fixed an obvious bug that meant that DosPrintQEnum could never
work. Now we'll see if it works after this fix ...
(This used to be commit 9735d7e8e2)
1996-08-14 15:01:09 +00:00
Andrew Tridgell
cd41e6629e minor cleanups
(This used to be commit f1dc2b9317)
1996-08-13 12:35:28 +00:00
Andrew Tridgell
396311075c - sequent-ptx support from bressler@iftccu.ca.boeing.com (Rick
Bressler)
- machten support from Trevor Strohman (trev@figment.tenon.com)

- added qinfo command to client as part of drag-and-drop printer
support for win95 from David Chappell <chappell@mouse.cc.trincoll.edu>
He also added the "printer driver" option

- use sigblock() on more systems and use sigsetmask(0) instead of
sigunblock() as its more portable. This beats a problem with zombies
on heavilily loaded systems.

- added internals.doc written by David Chappell into the source tree

- get rid of PRINT_COMMAND options from local.h as they are no longer
relevent

- new kanji code from Fujita

- don't set the recursion_available flag on queries in nmbd

- fix a potential bug with pointer subtraction in printing.c

- got rid of error_count code as the real fix (the EOF problem) is now
in
(This used to be commit aa6f8b04d1)
1996-08-13 08:57:55 +00:00
Samba Release Account
02b98a8965 applying login updates from jim@oxfordcc.co.uk, sent in by
lewis2@server.uwindsor.ca. rest of this patch to follow.

bug in interface.c - uninitialised pointer.
nmbd has 0x20 as well as 0x0 NetBIOS name when lmhosts entry is added.

lkcl
(This used to be commit 2b9475cc5f)
1996-08-09 18:05:34 +00:00
Andrew Tridgell
2b4b7b4e1a fix a bug that we've had for a long time where we don't handle EOF
properly from clients, and end up looping like mad.

At least I _hope_ this is fixed.
(This used to be commit a7c7d7afe2)
1996-07-30 15:47:30 +00:00
Samba Release Account
25b30c08dc lots of changes to nmbd
lkcl
(This used to be commit 45d3b26447)
1996-07-17 18:33:36 +00:00
Samba Release Account
e5a0619c28 updated docs to match code mods from last two or three updates. done
some more commenting of code to match docs.

sorted some bugs.

ipc BOOL domains was uninitialised.

lkcl
(This used to be commit cb43ce7bc0)
1996-07-10 18:48:49 +00:00
Samba Release Account
7812ff0813 modified become_master() to a state-based system. becoming a master
is now performed in stages: wait for each NetBIOS name to be
successfully registered before proceeding to the next stage.

tied implicit name registration and release (broadcast method) to the
same piece of code as explicit method (via WINS server).

created special_browser_name() function that checks __MSBROWSE__
name: this name is ignored by WINS servers apparently.

fixed likely incompatibility between refresh_my_names() and add_my_names().
(netbios entries were unlikely to be refreshed).

NOTE: none of these changes have been tested. at all.

lkcl
(This used to be commit 7719fb0652)
1996-07-04 19:19:26 +00:00
Andrew Tridgell
07fcf2df03 - moved the protocol defs in the client to keep sill C compilers happy
- added change for cnum range in reply_tdis()
(This used to be commit 609c3a5e1e)
1996-07-03 01:58:27 +00:00
Samba Release Account
601281a43b patch to fix NetServerEnum with multiple workgroup lists kindly supplied.
it works for him. needs testing.
(This used to be commit 546c490807)
1996-07-01 18:54:02 +00:00
Andrew Tridgell
a521fe8a27 a cleanup of the receive_smb() usage, adding timeouts in some places
also added paranoid code in the main process() loop of smbd to detect
when smbd is looping uselessly. This should stop the "smbd is chewing
lots of cpu" reports
(This used to be commit 8e9dce34d5)
1996-06-10 05:16:19 +00:00
Andrew Tridgell
7e3b4a1c0d got rid of a lot of redundent header files as we now globally generate
prototypes automatically using "make proto". This is much less prone
to error than the old method of manually adding prototypes
(This used to be commit b551dc98f7)
1996-06-10 04:38:24 +00:00
Andrew Tridgell
4eba893b02 - added comments to byteorder.h explaining how it works.
- fixed problem with installscripts if srcdir is not set
- fixed ptr init bug in interface.c
- changed default lookup type in nmblookup to match nbtstat under NT
- new quotas fixes for sunos and solaris
(This used to be commit e775576f02)
1996-06-08 04:33:37 +00:00
Andrew Tridgell
d160d93d8f - added predict.c, moving the routines from util.c
- added iface_count() and iface_n_ip() routines so its easy to loop
over the local interface list

- made readsize a normal loadparm global

- check for null w in add_domain_entry()

- set the deathtime to time()-1 for doamin entries with servertype==0
This allows servers that are shutting down to be removed

- add the 0x1c name at startup if we are a WINS server. Previously we
added it only if we were a master

- loop over interfaces in add_my_domains(), so people don't have to
have a lmhosts file to get lp_workgroup() on all interfaces

- set add to True for find_workgroupstruct() in nmbsync, and check for
null return

- remove some ugly "errno = EBADF" bits. they just confused things.
(This used to be commit 88b191b488)
1996-06-07 03:34:22 +00:00
Andrew Tridgell
b9ae225b28 - added interface.c and removed all the references to myip, bcast_ip
and Netmask, instead replacing them with calls to routines in
interface.c

- got rid of old MAXINT define

- added code to ensure we only return one entry for each name in the ipc
enum routines

- added new_only option to add_netbios_entry() to prevent overwriting
of important names

- minor time handling fixup
(This used to be commit 7ed71b73ae)
1996-06-06 11:43:09 +00:00
Andrew Tridgell
f6655e8a38 - remove some incorrect prototypes from server.c
- formatting cleanup in check_master_browser()
- removed unused code from nameserv.c
(This used to be commit ed3ef2e47d)
1996-06-05 15:44:24 +00:00
Andrew Tridgell
e38afbf382 - changed some debug levels in clientutil.c
- added dir_check_ftype() to clean up the file type checking a bit

- added check for libc version >= 5 for setfsuid() for Linux

- moved the AM_MASTER() and related macros to nameserv.h

- added proper defines for the various netbios announce types

- don't call the announce_backup() code, as I'm pretty sure its wrong
it sent ANN_GetBackupListReq packets as broadcasts, they are supposed
to be used only by clients to the master browser to find a list of
available backup servers to remote a netserverenum to, I don't think
nmbd should ever send one.

- fixed a bug in the browse list writing

- minor debug cleanups

- put in the code to discard our own broadcasts (it won't work for
multi-homed hosts though)

- changed ELECTION_VERSION to 1 so we can be beaten by a NT 3.51 server by
lowering the os level.

- only do sync_browse_lists() if we are the master browser, otherwise
we'll cause network overload

- don't call tell_become_backup() as it appears to be badly broken, it
should only be used when the machine being told has its MAINTAIN_LIST
to to auto. Not calling it does no great harm anyway

- fix a nasty bug where becomebackup was confused with reset browser!

- make setbuffer() not get caught by the auto protototypes
(This used to be commit cfbad9b082)
1996-06-05 15:16:09 +00:00
Andrew Tridgell
5607ff396c add dummy quotas fn
fix typo in reply to backup lists
(This used to be commit bc4a299437)
1996-06-04 06:53:43 +00:00
Andrew Tridgell
a2c1623827 a huge pile of changes :-)
The biggest thing is the integration of Lukes new nmbd. Its still
largely untested, so we will really need some feedback

I've also added auto prototype generation and cleaned up a lot of
minor things as a result
(This used to be commit 0d8dcfa13c)
1996-06-04 06:42:03 +00:00
Andrew Tridgell
81e398963d - moved the uid handling to uid.c
- added setfsuid() support (for Linux)
- started adding some of Lukes changes, just the loadparm and ipc ones
so far
(This used to be commit 72543810ce)
1996-06-01 15:25:30 +00:00
Andrew Tridgell
58734631b4 Lots of changes!
- add faq info on NT printer handling
- add "delete readonly" option to help rcs users
- add stuff to man pages on new printer options
- add "proxy name resolution" option
- add "command string" -c option to smbclient (thanks Ken)
- split time functions into time.c
- rearrange the quotas stuff a bit and fix some bugs
- complete rehash of the time handling code thanks to Paul Eggert
- fix nmblookup output a bit
- add plp print queue parsing from Bertrand Wallrich
(This used to be commit 635b56f19c)
1996-05-31 15:13:29 +00:00
Andrew Tridgell
d8cf90d37f comment out the code that tries to handle the NT bug where the 2nd
passlen is wrong. The fix is worse than the problem :-)
(This used to be commit 51e22c9310)
1996-05-31 06:09:42 +00:00
Andrew Tridgell
1b87ef2440 - added an entry on WinDD to samba.faq
- added a sample smb.conf from Thoralf.Freitag@remserv.rz.fhtw-berlin.de
- print the errno when you get a can't change directory error
- added installscripts.sh from James_K._Foote.PARC@xerox.com
(This used to be commit 48c6b86d4c)
1996-05-30 03:16:17 +00:00
Andrew Tridgell
ec52001809 handle errors from receive_smb better, and print error string
(This used to be commit 7814eca4b2)
1996-05-29 07:54:01 +00:00
Andrew Tridgell
debd5b6ae9 fixed a typo
(This used to be commit 654c242045)
1996-05-29 07:49:50 +00:00
Andrew Tridgell
1956d13494 cleanups to make thinsg compile cleanly
(This used to be commit 39fbeb04ae)
1996-05-29 07:47:47 +00:00
Andrew Tridgell
2ef2593c92 made dptr_num signed to handle -1 from OS/2
(This used to be commit d2c5ab135c)
1996-05-05 11:35:09 +00:00
Andrew Tridgell
90d21da1b9 - fix a bug hanlding very log filenames
- move quotas support to separate file
- send keepalives to password server
(This used to be commit f81295c7b4)
1996-05-05 11:26:58 +00:00
Andrew Tridgell
04af282209 move quotas support out of server.c
(This used to be commit 1ed5645a5d)
1996-05-05 11:25:33 +00:00
Andrew Tridgell
11f7553c74 turn on KEEP_PASSWORD_SERVER_OPEN by default
(This used to be commit d2676cdd0b)
1996-05-05 11:25:07 +00:00
Andrew Tridgell
341a401b48 handle being passed a dptr of -1 to mean "close all open dir handles".
Looks like OS/2 does this. It caused a core dump.
(This used to be commit 4b2579daae)
1996-05-05 11:23:23 +00:00
Andrew Tridgell
52fc872aec - close the listening socket in the child process when running as a daemon
- exit with a non-zero exit code if open_sockets() fails
(This used to be commit 83866f3c84)
1996-05-05 03:04:19 +00:00
Andrew Tridgell
b2a31c9e81 - use issafe()
- map the archive bit in a more robust manner. We now set it when we
first write to the file after opening it.
(This used to be commit d20627b378)
1996-05-04 10:48:19 +00:00
Andrew Tridgell
03aeb8af5d fix a netgroup bug (innetgr() was being called with the args in the
wrong order!)
(This used to be commit 4419093d33)
1996-05-04 10:45:50 +00:00
Andrew Tridgell
089c5b2165 move the dot_pos calculation down a bit
(This used to be commit 45e2ffdc9c)
1996-05-04 10:44:49 +00:00
Andrew Tridgell
6bbd0d7b69 use the new issafe() macro instead of isalnum() and strchr()
(This used to be commit 79c65e66f8)
1996-05-04 10:43:29 +00:00
Samba Release Account
0e8fd33987 Initial version imported to CVS
(This used to be commit 291551d807)
1996-05-04 07:50:46 +00:00