[SCM] Samba Shared Repository - branch master updated
Jeremy Allison
jra at samba.org
Wed Feb 15 05:21:02 UTC 2017
The branch, master has been updated
via e08110e s3/rpc_server/mdssvc: add attribute "kMDItemContentType"
via 2ef3cb0 lib: Avoid an "includes.h"
via ec5f42f winbind: Fix a signed/unsigned mixup
via ad15f5c libsmb: Fix whitespace
via 5f2c636 lib: Fix some whitespace
via 5a03c42 smbd: Fix some whitespace
via 68e1a64 auth3: Use NT_STATUS_EQUAL
via 9699c38 winbind: Fix a typo
via 02380ca ctdb: Only build test_mutex_raw.c on Linux
via 9ab820d smbd: Fix some whitespace
via 4492583 smbd: Make "create_file_sids" static
via 2251c30 rpc_server: Fix a typo
from b73c2e6 python/tests: improve samba-tool replicate --local test
https://git.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit e08110ece699eeb1b9ef688c92bf84c69a6fa5fc
Author: Ralph Boehme <slow at samba.org>
Date: Tue Jan 31 16:09:55 2017 +0100
s3/rpc_server/mdssvc: add attribute "kMDItemContentType"
Bug: https://bugzilla.samba.org/show_bug.cgi?id=12545
Signed-off-by: Ralph Boehme <slow at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
Autobuild-User(master): Jeremy Allison <jra at samba.org>
Autobuild-Date(master): Wed Feb 15 06:20:52 CET 2017 on sn-devel-144
commit 2ef3cb00930644b137bb86f856f000e9d4291891
Author: Volker Lendecke <vl at samba.org>
Date: Fri Jan 20 16:57:11 2017 +0100
lib: Avoid an "includes.h"
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit ec5f42fb2f81715bb84309cc223f72b53c5342b6
Author: Volker Lendecke <vl at samba.org>
Date: Tue Jan 24 16:17:31 2017 +0100
winbind: Fix a signed/unsigned mixup
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit ad15f5c0ca61f3dddc64f97d0c59f728adbd87e8
Author: Volker Lendecke <vl at samba.org>
Date: Tue Jan 24 21:17:38 2017 +0100
libsmb: Fix whitespace
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 5f2c6360bbf248051355eb0c1bac2ac0a3aca424
Author: Volker Lendecke <vl at samba.org>
Date: Thu Jan 26 12:51:24 2017 +0100
lib: Fix some whitespace
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 5a03c42af4945b11d80748649b97949e272bbd10
Author: Volker Lendecke <vl at samba.org>
Date: Thu Feb 9 18:43:46 2017 +0100
smbd: Fix some whitespace
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 68e1a64dc15a62037c2c77e1760b7064e391d2a1
Author: Volker Lendecke <vl at samba.org>
Date: Sat Feb 11 10:38:21 2017 +0100
auth3: Use NT_STATUS_EQUAL
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 9699c3873c82bdb99d569e2589a6465a0a349750
Author: Volker Lendecke <vl at samba.org>
Date: Mon Feb 13 10:14:24 2017 +0100
winbind: Fix a typo
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 02380ca3e75e5aae99f5024b4790e6e2bbdd8594
Author: Volker Lendecke <vl at samba.org>
Date: Wed Jan 18 12:58:19 2017 +0100
ctdb: Only build test_mutex_raw.c on Linux
This is pretty glibc on Linux specific. FreeBSD 11 also has
robust mutexes and can't build this.
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 9ab820d944bb16d2bcf629f616ef3001e78493ea
Author: Volker Lendecke <vl at samba.org>
Date: Thu Feb 9 19:13:21 2017 +0100
smbd: Fix some whitespace
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 44925832b1e326b85906496a2894ba22cf7b6dac
Author: Volker Lendecke <vl at samba.org>
Date: Wed Feb 8 15:19:54 2017 +0100
smbd: Make "create_file_sids" static
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
commit 2251c3052876eebfdccc416119576a56b54bdee7
Author: Volker Lendecke <vl at samba.org>
Date: Sun Jan 29 11:05:12 2017 +0000
rpc_server: Fix a typo
Signed-off-by: Volker Lendecke <vl at samba.org>
Reviewed-by: Jeremy Allison <jra at samba.org>
-----------------------------------------------------------------------
Summary of changes:
ctdb/wscript | 2 +-
source3/auth/auth.c | 2 +-
source3/lib/lsa.c | 4 ++-
source3/lib/winbind_util.c | 42 +++++++++++++--------------
source3/libsmb/trustdom_cache.c | 30 +++++++++----------
source3/modules/vfs_posixacl.c | 4 +--
source3/rpc_server/mdssvc/sparql_mapping.c | 5 ++++
source3/smbd/posix_acls.c | 8 +++--
source3/smbd/proto.h | 1 -
source3/winbindd/winbindd_cm.c | 2 +-
source3/winbindd/winbindd_dual_srv.c | 2 +-
source4/rpc_server/netlogon/dcerpc_netlogon.c | 3 +-
12 files changed, 57 insertions(+), 48 deletions(-)
Changeset truncated at 500 lines:
diff --git a/ctdb/wscript b/ctdb/wscript
index 13384c8..0233149 100644
--- a/ctdb/wscript
+++ b/ctdb/wscript
@@ -830,7 +830,7 @@ def build(bld):
ib_deps,
install_path='${CTDB_TEST_LIBEXECDIR}')
- if bld.env.HAVE_ROBUST_MUTEXES:
+ if bld.env.HAVE_ROBUST_MUTEXES and sys.platform.startswith('linux'):
bld.SAMBA_BINARY('test_mutex_raw',
source='tests/src/test_mutex_raw.c',
deps='pthread',
diff --git a/source3/auth/auth.c b/source3/auth/auth.c
index 833eae9..50d0188 100644
--- a/source3/auth/auth.c
+++ b/source3/auth/auth.c
@@ -229,7 +229,7 @@ NTSTATUS auth_check_ntlm_password(TALLOC_CTX *mem_ctx,
&server_info);
/* check if the module did anything */
- if ( NT_STATUS_V(result) == NT_STATUS_V(NT_STATUS_NOT_IMPLEMENTED) ) {
+ if (NT_STATUS_EQUAL(result, NT_STATUS_NOT_IMPLEMENTED)) {
DEBUG(10,("check_ntlm_password: %s had nothing to say\n", auth_method->name));
TALLOC_FREE(tmp_ctx);
if (user_info->flags & USER_INFO_LOCAL_SAM_ONLY) {
diff --git a/source3/lib/lsa.c b/source3/lib/lsa.c
index 6b9015a..1c24a42 100644
--- a/source3/lib/lsa.c
+++ b/source3/lib/lsa.c
@@ -19,7 +19,9 @@
init_lsa_ref_domain_list - adds a domain if it's not already in, returns index.
***************************************************************************/
-#include "includes.h"
+#include "replace.h"
+#include "lib/util/data_blob.h"
+#include "lib/util/time.h"
#include "libcli/security/dom_sid.h"
#include "librpc/gen_ndr/lsa.h"
#include "lsa.h"
diff --git a/source3/lib/winbind_util.c b/source3/lib/winbind_util.c
index b3ecac1..852929e 100644
--- a/source3/lib/winbind_util.c
+++ b/source3/lib/winbind_util.c
@@ -1,4 +1,4 @@
-/*
+/*
Unix SMB/CIFS implementation.
Winbind Utility functions
@@ -71,16 +71,16 @@ bool winbind_lookup_name(const char *dom_name, const char *name, struct dom_sid
{
struct wbcDomainSid dom_sid;
wbcErr result;
- enum wbcSidType type;
+ enum wbcSidType type;
result = wbcLookupName(dom_name, name, &dom_sid, &type);
if (result != WBC_ERR_SUCCESS)
return false;
memcpy(sid, &dom_sid, sizeof(struct dom_sid));
- *name_type = (enum lsa_SidType)type;
+ *name_type = (enum lsa_SidType)type;
- return true;
+ return true;
}
/* Call winbindd to convert sid to name */
@@ -95,7 +95,7 @@ bool winbind_lookup_sid(TALLOC_CTX *mem_ctx, const struct dom_sid *sid,
char *domain_name = NULL;
char *account_name = NULL;
- memcpy(&dom_sid, sid, sizeof(dom_sid));
+ memcpy(&dom_sid, sid, sizeof(dom_sid));
result = wbcLookupSid(&dom_sid, &domain_name, &account_name, &type);
if (result != WBC_ERR_SUCCESS)
@@ -103,7 +103,7 @@ bool winbind_lookup_sid(TALLOC_CTX *mem_ctx, const struct dom_sid *sid,
/* Copy out result */
- if (domain) {
+ if (domain) {
*domain = talloc_strdup(mem_ctx, domain_name);
}
if (name) {
@@ -111,16 +111,16 @@ bool winbind_lookup_sid(TALLOC_CTX *mem_ctx, const struct dom_sid *sid,
}
*name_type = (enum lsa_SidType)type;
- DEBUG(10, ("winbind_lookup_sid: SUCCESS: SID %s -> %s %s\n",
+ DEBUG(10, ("winbind_lookup_sid: SUCCESS: SID %s -> %s %s\n",
sid_string_dbg(sid), domain_name, account_name));
wbcFreeMemory(domain_name);
wbcFreeMemory(account_name);
- if ((domain && !*domain) || (name && !*name)) {
+ if ((domain && !*domain) || (name && !*name)) {
DEBUG(0,("winbind_lookup_sid: talloc() failed!\n"));
return false;
- }
+ }
return true;
@@ -142,11 +142,11 @@ bool winbind_sid_to_uid(uid_t *puid, const struct dom_sid *sid)
struct wbcDomainSid dom_sid;
wbcErr result;
- memcpy(&dom_sid, sid, sizeof(dom_sid));
+ memcpy(&dom_sid, sid, sizeof(dom_sid));
- result = wbcSidToUid(&dom_sid, puid);
+ result = wbcSidToUid(&dom_sid, puid);
- return (result == WBC_ERR_SUCCESS);
+ return (result == WBC_ERR_SUCCESS);
}
/* Call winbindd to convert uid to sid */
@@ -173,11 +173,11 @@ bool winbind_sid_to_gid(gid_t *pgid, const struct dom_sid *sid)
struct wbcDomainSid dom_sid;
wbcErr result;
- memcpy(&dom_sid, sid, sizeof(dom_sid));
+ memcpy(&dom_sid, sid, sizeof(dom_sid));
- result = wbcSidToGid(&dom_sid, pgid);
+ result = wbcSidToGid(&dom_sid, pgid);
- return (result == WBC_ERR_SUCCESS);
+ return (result == WBC_ERR_SUCCESS);
}
/* Call winbindd to convert gid to sid */
@@ -210,7 +210,7 @@ wbcErr wb_is_trusted_domain(const char *domain)
wbcFreeMemory(info);
}
- return result;
+ return result;
}
/* Lookup a set of rids in a given domain */
@@ -226,15 +226,15 @@ bool winbind_lookup_rids(TALLOC_CTX *mem_ctx,
enum wbcSidType *name_types = NULL;
struct wbcDomainSid dom_sid;
wbcErr ret;
- int i;
+ int i;
memcpy(&dom_sid, domain_sid, sizeof(struct wbcDomainSid));
ret = wbcLookupRids(&dom_sid, num_rids, rids,
&dom_name, &namelist, &name_types);
- if (ret != WBC_ERR_SUCCESS) {
+ if (ret != WBC_ERR_SUCCESS) {
return false;
- }
+ }
*domain_name = talloc_strdup(mem_ctx, dom_name);
*names = talloc_array(mem_ctx, const char*, num_rids);
@@ -249,7 +249,7 @@ bool winbind_lookup_rids(TALLOC_CTX *mem_ctx,
wbcFreeMemory(namelist);
wbcFreeMemory(name_types);
- return true;
+ return true;
}
/* Ask Winbind to allocate a new uid for us */
@@ -428,7 +428,7 @@ bool winbind_uid_to_sid(struct dom_sid *sid, uid_t uid)
bool winbind_sid_to_gid(gid_t *pgid, const struct dom_sid *sid)
{
- return false;
+ return false;
}
/* Call winbindd to convert gid to sid */
diff --git a/source3/libsmb/trustdom_cache.c b/source3/libsmb/trustdom_cache.c
index 330fd41..d78a28c 100644
--- a/source3/libsmb/trustdom_cache.c
+++ b/source3/libsmb/trustdom_cache.c
@@ -1,4 +1,4 @@
-/*
+/*
Unix SMB/CIFS implementation.
Trusted domain names cache on top of gencache.
@@ -99,7 +99,7 @@ static char* trustdom_cache_key(const char* name)
* @return true upon successful value storing or
* false if store attempt failed
**/
-
+
bool trustdom_cache_store(const char *name, const char *alt_name,
const struct dom_sid *sid, time_t timeout)
{
@@ -182,7 +182,7 @@ bool trustdom_cache_fetch(const char* name, struct dom_sid* sid)
/*******************************************************************
- fetch the timestamp from the last update
+ fetch the timestamp from the last update
*******************************************************************/
uint32_t trustdom_cache_fetch_timestamp( void )
@@ -195,7 +195,7 @@ uint32_t trustdom_cache_fetch_timestamp( void )
DEBUG(5, ("no timestamp for trusted domain cache located.\n"));
SAFE_FREE(value);
return 0;
- }
+ }
timestamp = atoi(value);
@@ -204,7 +204,7 @@ uint32_t trustdom_cache_fetch_timestamp( void )
}
/*******************************************************************
- store the timestamp from the last update
+ store the timestamp from the last update
*******************************************************************/
bool trustdom_cache_store_timestamp( uint32_t t, time_t timeout )
@@ -216,7 +216,7 @@ bool trustdom_cache_store_timestamp( uint32_t t, time_t timeout )
if (!gencache_set(TDOMTSKEY, value, timeout)) {
DEBUG(5, ("failed to set timestamp for trustdom_cache\n"));
return False;
- }
+ }
return True;
}
@@ -241,7 +241,7 @@ static void flush_trustdom_name(const char* key, const char *value, time_t timeo
void trustdom_cache_flush(void)
{
- /*
+ /*
* iterate through each TDOM cache's entry and flush it
* by flush_trustdom_name function
*/
@@ -349,7 +349,7 @@ done:
}
/********************************************************************
- update the trustdom_cache if needed
+ update the trustdom_cache if needed
********************************************************************/
#define TRUSTDOM_UPDATE_INTERVAL 600
@@ -364,8 +364,8 @@ void update_trustdom_cache( void )
time_t now = time(NULL);
int i;
- /* get the timestamp. We have to initialise it if the last timestamp == 0 */
- if ( (last_check = trustdom_cache_fetch_timestamp()) == 0 )
+ /* get the timestamp. We have to initialise it if the last timestamp == 0 */
+ if ( (last_check = trustdom_cache_fetch_timestamp()) == 0 )
trustdom_cache_store_timestamp(0, now+TRUSTDOM_UPDATE_INTERVAL);
time_diff = (int) (now - last_check);
@@ -387,20 +387,20 @@ void update_trustdom_cache( void )
/* get the domains and store them */
- if ( enumerate_domain_trusts(mem_ctx, lp_workgroup(), &domain_names,
+ if ( enumerate_domain_trusts(mem_ctx, lp_workgroup(), &domain_names,
&num_domains, &dom_sids)) {
for ( i=0; i<num_domains; i++ ) {
- trustdom_cache_store( domain_names[i], NULL, &dom_sids[i],
+ trustdom_cache_store( domain_names[i], NULL, &dom_sids[i],
now+TRUSTDOM_UPDATE_INTERVAL);
- }
+ }
} else {
/* we failed to fetch the list of trusted domains - restore the old
timestamp */
- trustdom_cache_store_timestamp(last_check,
+ trustdom_cache_store_timestamp(last_check,
last_check+TRUSTDOM_UPDATE_INTERVAL);
}
-done:
+done:
talloc_destroy( mem_ctx );
return;
diff --git a/source3/modules/vfs_posixacl.c b/source3/modules/vfs_posixacl.c
index f009fcc..aeadcbc 100644
--- a/source3/modules/vfs_posixacl.c
+++ b/source3/modules/vfs_posixacl.c
@@ -187,7 +187,7 @@ static bool smb_ace_to_internal(acl_entry_t posix_ace,
acl_free(puid);
break;
}
-
+
case SMB_ACL_GROUP: {
gid_t *pgid = (uid_t *)acl_get_qualifier(posix_ace);
if (pgid == NULL) {
@@ -230,7 +230,7 @@ static struct smb_acl_t *smb_acl_to_internal(acl_t acl, TALLOC_CTX *mem_ctx)
entry_id = ACL_NEXT_ENTRY;
- result->acl = talloc_realloc(result, result->acl,
+ result->acl = talloc_realloc(result, result->acl,
struct smb_acl_entry, result->count+1);
if (result->acl == NULL) {
TALLOC_FREE(result);
diff --git a/source3/rpc_server/mdssvc/sparql_mapping.c b/source3/rpc_server/mdssvc/sparql_mapping.c
index a3baf09..c71c7a5 100644
--- a/source3/rpc_server/mdssvc/sparql_mapping.c
+++ b/source3/rpc_server/mdssvc/sparql_mapping.c
@@ -133,6 +133,11 @@ const struct sl_attr_map *sl_attr_map_by_spotlight(const char *sl_attr)
.type = ssmt_type,
.sparql_attr = NULL,
},
+ {
+ .spotlight_attr = "kMDItemContentType",
+ .type = ssmt_type,
+ .sparql_attr = NULL,
+ },
/* Image metadata */
{
diff --git a/source3/smbd/posix_acls.c b/source3/smbd/posix_acls.c
index c8d2bb3..8187a8b 100644
--- a/source3/smbd/posix_acls.c
+++ b/source3/smbd/posix_acls.c
@@ -911,7 +911,9 @@ static int map_acl_perms_to_permset(connection_struct *conn, mode_t mode, SMB_AC
Function to create owner and group SIDs from a SMB_STRUCT_STAT.
****************************************************************************/
-void create_file_sids(const SMB_STRUCT_STAT *psbuf, struct dom_sid *powner_sid, struct dom_sid *pgroup_sid)
+static void create_file_sids(const SMB_STRUCT_STAT *psbuf,
+ struct dom_sid *powner_sid,
+ struct dom_sid *pgroup_sid)
{
uid_to_sid( powner_sid, psbuf->st_ex_uid );
gid_to_sid( pgroup_sid, psbuf->st_ex_gid );
@@ -3323,7 +3325,7 @@ static NTSTATUS posix_get_nt_acl_common(struct connection_struct *conn,
* would lead to usability problems under Windows: The Creator entries
* are only available in browse lists of directories and not for files;
* additionally the identity of the owning group couldn't be determined.
- * We therefore use those identities only for Default ACLs.
+ * We therefore use those identities only for Default ACLs.
*/
/* Create the canon_ace lists. */
@@ -3332,7 +3334,7 @@ static NTSTATUS posix_get_nt_acl_common(struct connection_struct *conn,
SMB_ACL_TYPE_ACCESS);
/* We must have *some* ACLS. */
-
+
if (count_canon_ace_list(file_ace) == 0) {
DEBUG(0,("get_nt_acl : No ACLs on file (%s) !\n", name));
goto done;
diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h
index 50ede9d..7ccb12a 100644
--- a/source3/smbd/proto.h
+++ b/source3/smbd/proto.h
@@ -762,7 +762,6 @@ void reply_pipe_read_and_X(struct smb_request *req);
/* The following definitions come from smbd/posix_acls.c */
-void create_file_sids(const SMB_STRUCT_STAT *psbuf, struct dom_sid *powner_sid, struct dom_sid *pgroup_sid);
uint32_t map_canon_ace_perms(int snum,
enum security_ace_type *pacl_type,
mode_t perms,
diff --git a/source3/winbindd/winbindd_cm.c b/source3/winbindd/winbindd_cm.c
index 4eff7a7..d8c894c 100644
--- a/source3/winbindd/winbindd_cm.c
+++ b/source3/winbindd/winbindd_cm.c
@@ -3332,7 +3332,7 @@ static NTSTATUS cm_connect_netlogon_transport(struct winbindd_domain *domain,
}
/****************************************************************************
-Open a LSA connection to a DC, suiteable for LSA lookup calls.
+Open a NETLOGON connection to a DC, suiteable for SamLogon calls.
****************************************************************************/
NTSTATUS cm_connect_netlogon(struct winbindd_domain *domain,
diff --git a/source3/winbindd/winbindd_dual_srv.c b/source3/winbindd/winbindd_dual_srv.c
index 49236cd..b0b38a6 100644
--- a/source3/winbindd/winbindd_dual_srv.c
+++ b/source3/winbindd/winbindd_dual_srv.c
@@ -601,7 +601,7 @@ NTSTATUS _wbint_LookupRids(struct pipes_struct *p, struct wbint_LookupRids *r)
enum lsa_SidType *types;
struct wbint_Principal *result;
NTSTATUS status;
- int i;
+ uint32_t i;
if (domain == NULL) {
return NT_STATUS_REQUEST_NOT_ACCEPTED;
diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c
index 15f0a77..afa9b1c 100644
--- a/source4/rpc_server/netlogon/dcerpc_netlogon.c
+++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c
@@ -837,7 +837,8 @@ static NTSTATUS dcesrv_netr_LogonSamLogon_check(const struct netr_LogonSamLogonE
This version of the function allows other wrappers to say 'do not check the credentials'
- We can't do the traditional 'wrapping' format completly, as this function must only run under schannel
+ We can't do the traditional 'wrapping' format completely, as this
+ function must only run under schannel
*/
static NTSTATUS dcesrv_netr_LogonSamLogon_base(struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx,
struct netr_LogonSamLogonEx *r, struct netlogon_creds_CredentialState *creds)
--
Samba Shared Repository
More information about the samba-cvs
mailing list