summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>1998-02-26 19:26:18 +0000
committerJeremy Allison <jra@samba.org>1998-02-26 19:26:18 +0000
commit64095b2486e3aca286103e28e400da3e40b14556 (patch)
tree9482955cb3daefa3f544a0fad33577cec5ee5d86
parent4680e65bb5a6da5131135a155573e1d2592ed1b0 (diff)
downloadsamba-64095b2486e3aca286103e28e400da3e40b14556.tar.gz
samba-64095b2486e3aca286103e28e400da3e40b14556.tar.bz2
samba-64095b2486e3aca286103e28e400da3e40b14556.zip
Code to work around a bug in FTP OnNet software NBT implementation.
They do a broadcast name release for WORKGROUP<0> and WORKGROUP<1e> names and *don't set the group bit*. Jeremy. (This used to be commit 1feb54e1ba27ab8aba2df4ebef4df010ca980f12)
-rw-r--r--source3/nmbd/nmbd_incomingrequests.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/source3/nmbd/nmbd_incomingrequests.c b/source3/nmbd/nmbd_incomingrequests.c
index 57517c3734..ae163c6014 100644
--- a/source3/nmbd/nmbd_incomingrequests.c
+++ b/source3/nmbd/nmbd_incomingrequests.c
@@ -29,6 +29,7 @@
#include "includes.h"
extern int DEBUGLEVEL;
+extern fstring myworkgroup;
/****************************************************************************
Send a name release response.
@@ -95,6 +96,21 @@ subnet %s from owner IP %s\n",
if( group && !ismyip(owner_ip) )
return;
+ /*
+ * Code to work around a bug in FTP OnNet software NBT implementation.
+ * They do a broadcast name release for WORKGROUP<0> and WORKGROUP<1e>
+ * names and *don't set the group bit* !!!!!
+ */
+
+ if( !group && !ismyip(owner_ip) && strequal(question->name, myworkgroup) &&
+ ((question->name_type == 0x0) || (question->name_type == 0x1e)))
+ {
+ DEBUG(6,("process_name_release_request: FTP OnNet bug workaround. Ignoring \
+group release name %s from IP %s on subnet %s with no group bit set.\n",
+ namestr(question), inet_ntoa(owner_ip), subrec->subnet_name ));
+ return;
+ }
+
namerec = find_name_on_subnet(subrec, &nmb->question.question_name, FIND_ANY_NAME);
/* We only care about someone trying to release one of our names. */