summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2001-03-16 02:31:24 +0000
committerAndrew Tridgell <tridge@samba.org>2001-03-16 02:31:24 +0000
commitc9b8da47a68c98d72d59d25d1e2d8f3069300f40 (patch)
tree7bb77b1e2ce2ee311fecdf297b7813a2769a6d1f
parentcd3c0592fc00d28492783db2dc7c601743a9c892 (diff)
downloadsamba-c9b8da47a68c98d72d59d25d1e2d8f3069300f40.tar.gz
samba-c9b8da47a68c98d72d59d25d1e2d8f3069300f40.tar.bz2
samba-c9b8da47a68c98d72d59d25d1e2d8f3069300f40.zip
enable unicode on the wire by default in smbd
the unicode support isn't complete, but it is good enough to be usable for a test server. (This used to be commit e787fc1daf4a46c182e87bf0697eec80ff0ce87a)
-rw-r--r--source3/include/proto.h1
-rw-r--r--source3/param/loadparm.c4
-rw-r--r--source3/smbd/negprot.c4
3 files changed, 7 insertions, 2 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 5cde8ca085..d244329470 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1625,6 +1625,7 @@ BOOL lp_bind_interfaces_only(void);
BOOL lp_unix_password_sync(void);
BOOL lp_passwd_chat_debug(void);
BOOL lp_nt_smb_support(void);
+BOOL lp_unicode(void);
BOOL lp_nt_pipe_support(void);
BOOL lp_nt_acl_support(void);
BOOL lp_stat_cache(void);
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index eafed8172a..8ea1d2e816 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -268,6 +268,7 @@ typedef struct
BOOL bDebugUid;
BOOL bHostMSDfs;
BOOL bHideLocalUsers;
+ BOOL bUnicode;
}
global;
@@ -775,6 +776,7 @@ static struct parm_struct parm_table[] = {
{"protocol", P_ENUM, P_GLOBAL, &Globals.maxprotocol, NULL, enum_protocol, 0},
{"max protocol", P_ENUM, P_GLOBAL, &Globals.maxprotocol, NULL, enum_protocol, 0},
{"min protocol", P_ENUM, P_GLOBAL, &Globals.minprotocol, NULL, enum_protocol, 0},
+ {"unicode", P_BOOL, P_GLOBAL, &Globals.bUnicode, NULL, NULL, 0},
{"read bmpx", P_BOOL, P_GLOBAL, &Globals.bReadbmpx, NULL, NULL, 0},
{"read raw", P_BOOL, P_GLOBAL, &Globals.bReadRaw, NULL, NULL, 0},
{"write raw", P_BOOL, P_GLOBAL, &Globals.bWriteRaw, NULL, NULL, 0},
@@ -1251,6 +1253,7 @@ static void init_globals(void)
Globals.bBindInterfacesOnly = False;
Globals.bUnixPasswdSync = False;
Globals.bPasswdChatDebug = False;
+ Globals.bUnicode = True; /* Do unicode on the wire by default */
Globals.bNTSmbSupport = True; /* Do NT SMB's by default. */
Globals.bNTPipeSupport = True; /* Do NT pipes by default. */
Globals.bNTAclSupport = True; /* Use NT ACLs by default. */
@@ -1508,6 +1511,7 @@ FN_GLOBAL_BOOL(lp_bind_interfaces_only, &Globals.bBindInterfacesOnly)
FN_GLOBAL_BOOL(lp_unix_password_sync, &Globals.bUnixPasswdSync)
FN_GLOBAL_BOOL(lp_passwd_chat_debug, &Globals.bPasswdChatDebug)
FN_GLOBAL_BOOL(lp_nt_smb_support, &Globals.bNTSmbSupport)
+FN_GLOBAL_BOOL(lp_unicode, &Globals.bUnicode)
FN_GLOBAL_BOOL(lp_nt_pipe_support, &Globals.bNTPipeSupport)
FN_GLOBAL_BOOL(lp_nt_acl_support, &Globals.bNTAclSupport)
FN_GLOBAL_BOOL(lp_stat_cache, &Globals.bStatCache)
diff --git a/source3/smbd/negprot.c b/source3/smbd/negprot.c
index e15af3f3ae..ffc5d5e398 100644
--- a/source3/smbd/negprot.c
+++ b/source3/smbd/negprot.c
@@ -200,8 +200,8 @@ static int reply_nt1(char *outbuf)
}
- /* until the unicode conversion is complete have it disabled by default */
- if (getenv("SMBD_USE_UNICODE")) {
+ /* allow for disabling unicode */
+ if (lp_unicode()) {
capabilities |= CAP_UNICODE;
}