Changeset 618 for vendor/current/source3
- Timestamp:
- Aug 5, 2011, 7:52:23 AM (14 years ago)
- Location:
- vendor/current/source3
- Files:
-
- 19 edited
Legend:
- Unmodified
- Added
- Removed
-
vendor/current/source3/VERSION
r615 r618 26 26 SAMBA_VERSION_MAJOR=3 27 27 SAMBA_VERSION_MINOR=5 28 SAMBA_VERSION_RELEASE=1 028 SAMBA_VERSION_RELEASE=11 29 29 30 30 ######################################################## -
vendor/current/source3/configure
r597 r618 9622 9622 done 9623 9623 9624 for ac_header in sys/acl.h acl/libacl.h 9624 for ac_header in sys/acl.h acl/libacl.h sys/file.h 9625 9625 do : 9626 9626 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` … … 16330 16330 16331 16331 $as_echo "#define HAVE_STAT_DOS_FLAGS 1" >>confdefs.h 16332 16333 fi 16334 16335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can compile with __attribute__((destructor))" >&5 16336 $as_echo_n "checking whether we can compile with __attribute__((destructor))... " >&6; } 16337 if test "${samba_cv_function_attribute_destructor+set}" = set; then : 16338 $as_echo_n "(cached) " >&6 16339 else 16340 16341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16342 /* end confdefs.h. */ 16343 16344 __attribute__((destructor)) 16345 static void cleanup(void) { } 16346 16347 _ACEOF 16348 if ac_fn_c_try_compile "$LINENO"; then : 16349 samba_cv_function_attribute_destructor=yes 16350 fi 16351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 16352 16353 fi 16354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $samba_cv_function_attribute_destructor" >&5 16355 $as_echo "$samba_cv_function_attribute_destructor" >&6; } 16356 16357 if test x"$samba_cv_function_attribute_destructor" = xyes ; then 16358 16359 $as_echo "#define HAVE_FUNCTION_ATTRIBUTE_DESTRUCTOR 1" >>confdefs.h 16332 16360 16333 16361 fi -
vendor/current/source3/configure.in
r597 r618 1332 1332 fi 1333 1333 1334 AC_CACHE_CHECK([whether we can compile with __attribute__((destructor))], 1335 samba_cv_function_attribute_destructor, 1336 [ 1337 AC_COMPILE_IFELSE( 1338 [ 1339 __attribute__((destructor)) 1340 static void cleanup(void) { } 1341 ], 1342 samba_cv_function_attribute_destructor=yes) 1343 ]) 1344 1345 if test x"$samba_cv_function_attribute_destructor" = xyes ; then 1346 AC_DEFINE(HAVE_FUNCTION_ATTRIBUTE_DESTRUCTOR, 1, 1347 [whether we can compile with __attribute__((destructor))]) 1348 fi 1349 1334 1350 ##################################### 1335 1351 # needed for SRV lookups -
vendor/current/source3/include/config.h.in
r597 r618 707 707 /* Truncate extend */ 708 708 #undef HAVE_FTRUNCATE_EXTEND 709 710 /* whether we can compile with __attribute__((destructor)) */ 711 #undef HAVE_FUNCTION_ATTRIBUTE_DESTRUCTOR 709 712 710 713 /* Whether there is a __FUNCTION__ macro */ -
vendor/current/source3/include/version.h
r615 r618 2 2 #define SAMBA_VERSION_MAJOR 3 3 3 #define SAMBA_VERSION_MINOR 5 4 #define SAMBA_VERSION_RELEASE 1 05 #define SAMBA_VERSION_OFFICIAL_STRING "3.5.1 0"4 #define SAMBA_VERSION_RELEASE 11 5 #define SAMBA_VERSION_OFFICIAL_STRING "3.5.11" 6 6 #ifdef SAMBA_VERSION_VENDOR_FUNCTION 7 7 # define SAMBA_VERSION_STRING SAMBA_VERSION_VENDOR_FUNCTION -
vendor/current/source3/lib/smbldap.c
r414 r618 1094 1094 connect to the ldap server under system privilege. 1095 1095 ******************************************************************/ 1096 static int smbldap_connect_system(struct smbldap_state *ldap_state, LDAP * ldap_struct) 1097 { 1096 static int smbldap_connect_system(struct smbldap_state *ldap_state) 1097 { 1098 LDAP *ldap_struct = ldap_state->ldap_struct; 1098 1099 int rc; 1099 1100 int version; … … 1106 1107 if (!fetch_ldap_pw(&bind_dn, &bind_secret)) { 1107 1108 DEBUG(0, ("ldap_connect_system: Failed to retrieve password from secrets.tdb\n")); 1108 return LDAP_INVALID_CREDENTIALS; 1109 rc = LDAP_INVALID_CREDENTIALS; 1110 goto done; 1109 1111 } 1110 1112 smbldap_set_creds(ldap_state, false, bind_dn, bind_secret); … … 1152 1154 SAFE_FREE(ld_error); 1153 1155 ldap_state->num_failures++; 1154 return rc;1156 goto done; 1155 1157 } 1156 1158 … … 1167 1169 DEBUGADD(10, ("ldap_connect_system: LDAP server %s support paged results\n", 1168 1170 ldap_state->paged_results ? "does" : "does not")); 1171 done: 1172 if (rc != 0) { 1173 ldap_unbind(ldap_struct); 1174 ldap_state->ldap_struct = NULL; 1175 } 1169 1176 return rc; 1170 1177 } … … 1221 1228 } 1222 1229 1223 if ((rc = smbldap_connect_system(ldap_state, ldap_state->ldap_struct))) { 1224 ldap_unbind(ldap_state->ldap_struct); 1225 ldap_state->ldap_struct = NULL; 1230 if ((rc = smbldap_connect_system(ldap_state))) { 1226 1231 return rc; 1227 1232 } … … 1235 1240 if (ldap_state->event_context != NULL) { 1236 1241 ldap_state->idle_event = event_add_timed( 1237 ldap_state->event_context, NULL,1242 ldap_state->event_context, ldap_state, 1238 1243 timeval_current_ofs(SMBLDAP_IDLE_TIME, 0), 1239 1244 smbldap_idle_fn, ldap_state); … … 1259 1264 1260 1265 smbldap_delete_state(ldap_state); 1266 1267 TALLOC_FREE(ldap_state->idle_event); 1261 1268 1262 1269 DEBUG(5,("The connection to the LDAP server was closed\n")); … … 1746 1753 1747 1754 state->idle_event = event_add_timed( 1748 event_ctx, NULL,1755 event_ctx, state, 1749 1756 timeval_add(&now, SMBLDAP_IDLE_TIME, 0), 1750 1757 smbldap_idle_fn, … … 1772 1779 SAFE_FREE((*ldap_state)->bind_secret); 1773 1780 1774 TALLOC_FREE((*ldap_state)->idle_event); 1775 1776 *ldap_state = NULL; 1781 TALLOC_FREE(*ldap_state); 1777 1782 1778 1783 /* No need to free any further, as it is talloc()ed */ 1784 } 1785 1786 static int smbldap_state_destructor(struct smbldap_state *state) 1787 { 1788 smbldap_free_struct(&state); 1789 return 0; 1779 1790 } 1780 1791 … … 1802 1813 (*smbldap_state)->event_context = event_ctx; 1803 1814 1815 talloc_set_destructor(*smbldap_state, smbldap_state_destructor); 1804 1816 return NT_STATUS_OK; 1805 1817 } -
vendor/current/source3/librpc/gen_ndr/cli_wbint.c
r594 r618 2509 2509 struct tevent_context *ev, 2510 2510 struct rpc_pipe_client *cli, 2511 struct dom_sid *_domain_sid /* [in] [ref] */, 2511 2512 struct wbint_RidArray *_rids /* [in] [ref] */, 2512 2513 const char **_domain_name /* [out] [ref,charset(UTF8)] */, … … 2526 2527 2527 2528 /* In parameters */ 2529 state->orig.in.domain_sid = _domain_sid; 2528 2530 state->orig.in.rids = _rids; 2529 2531 … … 2615 2617 NTSTATUS rpccli_wbint_LookupRids(struct rpc_pipe_client *cli, 2616 2618 TALLOC_CTX *mem_ctx, 2619 struct dom_sid *domain_sid /* [in] [ref] */, 2617 2620 struct wbint_RidArray *rids /* [in] [ref] */, 2618 2621 const char **domain_name /* [out] [ref,charset(UTF8)] */, … … 2623 2626 2624 2627 /* In parameters */ 2628 r.in.domain_sid = domain_sid; 2625 2629 r.in.rids = rids; 2626 2630 -
vendor/current/source3/librpc/gen_ndr/cli_wbint.h
r594 r618 224 224 struct tevent_context *ev, 225 225 struct rpc_pipe_client *cli, 226 struct dom_sid *_domain_sid /* [in] [ref] */, 226 227 struct wbint_RidArray *_rids /* [in] [ref] */, 227 228 const char **_domain_name /* [out] [ref,charset(UTF8)] */, … … 232 233 NTSTATUS rpccli_wbint_LookupRids(struct rpc_pipe_client *cli, 233 234 TALLOC_CTX *mem_ctx, 235 struct dom_sid *domain_sid /* [in] [ref] */, 234 236 struct wbint_RidArray *rids /* [in] [ref] */, 235 237 const char **domain_name /* [out] [ref,charset(UTF8)] */, -
vendor/current/source3/librpc/gen_ndr/ndr_wbint.c
r594 r618 2077 2077 { 2078 2078 if (flags & NDR_IN) { 2079 if (r->in.domain_sid == NULL) { 2080 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); 2081 } 2082 NDR_CHECK(ndr_push_dom_sid(ndr, NDR_SCALARS, r->in.domain_sid)); 2079 2083 if (r->in.rids == NULL) { 2080 2084 return ndr_push_error(ndr, NDR_ERR_INVALID_POINTER, "NULL [ref] pointer"); … … 2105 2109 { 2106 2110 uint32_t _ptr_domain_name; 2111 TALLOC_CTX *_mem_save_domain_sid_0; 2107 2112 TALLOC_CTX *_mem_save_rids_0; 2108 2113 TALLOC_CTX *_mem_save_domain_name_0; … … 2112 2117 ZERO_STRUCT(r->out); 2113 2118 2119 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { 2120 NDR_PULL_ALLOC(ndr, r->in.domain_sid); 2121 } 2122 _mem_save_domain_sid_0 = NDR_PULL_GET_MEM_CTX(ndr); 2123 NDR_PULL_SET_MEM_CTX(ndr, r->in.domain_sid, LIBNDR_FLAG_REF_ALLOC); 2124 NDR_CHECK(ndr_pull_dom_sid(ndr, NDR_SCALARS, r->in.domain_sid)); 2125 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_domain_sid_0, LIBNDR_FLAG_REF_ALLOC); 2114 2126 if (ndr->flags & LIBNDR_FLAG_REF_ALLOC) { 2115 2127 NDR_PULL_ALLOC(ndr, r->in.rids); … … 2171 2183 ndr_print_struct(ndr, "in", "wbint_LookupRids"); 2172 2184 ndr->depth++; 2185 ndr_print_ptr(ndr, "domain_sid", r->in.domain_sid); 2186 ndr->depth++; 2187 ndr_print_dom_sid(ndr, "domain_sid", r->in.domain_sid); 2188 ndr->depth--; 2173 2189 ndr_print_ptr(ndr, "rids", r->in.rids); 2174 2190 ndr->depth++; -
vendor/current/source3/librpc/gen_ndr/wbint.h
r594 r618 277 277 struct wbint_LookupRids { 278 278 struct { 279 struct dom_sid *domain_sid;/* [ref] */ 279 280 struct wbint_RidArray *rids;/* [ref] */ 280 281 } in; -
vendor/current/source3/librpc/idl/wbint.idl
r594 r618 141 141 142 142 NTSTATUS wbint_LookupRids( 143 [in] dom_sid *domain_sid, 143 144 [in] wbint_RidArray *rids, 144 145 [out,string,charset(UTF8)] char **domain_name, -
vendor/current/source3/nmbd/nmbd_packets.c
r591 r618 1730 1730 if (subrec->nmb_sock < 0 || subrec->nmb_sock >= FD_SETSIZE) { 1731 1731 /* We have to ignore sockets outside FD_SETSIZE. */ 1732 continue; 1733 } 1734 FD_SET(subrec->nmb_sock,pset); 1735 sock_array[num++] = subrec->nmb_sock; 1736 *maxfd = MAX( *maxfd, subrec->nmb_sock); 1732 sock_array[num++] = -1; 1733 } else { 1734 FD_SET(subrec->nmb_sock,pset); 1735 sock_array[num++] = subrec->nmb_sock; 1736 *maxfd = MAX( *maxfd, subrec->nmb_sock); 1737 } 1737 1738 1738 1739 if (subrec->nmb_bcast < 0 || subrec->nmb_bcast >= FD_SETSIZE) { 1739 1740 /* We have to ignore sockets outside FD_SETSIZE. */ 1740 continue; 1741 } 1742 sock_array[num++] = subrec->nmb_bcast; 1743 FD_SET(subrec->nmb_bcast,pset); 1744 *maxfd = MAX( *maxfd, subrec->nmb_bcast); 1741 sock_array[num++] = -1; 1742 } else { 1743 sock_array[num++] = subrec->nmb_bcast; 1744 if (subrec->nmb_bcast != -1) { 1745 FD_SET(subrec->nmb_bcast,pset); 1746 *maxfd = MAX( *maxfd, subrec->nmb_bcast); 1747 } 1748 } 1745 1749 } 1746 1750 … … 1762 1766 if (subrec->dgram_sock < 0 || subrec->dgram_sock >= FD_SETSIZE) { 1763 1767 /* We have to ignore sockets outside FD_SETSIZE. */ 1764 continue; 1765 } 1766 FD_SET(subrec->dgram_sock,pset); 1767 sock_array[num++] = subrec->dgram_sock; 1768 *maxfd = MAX( *maxfd, subrec->dgram_sock); 1768 sock_array[num++] = -1; 1769 } else { 1770 FD_SET(subrec->dgram_sock,pset); 1771 sock_array[num++] = subrec->dgram_sock; 1772 *maxfd = MAX( *maxfd, subrec->dgram_sock); 1773 } 1769 1774 1770 1775 if (subrec->dgram_bcast < 0 || subrec->dgram_bcast >= FD_SETSIZE) { 1771 1776 /* We have to ignore sockets outside FD_SETSIZE. */ 1772 continue; 1773 } 1774 sock_array[num++] = subrec->dgram_bcast; 1775 if (subrec->dgram_bcast != -1) { 1776 FD_SET(subrec->dgram_bcast,pset); 1777 *maxfd = MAX( *maxfd, subrec->dgram_bcast); 1778 } 1779 } 1777 sock_array[num++] = -1; 1778 } else { 1779 sock_array[num++] = subrec->dgram_bcast; 1780 if (subrec->dgram_bcast != -1) { 1781 FD_SET(subrec->dgram_bcast,pset); 1782 *maxfd = MAX( *maxfd, subrec->dgram_bcast); 1783 } 1784 } 1785 } 1786 1787 SMB_ASSERT(count == num); 1780 1788 1781 1789 *listen_number = count; -
vendor/current/source3/nmbd/nmbd_subnetdb.c
r414 r618 56 56 void close_subnet(struct subnet_record *subrec) 57 57 { 58 if (subrec->nmb_sock != -1) { 59 close(subrec->nmb_sock); 60 subrec->nmb_sock = -1; 61 } 62 if (subrec->nmb_bcast != -1) { 63 close(subrec->nmb_bcast); 64 subrec->nmb_bcast = -1; 65 } 58 66 if (subrec->dgram_sock != -1) { 59 67 close(subrec->dgram_sock); 60 68 subrec->dgram_sock = -1; 61 69 } 62 if (subrec-> nmb_sock!= -1) {63 close(subrec-> nmb_sock);64 subrec-> nmb_sock= -1;70 if (subrec->dgram_bcast != -1) { 71 close(subrec->dgram_bcast); 72 subrec->dgram_bcast = -1; 65 73 } 66 74 -
vendor/current/source3/smbd/file_access.c
r414 r618 76 76 if (!CAN_WRITE(conn)) { 77 77 return False; 78 } 79 80 if (!lp_acl_check_permissions(SNUM(conn))) { 81 /* This option means don't check. */ 82 return true; 78 83 } 79 84 -
vendor/current/source3/smbd/negprot.c
r414 r618 383 383 return; 384 384 } 385 p += ret; 385 386 DEBUG(3,("not using SPNEGO\n")); 386 387 } else { -
vendor/current/source3/smbd/open.c
r597 r618 86 86 NTSTATUS status; 87 87 struct security_descriptor *sd = NULL; 88 89 if ((access_mask & DELETE_ACCESS) && !lp_acl_check_permissions(SNUM(conn))) { 90 *access_granted = access_mask; 91 92 DEBUG(10,("smbd_check_open_rights: not checking ACL " 93 "on DELETE_ACCESS on file %s. Granting 0x%x\n", 94 smb_fname_str_dbg(smb_fname), 95 (unsigned int)*access_granted )); 96 return NT_STATUS_OK; 97 } 88 98 89 99 status = SMB_VFS_GET_NT_ACL(conn, smb_fname->base_name, … … 2968 2978 /* Setting FILE_SHARE_DELETE is the hint. */ 2969 2979 2970 if (lp_acl_check_permissions(SNUM(conn)) 2971 && (create_disposition != FILE_CREATE) 2980 if ((create_disposition != FILE_CREATE) 2972 2981 && (access_mask & DELETE_ACCESS) 2973 2982 && (!(can_delete_file_in_directory(conn, smb_fname) || -
vendor/current/source3/smbd/server.c
r597 r618 279 279 } 280 280 281 DEBUG(0, ("Could not find child %d -- ignoring\n", (int)pid)); 281 /* not all forked child processes are added to the children list */ 282 DEBUG(1, ("Could not find child %d -- ignoring\n", (int)pid)); 282 283 } 283 284 -
vendor/current/source3/winbindd/winbindd_dual_srv.c
r594 r618 374 374 375 375 status = domain->methods->rids_to_names( 376 domain, talloc_tos(), &domain->sid, r->in.rids->rids,376 domain, talloc_tos(), r->in.domain_sid, r->in.rids->rids, 377 377 r->in.rids->num_rids, &domain_name, &names, &types); 378 378 if (!NT_STATUS_IS_OK(status)) { … … 389 389 390 390 for (i=0; i<r->in.rids->num_rids; i++) { 391 sid_compose(&result[i].sid, &domain->sid, r->in.rids->rids[i]); 391 sid_compose(&result[i].sid, r->in.domain_sid, 392 r->in.rids->rids[i]); 392 393 result[i].type = types[i]; 393 394 result[i].name = talloc_move(result, &names[i]); -
vendor/current/source3/winbindd/winbindd_lookuprids.c
r594 r618 24 24 struct winbindd_lookuprids_state { 25 25 struct tevent_context *ev; 26 struct dom_sid domain_sid; 26 27 const char *domain_name; 27 28 struct wbint_RidArray rids; … … 42 43 struct winbindd_lookuprids_state *state; 43 44 struct winbindd_domain *domain; 44 struct dom_sid sid;45 45 46 46 req = tevent_req_create(mem_ctx, &state, … … 56 56 DEBUG(3, ("lookuprids (%s)\n", request->data.sid)); 57 57 58 if (!string_to_sid(&s id, request->data.sid)) {58 if (!string_to_sid(&state->domain_sid, request->data.sid)) { 59 59 DEBUG(5, ("%s not a SID\n", request->data.sid)); 60 60 tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER); … … 62 62 } 63 63 64 domain = find_lookup_domain_from_sid(&s id);64 domain = find_lookup_domain_from_sid(&state->domain_sid); 65 65 if (domain == NULL) { 66 66 DEBUG(5, ("Domain for sid %s not found\n", 67 sid_string_dbg(&s id)));67 sid_string_dbg(&state->domain_sid))); 68 68 tevent_req_nterror(req, NT_STATUS_NO_SUCH_DOMAIN); 69 69 return tevent_req_post(req, ev); … … 84 84 85 85 subreq = rpccli_wbint_LookupRids_send( 86 state, ev, domain->child.rpccli, &state-> rids,87 &state-> domain_name, &state->names);86 state, ev, domain->child.rpccli, &state->domain_sid, 87 &state->rids, &state->domain_name, &state->names); 88 88 if (tevent_req_nomem(subreq, req)) { 89 89 return tevent_req_post(req, ev);
Note:
See TracChangeset
for help on using the changeset viewer.