summaryrefslogtreecommitdiffstats
path: root/source/nmbd
Commit message (Collapse)AuthorAgeFilesLines
* update copyright notice since it we are now almost 4 months into 2003Gerald Carter2003-03-301-1/+1
|
* Don't use old usage() function, but the one from popt.Jelmer Vernooij2003-03-241-1/+0
| | | | Remove some useless arguments
* Revoke some of the popt patch from metze I applied earlier today. It addedJelmer Vernooij2003-03-241-0/+1
| | | | some double options and broke some parameters.
* Patch from metze to generalise POPT_COMMON_SAMBA, with some minor changesJelmer Vernooij2003-03-241-5/+0
|
* Add nicer --help headersJelmer Vernooij2003-03-221-7/+3
|
* use pstrcpy_base()Jim McDonough2003-03-201-1/+1
|
* replace pstrcpyJim McDonough2003-03-191-1/+1
|
* Fix nmbd under -DDEVELOPER (pstrcpy on not-pstring).Andrew Bartlett2003-03-161-5/+10
| | | | | | Make a new macro to help in this situation, and add memcpy() parinoia Andrew Bartlett
* String handling parinoia fixes.Andrew Bartlett2003-03-152-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch enables the compile-time checking of strings assable by means of sizeof(). (Original code had the configure check reversed). This is extended to all safe_strcpy() users, push_string and pull_string, as well as the cli and srv derivitives. There is an attempt to cap strings at the end of the cli buffer, and clobber_region() of the speified length (when not -1 :-). Becouse of the way they are declared, the 'overmalloc a string' users of safe_strcpy() have been changed to use overmalloc_safe_strcpy() (which skips some of the checks). This whole ball of mud worked fine, until I pulled out my 'fix' for our statcache. When jeremy fixes that, we should be able to get back to testing this stuff. This patch also includes a 'marker' of the last caller to clobber_region (ie, the function that called pstrcpy() that called clobber_region) to assist in debugging problems that may have smashed the stack. This is printed at smb_panic() time. (Original idea and patch by metze). It also removes some unsused functions, and #if 0's some others that are unused but probably should be used in the near future. For now, this patch gives us some confidence on one class of trivial parsing error in our code. Andrew Bartlett
* check a pointer before dereferencing it; not sure why userdata == NULL thoughGerald Carter2003-03-101-1/+1
|
* Make sure that the 'remote' machine name can only be set once. For some weirdAndrew Bartlett2003-03-081-1/+1
| | | | | | | | | | | | reason, during a Win2003 installation, when you select 'domain join' it sends one machine name in the name exchange, and litraly 'machinename' during the NTLMSSP login. Also fix up winbindd's logfile handling, so that it matches smbd and nmbd. (This helps me, by seperating the logs by pid). Andrew Bartlett
* A couple more fixes for fstrcpy() into a malloced region. In this case it'sAndrew Bartlett2003-03-052-5/+5
| | | | | | | all perfectly legit - the region is an fstring in length, but might not always be, and it is the last peice of code to fail my automated test. Andrew Bartlett
* Make this an fstrcat(), as this seems to fix some weird issue with the serverAndrew Bartlett2003-01-281-2/+2
| | | | | | name being truncated... (either way, it's the correct thing to do). Andrew Bartlett
* The last of the fstring/pstring mixups, and an extra 'static'.Andrew Bartlett2003-01-142-2/+2
|
* patch to include support for daemontools from Michael HandlerGerald Carter2003-01-031-3/+21
|
* BIG patch...Andrew Bartlett2003-01-026-10/+11
| | | | | | | | | | | | | | | | This patch makes Samba compile cleanly with -Wwrite-strings. - That is, all string literals are marked as 'const'. These strings are always read only, this just marks them as such for passing to other functions. What is most supprising is that I didn't need to change more than a few lines of code (all in 'net', which got a small cleanup of net.h and extern variables). The rest is just adding a lot of 'const'. As far as I can tell, I have not added any new warnings - apart from making all of tdbutil.c's function const (so they warn for adding that const string to struct). Andrew Bartlett
* Forward port the change to talloc_init() to make all talloc contextsJeremy Allison2002-12-201-0/+20
| | | | | named. Ensure we can query them. Jeremy.
* Protect nmbd against malformed reply packets. Some reports on the lists showingJeremy Allison2002-12-191-1/+10
| | | | | these. Jeremy.
* Stop using hacks for dns host/domain names.Jim McDonough2002-12-031-3/+5
|
* Remove extra headers, and ensure that we correctly bail out of winbindd if weAndrew Bartlett2002-12-015-5/+0
| | | | | | can't create the socket. Andrew Bartlett
* Lots of fixes for error paths where tdb_fetch() data need freeing.Jeremy Allison2002-11-231-3/+10
| | | | | Found via a post from Arcady Chernyak <Arcady.Chernyak@efi.com>. Jeremy.
* Fix from "Stefan (metze) Metzmacher" <metze@metzemix.de> for nmbd 1c groupJeremy Allison2002-11-151-0/+16
| | | | | release. Jeremy.
* Removed global_myworkgroup, global_myname, global_myscope. Added liberalJeremy Allison2002-11-1218-295/+158
| | | | | | dashes of const. This is a rather large check-in, some things may break. It does compile though :-). Jeremy.
* Compleatly remove support for logfile truncation. All logs are opened forAndrew Bartlett2002-11-081-5/+0
| | | | | | | | append writes. (blessed by jra) Andrew Bartlett
* Make IRIX happyJelmer Vernooij2002-11-041-16/+15
|
* Add more options to popt_common and use them. Current ones are:Jelmer Vernooij2002-11-021-21/+7
| | | | | | | | | -V Version information -n Set netbios name -l Set directory to store log files in -d Set debuglevel -s Load specified configuration file -O Set socket options
* Convert to poptJelmer Vernooij2002-11-021-87/+30
|
* Ensure we register the 1c name on the unicast subnet.Jeremy Allison2002-10-081-0/+10
| | | | Jeremy.
* fixed 3 bugs in the wins server code related to precedence of ! and &Andrew Tridgell2002-10-031-2/+2
| | | | | | | | | in C please note that: if (! a & b) is not the same as: if (! (a & b))
* Patch from Andy Levine andyl@epicrealm.com who discovered that W2K DMB'sJeremy Allison2002-09-101-1/+5
| | | | | return empty NetServerEnum2 on port 445, but not on port 139. Jeremy.
* fix for difference in strsep and strtok semanticsHerb Lewis2002-08-221-0/+1
|
* fix irix compile errors - cannot initialize array in declaration statementHerb Lewis2002-08-201-1/+1
| | | | with non-const values - strsep not defined
* The unused variable was actually needed. The correct fix is to moveTim Potter2002-08-151-1/+1
| | | | | it inside an #ifdef HAVE_ADS to avoid the warning and breaking the build. (-:
* Removed unused variable.Tim Potter2002-08-151-1/+0
|
* Make 'remote_machine' private to lib/substitute.c, and fix all the user to useAndrew Bartlett2002-08-111-2/+1
| | | | | | the new accessor functions. Andrew Bartlett
* Add AD version of samlogon replies for getdc. ATM it will only functionJim McDonough2002-08-061-11/+103
| | | | if you have an ADS DC.
* Fix length on mailslots. Looks like it should have been 0x17, not decimal 17.Jim McDonough2002-08-021-1/+1
|
* this is an interim fix for nmbd not registering DOMAIN#1b with WINSAndrew Tridgell2002-07-281-1/+20
| | | | | | when a PDC. The fix does not iterate over all WINS tags, which it should do, but after having looked at doing that it gets *very* messy to do with our current code base.
* make sure async dns nmbd child diesAndrew Tridgell2002-07-282-1/+8
| | | | samba-patches 898
* fix minor nits in nmbd from adtam@cup.hp.comAndrew Tridgell2002-07-283-13/+13
| | | | samba-patches 959
* I think this makes the debug statement clearer.Andrew Bartlett2002-07-261-1/+1
| | | | | | (but assumes that 'myip' is indeed our local IP...) Andrew Bartlett
* the last WINS update broke self registration when we are a WINSAndrew Tridgell2002-07-091-3/+4
| | | | | | | | | | | | | server. The real problem is all the special cases we had for when we are a wins server as opposed to when we are using a 'real' wins server. This patch removes the special cases. We now accept non-broadcast packets from ourselves and we use ourselves as a wins server when we are one. This gets rid of the special cases and simplifies things quite a bit. It all seems to work, but there are bound to be problems found later.
* fixed multi-homed re-registration of names when we are a WINSAndrew Tridgell2002-07-011-1/+11
| | | | server. We were rejecting them, leaving the name unregistered!
* don't start the async dns process unless we actually need it!Andrew Tridgell2002-07-011-1/+1
| | | | (ie. check for lp_dns_proxy())
* The next phase in the WINS rewrite!Andrew Tridgell2002-06-279-829/+802
| | | | | | | | | | | | | | | | We now cope wiith multiple WINS groups and multiple failover servers for release and refresh as well as registration. We also do the regitrations in the same fashion as W2K does, where we don't try to register the next IP in the list for a name until the WINS server has acked the previos IP. This prevents us flooding the WINS server and also seems to make for much more reliable multi-homed registration. I also changed the dead WINS server code to mark pairs of IPs dead, not individual IPs. The idea is that a WINS server might be dead from the point of view of one of our interfaces, but not another, so we need to keep talking to it on one while moving onto a failover WINS server on the other interface. This copes much better with partial LAN outages and weird routing tables.
* This commit finally gives us multiple wins server groups. We nowAndrew Tridgell2002-06-262-171/+224
| | | | | | | | | | | | | | | | | | | | | | | | accept an extended syntax for 'wins server' like this: wins server = group1:192.168.2.10 group2:192.168.3.99 group1:192.168.0.1 The tags before the IPs don't mean anything, they are just a way of grouping IPs together. If you use the old syntax (ie. no ':') then an implicit group name of '*' is used. In general I'd recommend people use interface names for the group names, but it doesn't matter much. When we register in nmbd we try to register all our IPs with each group of WINS servers. We keep trying until all of them are registered with every group, falling back to the failover WINS servers for each group as we go. When we do a WINS lookup we try each of the WINS servers for each group. If a WINS server for a group gives a negative answer then we give up on that group and move to the next group. If it times out then we move to the next failover wins server in the group. In either case, if a WINS server doesn't respond then we mark it dead for 10 minutes, to prevent lengthy waits for dead servers.
* we never pass any userdata when doing name registrations on theAndrew Tridgell2002-06-261-54/+51
| | | | | | unicast subnet, so remove that parameter. That frees up userdata so I can start using it to indicate which wins server tag we are registering (more about wins 'tags' later ...)
* - completely rewrote the wins_srv.c code. It is now much simpler, andAndrew Tridgell2002-06-263-7/+29
| | | | | | | | | | | | | | gives us a good grounding to properly support multiple wins servers for different interfaces (which will be coming soon ...) - fixed our wins registration failover code to actually do failover! We were not trying to register with a secondary wins server at all when the primary was down. We now fallback correctly. - fixed the multi-homed name registration packets so that they work even in a non-connected network (ie. when one of our interfaces is not routable from the wins server. Yes, this really happens in the real world).
* when nmbd starts up it is possible that dhcp hasn't started the localAndrew Tridgell2002-06-191-4/+9
| | | | | interfaces yet. Instead of giving up, nmbd will now wait for some interfaces to appear
* compile warngin fixes merged from 2.2Gerald Carter2002-06-171-2/+2
|