summaryrefslogtreecommitdiff
path: root/source3/param
diff options
context:
space:
mode:
authorSamba Release Account <samba-bugs@samba.org>1997-07-06 12:06:23 +0000
committerSamba Release Account <samba-bugs@samba.org>1997-07-06 12:06:23 +0000
commitb4863b07f4d659fe37531f04621a80180c014e0a (patch)
tree0a53ff3fefced221c7473ff8cb30d182123dad2d /source3/param
parent21e0589f347116ba1fa3ac5b35e651c4de406a46 (diff)
downloadsamba-b4863b07f4d659fe37531f04621a80180c014e0a.tar.gz
samba-b4863b07f4d659fe37531f04621a80180c014e0a.tar.bz2
samba-b4863b07f4d659fe37531f04621a80180c014e0a.zip
replaced the "wins proxy" to treat NetBIOS names as DNS names with new
"dns proxy" option. the "wins proxy" option should be used for broadcast only hosts, and isn't properly implemented anyway. the new "dns proxy" option can be disabled if the (blocking) dns resolution takes up a significant amount of time. this _will_ occur if gethostbyname does external DNS lookups, instead of just (immediately) returning entries in /etc/hosts. lkcl (This used to be commit 350dfc57dd3001ba27519000a2ab9dd541a66ac7)
Diffstat (limited to 'source3/param')
-rw-r--r--source3/param/loadparm.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index 9d3850b242..4c6ce30b19 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -155,6 +155,7 @@ typedef struct
int shmem_size;
int shmem_hash_size;
int client_code_page;
+ BOOL bDNSproxy;
BOOL bWINSsupport;
BOOL bWINSproxy;
BOOL bLocalMaster;
@@ -444,6 +445,7 @@ struct parm_struct
{"client code page", P_INTEGER, P_GLOBAL, &Globals.client_code_page, NULL},
{"os level", P_INTEGER, P_GLOBAL, &Globals.os_level, NULL},
{"max ttl", P_INTEGER, P_GLOBAL, &Globals.max_ttl, NULL},
+ {"dns proxy", P_BOOL, P_GLOBAL, &Globals.bDNSproxy, NULL},
{"wins support", P_BOOL, P_GLOBAL, &Globals.bWINSsupport, NULL},
{"wins proxy", P_BOOL, P_GLOBAL, &Globals.bWINSproxy, NULL},
{"wins server", P_STRING, P_GLOBAL, &Globals.szWINSserver, NULL},
@@ -650,6 +652,19 @@ static void init_globals(void)
Globals.bBrowseList = True;
Globals.bWINSsupport = False;
Globals.bWINSproxy = False;
+
+/* this parameter is currently set to the default functionality
+ in samba. given that w95 and NT is starting to use DNS for
+ server resolution, i expect that at some point it would be
+ sensible to default this to False.
+
+ this parameter is added because nmbd is a single process, and
+ gethostbyname is a blocking call, which can take out nmbd for
+ several seconds while a dns lookup is performed.
+
+ */
+
+ Globals.bDNSproxy = True;
}
/***************************************************************************
@@ -802,6 +817,7 @@ FN_GLOBAL_STRING(lp_interfaces,&Globals.szInterfaces)
FN_GLOBAL_STRING(lp_socket_address,&Globals.szSocketAddress)
FN_GLOBAL_STRING(lp_nis_home_map_name,&Globals.szNISHomeMapName)
+FN_GLOBAL_BOOL(lp_dns_proxy,&Globals.bDNSproxy)
FN_GLOBAL_BOOL(lp_wins_support,&Globals.bWINSsupport)
FN_GLOBAL_BOOL(lp_wins_proxy,&Globals.bWINSproxy)
FN_GLOBAL_BOOL(lp_local_master,&Globals.bLocalMaster)