mirror of
https://github.com/samba-team/samba.git
synced 2025-01-08 21:18:16 +03:00
s3: smbd: Rename "unix extensions" -> "smb1 unix extensions".
Make 'unix extensions' a synonym for "smb1 unix extensions". This will allow us to have a separate "smb2 unix extensions" parameter that we can examine separately. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: David Mulder <dmulder@suse.com> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Jan 25 21:43:59 UTC 2022 on sn-devel-184
This commit is contained in:
parent
1224d463e8
commit
d85461c4f5
@ -1,11 +1,12 @@
|
|||||||
<samba:parameter name="unix extensions"
|
<samba:parameter name="smb1 unix extensions"
|
||||||
context="G"
|
context="G"
|
||||||
type="boolean"
|
type="boolean"
|
||||||
xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
|
xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
|
||||||
|
<synonym>unix extensions</synonym>
|
||||||
<description>
|
<description>
|
||||||
<para>This boolean parameter controls whether Samba
|
<para>This boolean parameter controls whether Samba
|
||||||
implements the CIFS UNIX extensions, as defined by HP.
|
implements the SMB1/CIFS UNIX extensions, as defined by HP.
|
||||||
These extensions enable Samba to better serve UNIX CIFS clients
|
These extensions enable Samba to better serve UNIX SMB1/CIFS clients
|
||||||
by supporting features such as symbolic links, hard links, etc...
|
by supporting features such as symbolic links, hard links, etc...
|
||||||
These extensions require a similarly enabled client, and are of
|
These extensions require a similarly enabled client, and are of
|
||||||
no current use to Windows clients.</para>
|
no current use to Windows clients.</para>
|
@ -715,7 +715,7 @@ static void init_globals(struct loadparm_context *lp_ctx, bool reinit_globals)
|
|||||||
Globals.lock_spin_time = WINDOWS_MINIMUM_LOCK_TIMEOUT_MS; /* msec. */
|
Globals.lock_spin_time = WINDOWS_MINIMUM_LOCK_TIMEOUT_MS; /* msec. */
|
||||||
Globals.use_mmap = true;
|
Globals.use_mmap = true;
|
||||||
Globals.unicode = true;
|
Globals.unicode = true;
|
||||||
Globals.unix_extensions = true;
|
Globals.smb1_unix_extensions = true;
|
||||||
Globals.reset_on_zero_vc = false;
|
Globals.reset_on_zero_vc = false;
|
||||||
Globals.log_writeable_files_on_exit = false;
|
Globals.log_writeable_files_on_exit = false;
|
||||||
Globals.create_krb5_conf = true;
|
Globals.create_krb5_conf = true;
|
||||||
@ -4660,7 +4660,7 @@ void widelinks_warning(int snum)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lp_unix_extensions() && lp_wide_links(snum)) {
|
if (lp_smb1_unix_extensions() && lp_wide_links(snum)) {
|
||||||
DBG_ERR("Share '%s' has wide links and unix extensions enabled. "
|
DBG_ERR("Share '%s' has wide links and unix extensions enabled. "
|
||||||
"These parameters are incompatible. "
|
"These parameters are incompatible. "
|
||||||
"Wide links will be disabled for this share.\n",
|
"Wide links will be disabled for this share.\n",
|
||||||
@ -4671,7 +4671,7 @@ void widelinks_warning(int snum)
|
|||||||
bool lp_widelinks(int snum)
|
bool lp_widelinks(int snum)
|
||||||
{
|
{
|
||||||
/* wide links is always incompatible with unix extensions */
|
/* wide links is always incompatible with unix extensions */
|
||||||
if (lp_unix_extensions()) {
|
if (lp_smb1_unix_extensions()) {
|
||||||
/*
|
/*
|
||||||
* Unless we have "allow insecure widelinks"
|
* Unless we have "allow insecure widelinks"
|
||||||
* turned on.
|
* turned on.
|
||||||
|
@ -320,7 +320,7 @@ static NTSTATUS reply_nt1(struct smb_request *req, uint16_t choice)
|
|||||||
capabilities |= CAP_UNICODE;
|
capabilities |= CAP_UNICODE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lp_unix_extensions()) {
|
if (lp_smb1_unix_extensions()) {
|
||||||
capabilities |= CAP_UNIX;
|
capabilities |= CAP_UNIX;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4293,7 +4293,7 @@ static size_t calc_max_read_pdu(const struct smb_request *req)
|
|||||||
return 0x1FFFF;
|
return 0x1FFFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return 0x1FFFF;
|
return 0x1FFFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2720,7 +2720,7 @@ static void call_trans2findfirst(connection_struct *conn,
|
|||||||
break;
|
break;
|
||||||
case SMB_FIND_FILE_UNIX:
|
case SMB_FIND_FILE_UNIX:
|
||||||
case SMB_FIND_FILE_UNIX_INFO2:
|
case SMB_FIND_FILE_UNIX_INFO2:
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
@ -3190,7 +3190,7 @@ resume_key = %d resume name = %s continue=%d level = %d\n",
|
|||||||
case SMB_FIND_FILE_UNIX_INFO2:
|
case SMB_FIND_FILE_UNIX_INFO2:
|
||||||
/* Always use filesystem for UNIX mtime query. */
|
/* Always use filesystem for UNIX mtime query. */
|
||||||
ask_sharemode = false;
|
ask_sharemode = false;
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -3918,7 +3918,7 @@ cBytesSector=%u, cUnitTotal=%u, cUnitAvail=%d\n", (unsigned int)bsize, (unsigned
|
|||||||
bool large_read = !srv_is_signing_active(xconn);
|
bool large_read = !srv_is_signing_active(xconn);
|
||||||
int encrypt_caps = 0;
|
int encrypt_caps = 0;
|
||||||
|
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return NT_STATUS_INVALID_LEVEL;
|
return NT_STATUS_INVALID_LEVEL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3964,7 +3964,7 @@ cBytesSector=%u, cUnitTotal=%u, cUnitAvail=%d\n", (unsigned int)bsize, (unsigned
|
|||||||
int rc;
|
int rc;
|
||||||
vfs_statvfs_struct svfs;
|
vfs_statvfs_struct svfs;
|
||||||
|
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return NT_STATUS_INVALID_LEVEL;
|
return NT_STATUS_INVALID_LEVEL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -3998,7 +3998,7 @@ cBytesSector=%u, cUnitTotal=%u, cUnitAvail=%d\n", (unsigned int)bsize, (unsigned
|
|||||||
uint32_t sid_bytes;
|
uint32_t sid_bytes;
|
||||||
uint32_t i;
|
uint32_t i;
|
||||||
|
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return NT_STATUS_INVALID_LEVEL;
|
return NT_STATUS_INVALID_LEVEL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -4303,7 +4303,7 @@ static void call_trans2setfsinfo(connection_struct *conn,
|
|||||||
|
|
||||||
switch(info_level) {
|
switch(info_level) {
|
||||||
case SMB_SET_CIFS_UNIX_INFO:
|
case SMB_SET_CIFS_UNIX_INFO:
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
DEBUG(2,("call_trans2setfsinfo: "
|
DEBUG(2,("call_trans2setfsinfo: "
|
||||||
"SMB_SET_CIFS_UNIX_INFO is invalid with "
|
"SMB_SET_CIFS_UNIX_INFO is invalid with "
|
||||||
"unix extensions off\n"));
|
"unix extensions off\n"));
|
||||||
@ -4359,7 +4359,7 @@ static void call_trans2setfsinfo(connection_struct *conn,
|
|||||||
size_t param_len = 0;
|
size_t param_len = 0;
|
||||||
size_t data_len = total_data;
|
size_t data_len = total_data;
|
||||||
|
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(
|
reply_nterror(
|
||||||
req,
|
req,
|
||||||
NT_STATUS_INVALID_LEVEL);
|
NT_STATUS_INVALID_LEVEL);
|
||||||
@ -5163,7 +5163,7 @@ NTSTATUS smbd_do_qfilepathinfo(connection_struct *conn,
|
|||||||
size_t len = 0;
|
size_t len = 0;
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return NT_STATUS_INVALID_LEVEL;
|
return NT_STATUS_INVALID_LEVEL;
|
||||||
}
|
}
|
||||||
if (!req->posix_pathnames) {
|
if (!req->posix_pathnames) {
|
||||||
@ -5983,7 +5983,7 @@ static void call_trans2qfilepathinfo(connection_struct *conn,
|
|||||||
DEBUG(3,("call_trans2qfilepathinfo: TRANSACT2_QFILEINFO: level = %d\n", info_level));
|
DEBUG(3,("call_trans2qfilepathinfo: TRANSACT2_QFILEINFO: level = %d\n", info_level));
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -6066,7 +6066,7 @@ static void call_trans2qfilepathinfo(connection_struct *conn,
|
|||||||
DEBUG(3,("call_trans2qfilepathinfo: TRANSACT2_QPATHINFO: level = %d\n", info_level));
|
DEBUG(3,("call_trans2qfilepathinfo: TRANSACT2_QPATHINFO: level = %d\n", info_level));
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -9052,7 +9052,7 @@ NTSTATUS smbd_do_setfilepathinfo(connection_struct *conn,
|
|||||||
int data_return_size = 0;
|
int data_return_size = 0;
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
return NT_STATUS_INVALID_LEVEL;
|
return NT_STATUS_INVALID_LEVEL;
|
||||||
}
|
}
|
||||||
if (!req->posix_pathnames) {
|
if (!req->posix_pathnames) {
|
||||||
@ -9280,7 +9280,7 @@ static void call_trans2setfilepathinfo(connection_struct *conn,
|
|||||||
info_level = SVAL(params,2);
|
info_level = SVAL(params,2);
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -9359,7 +9359,7 @@ static void call_trans2setfilepathinfo(connection_struct *conn,
|
|||||||
info_level = SVAL(params,0);
|
info_level = SVAL(params,0);
|
||||||
|
|
||||||
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
if (INFO_LEVEL_IS_UNIX(info_level)) {
|
||||||
if (!lp_unix_extensions()) {
|
if (!lp_smb1_unix_extensions()) {
|
||||||
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
reply_nterror(req, NT_STATUS_INVALID_LEVEL);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user