1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

18464 Commits

Author SHA1 Message Date
Volker Lendecke
9985f25f00 r20496: Some changes to make Samba3 the RAW-OPEN test. Checking in to both 3_0 and
3_0_24 because I was explicitly asked to, although this needs close
review. Jeremy, I'm sure you will check this thoroughly :-)

In reply_open_and_X the separate "size" variable kills the calculation of the
SPARSE flag returned to the client in the attrib field. In getpathinfo we do
it correctly, and RAW-OPEN (correctly) complains about the difference.

Add the "set the write time" to mknew and create.

For trans2open we were missing the "ofun == 0" ->
NT_STATUS_OBJECT_NAME_COLLISION case, and we dropped the status returned in
favor of ACCESS_DENIED once too many.

Last change is a fix to trans2open: We were returning the attributes given by
the client, not the attributes of the new file.

Volker
(This used to be commit 84e6889632)
2007-10-10 12:16:53 -05:00
Gerald Carter
3063738c24 r20489: Missed patch ofthe forest_name patch for lookupname
(This used to be commit 25c4ebb55f)
2007-10-10 12:16:52 -05:00
Gerald Carter
b2317c0979 r20488: When joined to a child domain in a multi-domain/single domain tree,
the child domain cannot always resolve SIDs in sibling domains.
Windows tries to contact a DC in its own domain and then the root
domain in the forest.  This async changes makes winbindd's name2sid()
call do the same.
(This used to be commit 7b2bf0e5a6)
2007-10-10 12:16:52 -05:00
Gerald Carter
d3fc370fb9 r20487: Remove the unused dn2ad_canonical() call
(This used to be commit 86e6ae6a9f)
2007-10-10 12:16:52 -05:00
Gerald Carter
725cb5d7c9 r20486: Always upper case the "host/<sAMAccoutnName>" entry in the keytab file
so apps will know which one to look for,
(This used to be commit d4a5dc3ad5)
2007-10-10 12:16:52 -05:00
Gerald Carter
19f85cd9b9 r20485: Add select with a 10 second timeout when reading DSN update responses.
(This used to be commit cb6c6a49e2)
2007-10-10 12:16:52 -05:00
Volker Lendecke
b3ddd92ba2 r20482: Make us survive and activate RAW-CLOSE
(This used to be commit 471c6e6a21)
2007-10-10 12:16:52 -05:00
Volker Lendecke
6edd999dc1 r20479: Both remaining calls of can_delete called it with check_is_at_open==False,
remove that parameter.

Volker
(This used to be commit e51b764870)
2007-10-10 12:16:51 -05:00
Volker Lendecke
58b63b65fc r20478: Make us survive & activate RAW-UNLINK
(This used to be commit 4f0f917b34)
2007-10-10 12:16:51 -05:00
Volker Lendecke
2c1b3a0720 r20470: Jeremy, another one to check:
The only error path of can_delete() that we're interested in ntcreate&x is the
one of can_delete_file_in_directory(), so call that directly.

The only other one where we might get a NT_STATUS_ACCESS_DENIED is from the
lstat in can_delete, but this is covered later in the open_directory and
open_file_ntcreate calls. open_directory does a stat() in the open case which
also covers the (potential) symlink, and open_file_ntcreate does the open(2)
itself, so this should also work.

This makes can_delete() static to reply.c.

Volker
(This used to be commit d289037fdb)
2007-10-10 12:16:51 -05:00
Volker Lendecke
3c4342ddfb r20465: Get rid of a redundant !NT_STATUS_IS_OK(status)
(This used to be commit ff173995cf)
2007-10-10 12:16:51 -05:00
Volker Lendecke
495c361907 r20454: Get rid of a bogus variable that was only assigned but never read.
Jeremy, please check this.

Thanks,

Volker
(This used to be commit 2becbb9e5f)
2007-10-10 12:16:51 -05:00
Volker Lendecke
92d02f7afe r20451: Survive the first of the filter-tests (mkdir).
Add lots of TODOs :-)

Volker
(This used to be commit 0e953884a1)
2007-10-10 12:16:50 -05:00
Stefan Metzmacher
41440d483a r20448: Happy New Year!
metze
(This used to be commit 3260d21163)
2007-10-10 12:16:50 -05:00
Volker Lendecke
dbc231a1c6 r20443: Fix a compiler warning
(This used to be commit 19781d71fc)
2007-10-10 12:16:50 -05:00
Volker Lendecke
200bd10b32 r20442: Slight rewrite of the change notify infrastructure. This now survives the
first of the raw-notify subtests, the one-level test_notify_dir without any
flags around yet.

The tricky part was getting the data structures right, I hope the next tests
don't let that fall over.

fsp->notify is now by default NULL, meaning that nobody has issued a
changenotify call. This means nobody is interested in changes for this
directory.

If that has happened, notify_change_buf collects the changes if no current
request is outstanding, and it collects the requests if no change has happened
since the last request.

Happy New Year, somewhere on this planet it's already 2007 :-)

Volker

P.S: Jeremy, there's a question for you in smbd/files.c line 367.
(This used to be commit ce0ad24988)
2007-10-10 12:16:50 -05:00
Volker Lendecke
421ffdbb24 r20434: Revert an accidential commit
(This used to be commit fe122b07fa)
2007-10-10 12:16:50 -05:00
Volker Lendecke
165f5f3f40 r20433: Work in progress: Survive more of RAW-NOTIFY.
call_nt_transact_notify_change() is now sync if there are changes around.

A notify_message does a direct reply from within the message, so
process_pending_change_notify_queue is not needed anymore for samba-generated
events. Next step is to restructure the kernel-mechanisms to generate
messages.

Volker
(This used to be commit c813f71d00)
2007-10-10 12:16:49 -05:00
Volker Lendecke
ab7fc62edf r20432: Apply some const
(This used to be commit 22163fee59)
2007-10-10 12:16:49 -05:00
James Peach
17a8c7cb92 r20429: Restructure the libuuid API tests to handle the case where libuuid
is (effectively) in libc. Convert AC_LIBTESTFUNC to use the mystically
undocumented m4_ifval, which fixes some quoting problems when
providing shell code for the if-true and if-false branches.
(This used to be commit 5e1fbcc403)
2007-10-10 12:16:49 -05:00
James Peach
62382d19e9 r20428: Rename dns_open. This conflicts with the dns_open symbol in
libSystem on Mac OS X.
(This used to be commit 2117904f18)
2007-10-10 12:16:48 -05:00
James Peach
1beb6f6038 r20427: Rename dnp_open. This conflicts with the dns_open symbol in
libSystem on Mac OS X.
(This used to be commit 585ee7f31d)
2007-10-10 12:16:48 -05:00
Volker Lendecke
6d1607f4d7 r20424: No, we do not have to do that here :-)
(This used to be commit 49a463a97a)
2007-10-10 12:16:48 -05:00
Jeremy Allison
a77b3f38b9 r20412: Placeholder to remind me to write a torture test
for this error code.
Jeremy.
(This used to be commit 71b8686116)
2007-10-10 12:16:48 -05:00
Jeremy Allison
8e6390a160 r20411: Fix originally from SATOH Fumiyasu (slightly
modified). Ensure "hide unXXX" parameters don't
hide MSDFS links. Bug #3319.
Jeremy.
(This used to be commit e5466fffc2)
2007-10-10 12:16:47 -05:00
Andrew Bartlett
76cdf68ee9 r20403: Cleaning out my Samba 3.0 tree:
As discussed with jerry at the CIFS conf: overriding the
administrator's wishes from the krb5.conf has only every given me
segfaults.  We suggest leaving this up to the defaults from the
libraries anyway.

Andrew Bartlett
(This used to be commit 0b72c04906)
2007-10-10 12:16:47 -05:00
Andrew Bartlett
adb3a63943 r20402: Fix spelling: samba bug #4292 debian #402392
(This used to be commit e43aa4e03d)
2007-10-10 12:16:46 -05:00
Volker Lendecke
98c082489b r20394: This is a *VERY* early start of my work on notify.
Checking in because Jeremy was bugging me. Potentially this becomes quite
intrusive, I'm not sure if I should open a temporary branch for this.

Jeremy, Jerry, do you think 3_0 is the right place for this?

Volker
(This used to be commit bcf5c751cb)
2007-10-10 12:16:46 -05:00
Volker Lendecke
143a364d62 r20393: Debug level 1 is a bit excessive here
(This used to be commit 48798b5e57)
2007-10-10 12:16:46 -05:00
Stefan Metzmacher
8993ab2fcb r20389: this needs to be after AC_LIBREPLACE_BROKEN_CHECKS :-)
metze
(This used to be commit e5333d5628)
2007-10-10 12:16:46 -05:00
Stefan Metzmacher
ffa4ecae30 r20388: add the library that contains dlopen to the global LIBS as it was before
metze
(This used to be commit b2feeee748)
2007-10-10 12:16:46 -05:00
Stefan Metzmacher
e1d4e31c44 r20386: remove unneeded dlopen related configure checks and includes
this is done by libreplace...

this hopefully fixes the build on HPUX 11.00

metze
(This used to be commit eed50e1047)
2007-10-10 12:16:45 -05:00
Stefan Metzmacher
0b24e3d021 r20385: merge from samba4:
only try to find dlfcn.h if the dlopen symbol was found,
it hopefully fixes systems where dlfcn.h but no library with dlopen

metze
(This used to be commit b303e929d1)
2007-10-10 12:16:45 -05:00
Jeremy Allison
48c3f76b2e r20372: Make NTrename the same as SMBmv w.r.t. wildcards.
Jeremy.
(This used to be commit b8d5faac69)
2007-10-10 12:16:45 -05:00
Jeremy Allison
3430c1ddb8 r20371: In renames (via SMBmv) both src and dest can contain
wcards. I had forgotten this and had refused to allow
dest to contain wcards. We now pass all the normal
Samba4 smbtorture RAW-RENAME tests.
Jeremy
(This used to be commit 4183c1b49f)
2007-10-10 12:16:45 -05:00
Jeremy Allison
654f747e6d r20370: Now we've gone to the trouble of getting an NT status
from open_file_ntcreate make sure we return it on rename
error.
Jeremy.
(This used to be commit 633f02fb86)
2007-10-10 12:16:44 -05:00
Jeremy Allison
2703b3ac48 r20368: Fix valgrind report of uninitialized memory
being returned (false positive). Up debug
level on "open_directory" message.
Jeremy.
(This used to be commit 71a8b8863f)
2007-10-10 12:16:44 -05:00
Jeremy Allison
b26a9ad9df r20363: Fix any possible valgrind errors in srvstr_get_XX or srvstr_pull_XX
by ensuring we pass in a valid src_len (or zero when appropriate).
Volker is correct in that this is a *horrible* interface and he is
now free to generally clean it up everywhere :-). Go for it Volker !
Jeremy.
(This used to be commit cd991fb839)
2007-10-10 12:16:44 -05:00
Jeremy Allison
ae7526fd55 r20362: Fix valgrind issues where we may read params
before checking length. Found by Volker.
Jeremy.
(This used to be commit 683c5fce68)
2007-10-10 12:16:44 -05:00
Jeremy Allison
bc112cc46d r20361: Prevent strnlen_w reading beyond max. Valgrind
found by Volker.
Jeremy
(This used to be commit 08d551163c)
2007-10-10 12:16:44 -05:00
Volker Lendecke
8cd9636458 r20356: Consolidate the calls to parent_dirname() per open to one.
This involved passing the dirname as argument to a few routines instead of
calling parent_dirname() deep down.

Volker
(This used to be commit 7977fd7865)
2007-10-10 12:16:43 -05:00
Volker Lendecke
9f2807fc93 r20355: Fix some C++ warnings
(This used to be commit f103c301b1)
2007-10-10 12:16:43 -05:00
Volker Lendecke
96a2972bd2 r20345: Simplify call_nt_transact_create by using tmp_talloc_ctx()
(This used to be commit df6362baa0)
2007-10-10 12:16:43 -05:00
Volker Lendecke
e8e5c17f2e r20344: Move the calls to inherit_access_acls and change_owner_to_parent together.
Jeremy, I'm 100% sure you watch me closely here, I count on you :-)

Volker
(This used to be commit 02f85265f2)
2007-10-10 12:16:43 -05:00
Volker Lendecke
a67757ef9c r20343: Split change_owner_to_parent fd-based (for file opens) and a name-based (for
directory opens) routines.

Volker
(This used to be commit 4ca921d9aa)
2007-10-10 12:16:43 -05:00
Volker Lendecke
4e5a335c07 r20342: Move the lstat into mkdir_internal, for the FILE_OPEN case in open_directory
we want to follow symlinks.

Volker
(This used to be commit c20bdd219d)
2007-10-10 12:16:43 -05:00
Volker Lendecke
af1750934d r20340: Join vfs_MkDir to its only caller
(This used to be commit cce911780f)
2007-10-10 12:16:42 -05:00
Volker Lendecke
d0c6f9b728 r20339: Make mkdir_internal static to open.c
(This used to be commit 6dd0886b49)
2007-10-10 12:16:42 -05:00
Volker Lendecke
469b42c61f r20338: Restructure open_directory a bit. This gets rid of a race condition regarding
error messages: We relied upon a stat that a directory did not exist to later
on then do the mkdir or not. This does the mkdir directly and copes with a
potential error.

The second one is more important: It's possible with Samba 3 to do a
ntcreate&x with NTCREATEX_OPTIONS_DIRECTORY and we happily do a NT_STATUS_OK.

Also move up the use_nt_status() logic a bit. I think this does not belong
into the core routines, the smb server as such should take care of it.

Jeremy, do you think this should go to 3.0.24?

I'll update samba4torture when the build farm has picked up this checkin.

Volker
(This used to be commit 472fb11f49)
2007-10-10 12:16:42 -05:00
Volker Lendecke
57d11622b5 r20336: Fix some memleaks in trans2open and simplify trans2mkdir a bit: We now have
tmp_talloc_ctx().

Volker
(This used to be commit 165d28f03a)
2007-10-10 12:16:42 -05:00
Volker Lendecke
b596d6a111 r20335: Port oplock return logic from ntcreate&x to NT_TRANSACT_CREATE. Fixes parts of
raw-open.

Volker
(This used to be commit e4e766c092)
2007-10-10 12:16:42 -05:00
Volker Lendecke
81824507f6 r20334: Activate RAW-MKDIR
(This used to be commit 8f76914e01)
2007-10-10 12:16:41 -05:00
Volker Lendecke
fb93332b30 r20333: Fix a couple of Coverity errors in one run, this was a potential NULL dereference
(This used to be commit f9edfffeb5)
2007-10-10 12:16:41 -05:00
Jeremy Allison
c04b948750 r20330: And here's the fix for the parent winbindd crashing
after it's child died unexpectedly whilst the parent
was waiting for a reply. We need to clean up the request
we're not going to service, plus we still need to call
the continuation function with a "False" flag so it
can clean things up. Still testing this, but I think
I'm right.
Jeremy
(This used to be commit 9b04ac0c81)
2007-10-10 12:16:41 -05:00
Jeremy Allison
ad325a7905 r20329: Fix a winbindd crash bug. If someone pulls
the network cable out of the machine *exactly*
after the init_dc_connect() call in cm_connect_sam()
or cm_connect_lsa() call succeeded but before any
of the other calls fail, and they have debug level
10 set in the log, then we'd crash due to dereferencing
a now NULL pointer (conn->cli gets set to NULL when
the init_dc_connect() call called from cm_get_schannel_dcinfo()
fails). Yes, before you ask this *did* happen on a
customer site :-).
Jeremy.
(This used to be commit a0278a0cb0)
2007-10-10 12:16:41 -05:00
Volker Lendecke
6988778850 r20313: Make trans2_mkdir also go through open_directory for all the fancy inherit_acl
stuff & friends.

Survives raw-mkdir. I'll activate that tomorrow when all build farm machines
have picked up the changed samba4 torture test.

Volker
(This used to be commit 37e7a3f35f)
2007-10-10 12:16:41 -05:00
Volker Lendecke
f023f86709 r20312: Fix a memleak
(This used to be commit 20d3bc3549)
2007-10-10 12:16:40 -05:00
Volker Lendecke
f871861673 r20310: We've checked for EA's and support for them further up already.
Volker
(This used to be commit 9c00ce0bbc)
2007-10-10 12:16:40 -05:00
Günther Deschner
c1a05657b9 r20304: Smaller fixes for pam_winbind:
* fail on invalid credential flags in pam_sm_setcred
* parse config file for pam_sm_acct_mgmt and pam_sm_open_session

Guenther
(This used to be commit 2a428ac814)
2007-10-10 12:16:40 -05:00
Jeremy Allison
eeb14fcc94 r20296: If we're going to overwrite krb5.conf
only do it for our primary domain.
Jeremy.
(This used to be commit 61d31ce008)
2007-10-10 12:16:39 -05:00
Simo Sorce
c127486a84 r20290: Remove unused call
(This used to be commit 4920265c31)
2007-10-10 12:16:39 -05:00
Simo Sorce
ced5c1f9aa r20289: IDMAP is part of winbind but not the main process.
Make sure we route all request to remote DCs via the main process
so that IDMAP can correctly reuse DC connections and use the
async interface.

This fixes also idmap_nss so that it is able to resolve local
group names (requires patch on the samba dc earlier committed
to SAMBA_3_0 to make it resolve both the mapped and the unmapped
name).

Simo.
(This used to be commit 4297510f22)
2007-10-10 12:16:39 -05:00
Gerald Carter
8b0fce0b0c r20287: Allow a NULL sid when setting up the list of trusted domains.
(This used to be commit ccea7155bc)
2007-10-10 12:16:39 -05:00
Günther Deschner
bb9ca5025c r20279: Fix winbind segfault in winbindd_getsidaliases.
Jeremy: sidstr formerly could be NULL (when num_aliases was 0), since we
strdup here it needs to exist.

Guenther
(This used to be commit 29396a1bd8)
2007-10-10 12:16:39 -05:00
Günther Deschner
2d34900088 r20273: Map KRB5_KDCREP_SKEW to NT_STATUS_TIME_DIFFERENCE_AT_DC.
This gives much nicer error messages when failing to join due to clock
skew.

Guenther
(This used to be commit 5c5a761102)
2007-10-10 12:16:38 -05:00
Volker Lendecke
d6d17ea883 r20271: Fix the build
(This used to be commit c703d2ae1f)
2007-10-10 12:16:38 -05:00
Jeremy Allison
5d3456b22e r20270: Even with the dual daemon mode the parent winbindd
still needs to contact the DC's for non async requests
like enumerate users/groups etc. Now that online
DC detection is tied to async events we must enable
the processing of events in the main loop of winbindd.
Finally got rid of the last hard coded domain->initialized = 1
code in init_child_recv() - now all domain->initialized = True
gets done only in the connection manager code when either
we're online and have spoken to the DC or are offline and
we know we can't talk to the DC.
Jeremy.
(This used to be commit b3c98057fb)
2007-10-10 12:16:38 -05:00
Herb Lewis
e59e787b48 r20269: merge -r20264:20267 from SAMBA_3_0_24
more no previous prototype warnings
(This used to be commit 41be182f78)
2007-10-10 12:16:38 -05:00
Herb Lewis
84cd4d05e0 r20268: merge -r 20261:20263 from samba_3_0_24
get rid of previous prototype warnings
(This used to be commit 90265c83ff)
2007-10-10 12:16:38 -05:00
Volker Lendecke
9e41616b06 r20264: Two lines above this we just checked if (fsp->is_directory) ...
(This used to be commit 88ab54b3b7)
2007-10-10 12:16:37 -05:00
Herb Lewis
55ed1d5945 r20261: merge 20260 from samba_3_0_24
clean up a bunch of no previous prototype warnings
(This used to be commit c60687db11)
2007-10-10 12:16:37 -05:00
Volker Lendecke
920e1a3685 r20257: Hey, change_owner_to_parent is now static :-)
(This used to be commit 4090bc4bca)
2007-10-10 12:16:37 -05:00
Volker Lendecke
bc3787ab6e r20255: Activate BASE-SAMBA3ERROR in the build farm
(This used to be commit 7e0005c14b)
2007-10-10 12:16:37 -05:00
Günther Deschner
bd7b2c76f3 r20254: The pam_chauthtok needs to go through the async interface as well.
This fixes pam password changes in the online case.

Guenther
(This used to be commit 2d2de1ac27)
2007-10-10 12:16:37 -05:00
Volker Lendecke
f4f1814f8c r20253: Reduce some code duplication, make reply_mkdir go through the same code paths
ncreate does. This is a bit slower (about 10-20%), because it goes touches the
share mode db, but I think not having to call change_owner_to_parent and
friends in fewer places outweighs this. And, mkdir is not the way current
Windows boxes create directories, they do it via the ncreate call.

Volker
(This used to be commit ddae494fbe)
2007-10-10 12:16:37 -05:00
Simo Sorce
03b1445450 r20252: Revert back to const, but I have a fleble feeling we should go the ther way.
(This used to be commit 2048d49150)
2007-10-10 12:16:36 -05:00
Jeremy Allison
5115931024 r20250: If we've come from being globally offline we
don't have a check online event handler set.
We need to add one once we're been asked to
go back online as this is the only way to actually
go into the online state. Doh ! :-).
Jeremy.
(This used to be commit 5d36c4e031)
2007-10-10 12:16:36 -05:00
Günther Deschner
fb6d54dbab r20249: Fail when parsing invalid options in _pam_parse.
Guenther
(This used to be commit f6c9421abd)
2007-10-10 12:16:36 -05:00
Herb Lewis
911413e7d7 r20248: merge 20247 from samba_3_0_24
get rid of warning: value computed is not used
(This used to be commit ebe16589cb)
2007-10-10 12:16:36 -05:00
Herb Lewis
ef4c2088c5 r20245: merge 20244 from samba_3_0_24
get rid of more nested extern declarations warnings
(This used to be commit e9df051f52)
2007-10-10 12:16:36 -05:00
Simo Sorce
91626a4497 r20243: Make lookup_name resolve both the mapped and the real unix group name
(This used to be commit 7167e7b26a)
2007-10-10 12:16:35 -05:00
Simo Sorce
bb3cf31184 r20242: these are not really const as we set them in the function
(This used to be commit 6a0260fb04)
2007-10-10 12:16:35 -05:00
Günther Deschner
9291e634c0 r20241: Slightly improve readability of the pam_vsyslog replacement function.
Guenther
(This used to be commit 222320373f)
2007-10-10 12:16:35 -05:00
Günther Deschner
619671a718 r20240: Be a little more verbose about the credential flags when the debug flag
is set.

Guenther
(This used to be commit ecbab58826)
2007-10-10 12:16:35 -05:00
Günther Deschner
6fdbdfc86f r20239: Parse the configfile for pam_sm_setcred as well
(e.g. to get the debug flag)

Guenther
(This used to be commit 2c549f71f1)
2007-10-10 12:16:35 -05:00
James Peach
5bb49b08f3 r20237: Replace exit_server with exit_server_cleanly where appropriate. All
send_smb failures should be clean exits. All times when we exit as
a matter of policy should also be clean exits.
(This used to be commit d6382092e7)
2007-10-10 12:16:34 -05:00
James Peach
7d4449ffa0 r20235: Don't use realloc directly.
(This used to be commit 91e90f3bc4)
2007-10-10 12:16:34 -05:00
Volker Lendecke
0379e088dc r20229: Avoid a silly function call in mkdir_internal. None of the callers look at
errno, all go straight to ERROR_NT(status).

Volker
(This used to be commit 9d8b48c0ef)
2007-10-10 12:16:34 -05:00
Volker Lendecke
9933b596d1 r20228: Bring the calling conventions of inherit_access_acl and change_owner_to_parent
a bit closer together: Move the lp_inherit_perms() check into the callers.

Volker
(This used to be commit 0874093e5f)
2007-10-10 12:16:34 -05:00
Volker Lendecke
771f595693 r20227: Simplify logic in vfs_MkDir() a bit
(This used to be commit b24cf79e9e)
2007-10-10 12:16:33 -05:00
Volker Lendecke
f5b3bed84f r20218: Same fix as r20217 -- can we consolidate that duplicated code a bit?
(This used to be commit fdb310f579)
2007-10-10 12:16:33 -05:00
Volker Lendecke
34a0885df0 r20217: uid_t and gid_t are not necessarily 32 bit. In assignments we get an automatic
conversion, but not when we pass pointers down to other functions.

Simo, please check.

Volker
(This used to be commit 04845f600b)
2007-10-10 12:16:33 -05:00
Simo Sorce
b1de1a6eab r20216: Fix fallback code.
A reversed check made it impossile to fallback to the Unix Domain mapping code.
Also fix a potential use of a freed array.

Jerry,
my tests shows that this code now correctly handle the fallback to Unix Domain
when our Domain member is asked for a mapped group that has a unix name different
from the Windows name against a Samba DC and we do not use winbindd but share
users/groups by other means (ldap / sync of passwd and group files)

Immediate Fix would be to discuss if we should answer back when DOMAIN\unixgroup -> SID
is asked for, in the case the unixgroup name is mapped to a different name.
IE: DOMAIN\Domain Admins -> ntadmins

Currently if we are asked for "DOMAIN\Domain Admins" we return the dom admins SID
If we are asked for "DOMAIN\ntadmins we return "not found", but we may consider to
return the Domain admins SID in this case too.

Comments are welcome on this point!

Long term fix I think is the unixinfo pipe and of course an idmap_unixinfo moudle.

Simo.
(This used to be commit 07bdbb4c21)
2007-10-10 12:16:33 -05:00
Volker Lendecke
55e70f6987 r20215: Next step trying to fix the Solaris build.
I think "anonimous" is correctly spelled "anonymous". The Solaris compile is
referring to this as "anonymous" in line 814 of smbldap.c. Simo, please check.

Thanks,

Volker
(This used to be commit a77d8fa08e)
2007-10-10 12:16:33 -05:00
Volker Lendecke
0ef4aadb9b r20214: Fix a type-punned warning. Simo, Jerry, please check
(This used to be commit b459096a15)
2007-10-10 12:16:33 -05:00
Volker Lendecke
494a6e7658 r20212: Attempt to fix the Solaris build
(This used to be commit 902d81becb)
2007-10-10 12:16:32 -05:00
Volker Lendecke
e9a2b265e7 r20211: send_nt_replies does not need the inbuf arg
(This used to be commit ab45c50da3)
2007-10-10 12:16:32 -05:00
Volker Lendecke
ed7e7efd20 r20210: registry_fetch_values is not needed anymore, fix typo
(This used to be commit 77e556f4a3)
2007-10-10 12:16:32 -05:00
Volker Lendecke
5ee2748106 r20209: Fix two memleaks
(This used to be commit 92bc870768)
2007-10-10 12:16:32 -05:00
Jeremy Allison
a179d2f495 r20208: Change sprintf_append() never to use malloc,
but always use a talloc context.
Thanks to simo for pointing this out.
Jeremy.
(This used to be commit 437cb7c888)
2007-10-10 12:16:32 -05:00
Jeremy Allison
f0c7dc544b r20207: Fix a couple more places where extra_data was
being talloc'ed off the NULL context instead
of being malloced.
Jeremy.
(This used to be commit 47bdeb4efe)
2007-10-10 12:16:32 -05:00
Jeremy Allison
bf8988feaf r20206: Start cleaning up the talloc_ctx mess.
child->mem_ctx isn't actually used for
anything, so remove it.
Jeremy.
(This used to be commit a7f294b592)
2007-10-10 12:16:31 -05:00
Herb Lewis
2829b1db34 r20202: fix make clean
(This used to be commit 339c029521)
2007-10-10 12:16:31 -05:00
Herb Lewis
0decd48879 r20201: merge makefile changes from 3_0_24
(This used to be commit 3f8587fc6d)
2007-10-10 12:16:31 -05:00
Stefan Metzmacher
247e1667b0 r20197: merge talloc fixes from samba4:
- make most static functions inline
- handle NULL pointers in talloc_parent_chunk()
- use talloc_parent_chunk() in talloc_parent_name()
  to fix a bug found by the IBM checker

metze
(This used to be commit c718eb7a7c)
2007-10-10 12:16:31 -05:00
Günther Deschner
b49f0ae018 r20186: Fix winbind crash bug in WINBIND_GETGROUPS.
response_extra_sent() expects to free a malloced
extra_data.data while the add_XX_to_array functions all return talloced
memory now. Jeremy, please check.

Guenther
(This used to be commit 9f34c9f369)
2007-10-10 12:16:31 -05:00
Günther Deschner
69d4146042 r20183: Fix the build.
Guenther
(This used to be commit fe3ed63d29)
2007-10-10 12:16:31 -05:00
Jeremy Allison
3aec4cc13c r20181: Improve NT status to pam error mapping.
Jeremy.
(This used to be commit 794ebd8a84)
2007-10-10 12:16:30 -05:00
Jeremy Allison
63d8197453 r20180: Ensure that pam returns the correct error messages
when offline and or doing password changes.
Jeremy.
(This used to be commit 4a74c55384)
2007-10-10 12:16:30 -05:00
Jeremy Allison
728bee7ff3 r20179: Sync up with Samba4 - remove blank lines at the
end parsing a file.
Jeremy.
(This used to be commit ea8215935e)
2007-10-10 12:16:30 -05:00
Jeremy Allison
d29722e378 r20178: Ensure we allocate the intermediate trans structs
off conn->mem_ctx, not the null context so we can
safefy free everything on conn close. Should fix
possible memleak.
Jeremy.
(This used to be commit b33bde7b39)
2007-10-10 12:16:29 -05:00
Jeremy Allison
806daad510 r20174: If we're only going to call one handler per message
then terminate the traversal once we've done that.
Jeremy.
(This used to be commit da3d0b6234)
2007-10-10 12:16:29 -05:00
Gerald Carter
db7bf9a6b6 r20173: DNS update fixes:
* Fix DNS updates for multi-homed hosts
* Child domains often don't have an NS record in
  DNS so we have to fall back to looking up the the NS
  records for the forest root.
* Fix compile warning caused by mismatched 'struct in_addr'
  and 'in_addr_t' parameters called to DoDNSUpdate()
(This used to be commit 3486acd3c3)
2007-10-10 12:16:29 -05:00
Günther Deschner
3ff4f4410f r20171: Don't delete the krb5 credential if others still reference to it.
Guenther
(This used to be commit a1378979be)
2007-10-10 12:16:29 -05:00
Gerald Carter
d879aa8f36 r20170: Fix secure DNS updates to work against
Wnidows 2000 DNS which expects the TKEY payload to
be in the answer section and not in the additional
set of records (like Windows 2003 and the RFC).
(This used to be commit a3b6734fda)
2007-10-10 12:16:29 -05:00
Simo Sorce
35a3773a6d r20169: Support for fallback to legacy mapping code was not completely tested.
Add necessary fixes.
(This used to be commit 4a81ee9608)
2007-10-10 12:16:28 -05:00
Jeremy Allison
7f5fefb7bb r20165: Change messaging subsystem to only allow one message
per type - this is all we use right now and makes
re-entrancy problems with deleting handlers with
a message dispatch loop go away.
Jeremy.
(This used to be commit 2e9b6faeae)
2007-10-10 12:16:28 -05:00
Jeremy Allison
25f8970539 r20160: Fix long-standing (ie. from initial code I think) bug
in tdb message processing. If we're inside a dispatch
function and we delete our own handler we'd walk onto
the next pointer from a deleted memory block. Fixes
crash bug in winbindd (and goodness knows where else).
Jeremy.
(This used to be commit 27a4c11214)
2007-10-10 12:16:28 -05:00
Simo Sorce
1da72a1c3f r20155: revert, I misread
(This used to be commit 20aa6322ef)
2007-10-10 12:16:28 -05:00
Simo Sorce
7c5dba63a0 r20154: Fix nasty typo, hunting another bug
(This used to be commit bf8dc44cc2)
2007-10-10 12:16:28 -05:00
Simo Sorce
9b5354bea4 r20151: remove meaningless checks
(This used to be commit 33a55f0cfc)
2007-10-10 12:16:28 -05:00
Simo Sorce
25fe484101 r20150: better memory handling for some functions, make sure we don't
leak memory by using the wrong(long lived)  mem context
(This used to be commit a28cdd6e74)
2007-10-10 12:16:27 -05:00
Jeremy Allison
050534827f r20148: Forgot to merge. Ensure open_any_socket_out()
is safe from signals.
Jeremy.
(This used to be commit c264a0aa4a)
2007-10-10 12:16:27 -05:00
Jeremy Allison
6b232e8c1f r20146: Now online checks are fully async we can do them
every cache timeout times.
Jeremy.
(This used to be commit 5d364bc5cc)
2007-10-10 12:16:27 -05:00
Jeremy Allison
ebb8161e1c r20140: Make online/offline detection completely asynchronous.
Now I've done this I might be able to reduce the probe
timeout and reduce the backoff algorithm, going back
to checking every cache time seconds (5 mins by default),
as the parent or forked domain child will never block.
Jeremy.
(This used to be commit d0add5f946)
2007-10-10 12:16:27 -05:00
Jim McDonough
86a11183f7 r20136: Fix #4290. Properly compute time to password expiration in message from
pam_winbind.  Thanks to Andrew Benham <andrew.benham@thus.net>
(This used to be commit 0d03f51379)
2007-10-10 12:16:27 -05:00
Herb Lewis
8b4669c3c5 r20133: get rid of defined but not used warning - static function only used
inside the #ifdef HAVE_NATIVE_ICONV
(This used to be commit 43ab1d2ba5)
2007-10-10 12:16:27 -05:00
Herb Lewis
dc06fda6c7 r20132: get rid of defined but not used warning - static function only used
inside the #ifdef HAVE_KRB5
(This used to be commit c6cdf76c58)
2007-10-10 12:16:26 -05:00
Herb Lewis
6914b29daa r20131: get rid of a few no previous prototype warnings
(This used to be commit e710a7d39a)
2007-10-10 12:16:26 -05:00
Herb Lewis
791f48f167 r20124: clean up nested extern declaration warnings
(This used to be commit ac3eb7813e)
2007-10-10 12:16:26 -05:00
Jim McDonough
243b462b09 r20119: Update help info indicating how to use separators (forward slash only)
and properly use backslashes in "net ads join computername="
(This used to be commit cc26e2f9a1)
2007-10-10 12:16:26 -05:00
Simo Sorce
7165944469 r20118: Fix some more warnings
(This used to be commit b6db21ff65)
2007-10-10 12:16:26 -05:00
Simo Sorce
79416a5226 r20117: 1st Error in the merge
(This used to be commit 5e46c43a2e)
2007-10-10 12:16:25 -05:00
Simo Sorce
4225f9a4bd r20116: Start merging in the work done to create the new idmap subsystem.
Simo.
(This used to be commit 50cd8bffee)
2007-10-10 12:16:25 -05:00
Jeremy Allison
18f9156d96 r20110: Fix interaction between paranoid malloc checker
and lib/replace. Found by Herb - thanks !
Jeremy.
(This used to be commit 67c4d5e73f)
2007-10-10 12:16:25 -05:00
Jeremy Allison
25d6eaae8d r20098: Properly fix issues with create_token_from_username()
reported by James. Ensure that this function allocates
everything on the temporary context except the return
memory. Never call this with a null mem context, and
now use conn->mem_ctx instead in smbd/service.c.
Remove separate free functions for conn->ngroups
and conn->nt_user_token as they are now always
talloc'ed off the conn->mem_ctx. Future optimization
will be to remove conn->mem_ctx and make all objects
pointed to in the conn struct talloc'ed off conn itself.
Easy to free then :-).
Jeremy.
(This used to be commit f83b6de44f)
2007-10-10 12:16:24 -05:00
Jeremy Allison
af0f14e3a7 r20097: Ensure found_username is freed correctly when
talloced on the null context.
Jeremy.
(This used to be commit 2c59c4dddc)
2007-10-10 12:16:24 -05:00
Jeremy Allison
63609fbb04 r20090: Fix a class of bugs found by James Peach. Ensure
we never mix malloc and talloc'ed contexts in the
add_XX_to_array() and add_XX_to_array_unique()
calls. Ensure that these calls always return
False on out of memory, True otherwise and always
check them. Ensure that the relevent parts of
the conn struct and the nt_user_tokens are
TALLOC_DESTROYED not SAFE_FREE'd.
James - this should fix your crash bug in both
branches.
Jeremy.
(This used to be commit 0ffca7559e)
2007-10-10 12:16:24 -05:00
Jim McDonough
19ddef3dd9 r20089: Put gpfs acl function into vfs_gpfs module. Thanks to Gomati Mohanan
<gomati.mohanan@in.ibm.com>.

Also fix fields for sec_desc differences between 3.0 and 3.0.24 in
nfs4_acls.c.
(This used to be commit 3d6f387783)
2007-10-10 12:16:24 -05:00
Jeremy Allison
5ce139751b r20087: Ensure we clean up any random pending events we
may have inherited from our parent in the winbindd
forked child.
Jeremy.
(This used to be commit 0a1352f440)
2007-10-10 12:16:23 -05:00
Jeremy Allison
5be92d0d18 r20082: When fork_domain_child is forked when we're offline
the child inherits *all* active check_online timout handlers.
This is bad when it's not our domain (ie. BUILTIN).
Jeremy.
(This used to be commit 8d815ec4c1)
2007-10-10 12:16:23 -05:00
Volker Lendecke
ff61853fb3 r20069: Fix logic bug I introduced
(This used to be commit d935ecec98)
2007-10-10 12:16:23 -05:00
Volker Lendecke
97a00e7df8 r20063: Fix a missing protoype warning in freelistcheck.c
(This used to be commit 2fdfc54e7e)
2007-10-10 12:16:23 -05:00
Jeremy Allison
1c6de687f1 r20060: Fix the timout calculation.
Jeremy.
(This used to be commit 017be792f3)
2007-10-10 12:16:23 -05:00
Jeremy Allison
b59412e6bf r20058: Ensure we actually do the increasing time
calculation when in offline mode.
Jeremy.
(This used to be commit b7dc67ab2a)
2007-10-10 12:16:23 -05:00
Jeremy Allison
155083547a r20057: Attempt to fix connect timeouts when connected on
a network but not one on which any home DC's can
be found (hotel network problem). Still testing
but this is getting close.
Jeremy.
(This used to be commit 369c9e4138)
2007-10-10 12:16:23 -05:00
Volker Lendecke
4a1efb1abe r20054: Revert my changes, Simo promised to work on it :-)
(This used to be commit 4b5cf0c9cf)
2007-10-10 12:16:22 -05:00
Volker Lendecke
c0d74d11bc r20050: Remove a bogus NULL check, LTDB_OBJECTCLASS is a static string
(This used to be commit f64866a43f)
2007-10-10 12:16:22 -05:00
Volker Lendecke
8a20dd0ff1 r20049: Reformatting
(This used to be commit 75555ae1c8)
2007-10-10 12:16:22 -05:00
Volker Lendecke
66cd8c3078 r20048: Fix vfs_full_audit after Jims kernel_flock addition
(This used to be commit 4fe19e741f)
2007-10-10 12:16:22 -05:00
Volker Lendecke
91adcd0bae r20046: Add ldb_search_exp_fmt and port comment to 4
(This used to be commit 1fe41c96f5)
2007-10-10 12:16:22 -05:00
Volker Lendecke
5b1f85a832 r20037: Reduce code size slightly by shuffling stuff around
(This used to be commit 0742faaacd)
2007-10-10 12:16:22 -05:00
Volker Lendecke
1710dd1fe2 r20036: Merge ldb_search_exp_fmt -- Thanks simo
(This used to be commit fa6fa1268b)
2007-10-10 12:16:21 -05:00
Jeremy Allison
490e3205bc r20035: Fix obvious horrible bug in falling back to MS-RPC
methods.
Jeremy.
(This used to be commit 7ac4ae4b51)
2007-10-10 12:16:21 -05:00
Volker Lendecke
2494868ffb r20020: Arglll... eventlogadm links against reg_db but not the rest of the registry
stuff. Revert the last change.

This needs better fixing.

Volker
(This used to be commit ad1e00430b)
2007-10-10 12:16:21 -05:00
Volker Lendecke
61bd0c8e45 r20019: Replace one set of tricky code by calls to another set of tricky code:
Initializing the reg_db now uses reg_createkey and reg_setvalue.

Volker
(This used to be commit cab5ccbbe4)
2007-10-10 12:16:21 -05:00
Volker Lendecke
b0a6049391 r20018: Fix a memleak in reg_createkey
(This used to be commit 281640823b)
2007-10-10 12:16:21 -05:00
Volker Lendecke
b676097927 r20017: Make srvsvc_NetShareAdd & friends take care of registry shares
(This used to be commit fc29a283cc)
2007-10-10 12:16:21 -05:00
Volker Lendecke
4a272ef0a8 r20016: Add two utility functions for easy opening/creating registry keys
(This used to be commit ad22a46718)
2007-10-10 12:16:20 -05:00
Volker Lendecke
fe34827ffd r20015: We have to zero out handle on key_close, otherwise the NT4 regedit will re-use the handle
(This used to be commit 0afd696f88)
2007-10-10 12:16:20 -05:00
Volker Lendecke
7299dc8b54 r20014: Ouch.... "res" is not a flag here, it is the service number...
(This used to be commit a4862f48d0)
2007-10-10 12:16:20 -05:00
Volker Lendecke
c6597384ba r20013: Fix segfaults: parm_error is a unique in/out ptr
(This used to be commit 0104371dd6)
2007-10-10 12:16:20 -05:00
Volker Lendecke
3f1978c059 r20012: Reformatting
(This used to be commit b32c65cb62)
2007-10-10 12:16:20 -05:00
Volker Lendecke
760056ec8d r20007: Fix a const warning just introduced
(This used to be commit 3da37287ca)
2007-10-10 12:16:19 -05:00
Volker Lendecke
fc030c313f r20006: Convert the registry shares to use the new API
(This used to be commit 66e889bbab)
2007-10-10 12:16:19 -05:00
Volker Lendecke
9690500e57 r20005: reg_open_path should become the replacement for regkey_open_internal.
(This used to be commit a6039eb46c)
2007-10-10 12:16:19 -05:00
Volker Lendecke
1a66ed34cd r20004: Remove a const, "name" is allocated anyway
(This used to be commit dc0300ec70)
2007-10-10 12:16:19 -05:00
Volker Lendecke
38cc572b1e r20003: Fix error message
(This used to be commit de05358351)
2007-10-10 12:16:19 -05:00
Volker Lendecke
d5e4b3bea8 r20001: Fix bug 4273, thanks to Pascal Terjan
(This used to be commit a2f5c92918)
2007-10-10 12:16:18 -05:00
Jeremy Allison
61ea96ec79 r19993: Fix the problem with Linux clients requesting O_WRONLY
on write-only files. Jim please check. Should not affect
Windows clients - I ensured all the relevent Samba4
torture tests still pass.
Jeremy.
(This used to be commit 6df3cac44f)
2007-10-10 12:16:18 -05:00
Paul Green
4eb9dda8a7 r19992: Add support to the tdb Makefile.in for executable extensions and for
separately specifying CPPFLAGS and LDFLAGS.
(This used to be commit 8c36f1a745)
2007-10-10 12:16:18 -05:00
Volker Lendecke
ecf90c495e r19991: Sorry for this 2000-liner...
The main thing here is a rewrite of srv_winreg_nt.c. The core functionality
has moved to registry/reg_api.c which is then usable by the rest of Samba as
well.

On that way it fixes creating keys with more than one element in the
path. This did not work before.

Two things that sneaked in (sorry :-) is the change of some routines from
NTSTATUS to WERROR the removed "parent" argument to regkey_open_internal.

Volker
(This used to be commit fea52801de)
2007-10-10 12:16:18 -05:00
Volker Lendecke
e57de5730c r19990: Fix comment
(This used to be commit 8b3d860f27)
2007-10-10 12:16:18 -05:00
Simo Sorce
dc2ed4c830 r19986: ooops
(This used to be commit 97f150fbbb)
2007-10-10 12:16:17 -05:00
Simo Sorce
c81c8cb4a7 r19984: Must have been drunk yesterday.
Freeing memctx is all we need, fix double free stupidity
(This used to be commit 2a7454959e)
2007-10-10 12:16:17 -05:00
Stefan Metzmacher
d908a897ed r19982: From Michael Adam (ma@sernet.de) (thanks!:-)
Metze: as noted by "shattered" and discussed on the irc,
  here is a patch to lib/sysquotas_linux.c replacing some
  "get"s by "set"s. The other lib/sysquotas*.c files look
  ok to me. But in the linux variant, the problem is not
  in the actual call of quotactl but in the preparation of
  the respective "D" structs. This makes the difference
  between the get and set calls for SMB_USER_FS_QUOTA_TYPE
  and SMB_GROUP_FS_QUOTA_TYPE.

metze
(This used to be commit d303cc7e62)
2007-10-10 12:16:17 -05:00
Simo Sorce
cb0402c2d3 r19980: Implement pam account stack checks when obey pam restrictions is true.
It was missing for security=server/domain/ads

Simo.
(This used to be commit 550f651499)
2007-10-10 12:16:17 -05:00
Simo Sorce
ef8d6bf5f7 r19979: Fix memleak on pw and change talloc_destroy to TALLOC_FREE for mem_ctx
(This used to be commit defa0a352b)
2007-10-10 12:16:17 -05:00
Volker Lendecke
e2bebe4865 r19978: More "net sam policy" improvements. Thanks to Karolin Seeger <ks@sernet.de>
Volker
(This used to be commit fde042f29e)
2007-10-10 12:16:17 -05:00
Gerald Carter
0d38f8af39 r19977: * Fix a crash in the secure DNS update code. Don't free
the host_principal memory while it is still being referenced
  by the gss code.
(This used to be commit 7a5a12e892)
2007-10-10 12:16:16 -05:00
Jeremy Allison
4c98afb2de r19975: Deal with 2 keytypes I messed previously (DR/DE).
Fix code that mistakenly assumed tdb_traverse
returned 0 or -1, it actually returns -1 or the
number of entries traversed. Add a static as another
way to return the bad cache value.
Jeremy.
(This used to be commit 5266a70ae9)
2007-10-10 12:16:16 -05:00
Jeremy Allison
913222d76a r19974: Add freelist check for cache. Fix testing of entry
names (all except SEQNUM are *not* null terminated
strings).
Jeremy.
(This used to be commit bcb68260ba)
2007-10-10 12:16:16 -05:00
Volker Lendecke
575845ccbe r19963: Add 'registry shares = yes' and registry key security descriptors.
(This used to be commit 6cab254c49)
2007-10-10 12:16:16 -05:00
James Peach
3fda843ac1 r19962: Revert bogus change in r19961. In future I will check configure.in
as well as Makefile.in :(
(This used to be commit 5d000fed59)
2007-10-10 12:16:16 -05:00
James Peach
1b25dd38c7 r19961: Remove VARDIR. Nothing is ever installed into this, so there's no
need to create it.
(This used to be commit f440efd961)
2007-10-10 12:16:15 -05:00
Jeremy Allison
cc13e21dbe r19959: Allow tdb to be built standalone in Samba3.
Add code to check for loops in the free list.
Should help us validate tdb's against corruption.
Jeremy.
(This used to be commit f8e7386773)
2007-10-10 12:16:15 -05:00
Jeremy Allison
2941b044b3 r19958: Add check for WINBIND_OFFLINE key.
Jeremy.
(This used to be commit 270e84db6d)
2007-10-10 12:16:15 -05:00
Jeremy Allison
ed34ffb147 r19957: Initial framework to make winbindd robust
against tdb corruption. Needs fleshing out
(and I forgot one record type) and needs helpful
suggestion from Volker to validate freelist,
but should give an idea of how this will look.
Jeremy.
(This used to be commit 8eb53f74e4)
2007-10-10 12:16:15 -05:00
Volker Lendecke
5893c0215d r19950: talloc_destroy is replaced these days
(This used to be commit b6bf2e4267)
2007-10-10 12:16:15 -05:00
Volker Lendecke
4a42371c20 r19948: Fix a memleak
(This used to be commit fd429c8c06)
2007-10-10 12:16:15 -05:00
Volker Lendecke
1c91cca86e r19947: Change regkey_open_internal to take the parent key and a talloc_ctx as
arguments. This also replaces regkey_close_internal by TALLOC_FREE.

Volker
(This used to be commit a177bbb2d5)
2007-10-10 12:16:14 -05:00
Volker Lendecke
443421828a r19946: in SetKeySec, sd is just a [in,ref] ptr
(This used to be commit 38a88ed5d7)
2007-10-10 12:16:14 -05:00
Volker Lendecke
d746c3b781 r19945: Fix a segfault -- lookup_rids needs to init the names even on failure
(This used to be commit eba404e668)
2007-10-10 12:16:14 -05:00
Volker Lendecke
dd813b6b29 r19944: Fix from Don Watson -- thanks
(This used to be commit c27e48594a)
2007-10-10 12:16:12 -05:00
Volker Lendecke
817151c87f r19943: Fix bug 4267 -- Thanks to David!
(This used to be commit 714971b34a)
2007-10-10 12:16:12 -05:00
Volker Lendecke
1c2ed58302 r19942: Fix Coverity id 333, a dereference before a NULL check.
Metze, you wanted to port talloc_get_type_abort() to 4. Should I just use it
in 3-ldb?

Volker
(This used to be commit ba0df1c915)
2007-10-10 12:16:12 -05:00
James Peach
760c7a6534 r19941: One copy of this code should be sufficient.
(This used to be commit 493ba681e5)
2007-10-10 12:16:11 -05:00
Gerald Carter
e6467907ed r19939: ,fix compile warning about unused functions when not using heimdal
(This used to be commit f53983079b)
2007-10-10 12:16:11 -05:00
Jeremy Allison
fb1430d6c9 r19936: Patch from Kai Blin <kai.blin@gmail.com> to
match Windows NTLMSSP flags.
Jeremy.
(This used to be commit 786318f84b)
2007-10-10 12:16:11 -05:00
Stefan Metzmacher
762b86ff0d r19935: always use discard_const_p() in lib/ldb/
metze
(This used to be commit 4a5da57306)
2007-10-10 12:16:11 -05:00
Volker Lendecke
15974508e8 r19932: Add some const
(This used to be commit be3c444c37)
2007-10-10 12:16:11 -05:00
Volker Lendecke
f1d492d11f r19930: Revert the winreg idl changes. At least enumkey does not work anymore today.
With more than 5 different trees I can't swear that I did test this properly
yesterday. Sorry for the noise.

Volker
(This used to be commit 978a6196bf)
2007-10-10 12:16:10 -05:00
Volker Lendecke
7ef185fae7 r19929: Fix indentation
(This used to be commit 2369ad0852)
2007-10-10 12:16:10 -05:00
Volker Lendecke
985248b638 r19928: Fix klokwork id 4509, 4573, 4574.
(This used to be commit c004d04181)
2007-10-10 12:16:10 -05:00
Volker Lendecke
78a0932145 r19927: Fix klokwork ID 4702
(This used to be commit 820a64af25)
2007-10-10 12:16:10 -05:00
Gerald Carter
16a076ae74 r19921: Add license and copyright info
(This used to be commit a3e1682ba3)
2007-10-10 12:16:10 -05:00
Volker Lendecke
8e8821b1da r19919: Convert winreg_EnumKey to use ref ** instead of a unique *.
Volker
(This used to be commit b714b51884)
2007-10-10 12:16:10 -05:00
Volker Lendecke
4a361ffd7f r19918: Convert winreg_CreateKey to use a ref ** instead of a unique *. W2k3 can still
create keys on Samba and vice versa.

Jelmer, please check.

Thanks,

Volker
(This used to be commit 1b460d6cdf)
2007-10-10 12:16:09 -05:00
Volker Lendecke
847644bdac r19917: Fix warnings
(This used to be commit cf4309b904)
2007-10-10 12:16:09 -05:00
Volker Lendecke
fb5d4f9c86 r19916: Fix some c++ warnings
(This used to be commit fb5bcb826e)
2007-10-10 12:16:09 -05:00
Volker Lendecke
2d6e409dc2 r19915: Fix two type-punned warnings
(This used to be commit f1266475da)
2007-10-10 12:16:09 -05:00
Volker Lendecke
f57cd1f63c r19914: The "default" value with the name "" need different 0-length treatment as the
other StringBufs, otherwise clicking on a key with this value being set leads
to regedit.exe on w2k3 chew all memory.
(This used to be commit b148cde7f3)
2007-10-10 12:16:09 -05:00
Volker Lendecke
213bc9d440 r19913: Fix a const warning
(This used to be commit a660993d14)
2007-10-10 12:16:08 -05:00
Volker Lendecke
b189e6d76e r19912: Move the subkey cache to srv_winreg_nt.c
(This used to be commit 01a53590a6)
2007-10-10 12:16:08 -05:00
Volker Lendecke
2685e167fa r19900: Fix klokwork ID 3148, 3149
(This used to be commit 1f3e20ef39)
2007-10-10 12:16:08 -05:00
Volker Lendecke
a12fb3afdd r19899: Fix some C++ warnings and klokwork ID 3147
(This used to be commit c5e041661e)
2007-10-10 12:16:08 -05:00
Volker Lendecke
ca3300cbd1 r19898: Fix klokwork ids 3127, 3128, 3129, 3130
(This used to be commit 3250d20d27)
2007-10-10 12:16:07 -05:00
Volker Lendecke
f6dece8b4d r19896: Fix klokwork id 2279
(This used to be commit 558a13a755)
2007-10-10 12:16:07 -05:00
Volker Lendecke
f494d7d31f r19895: Fix klokwork id 2278
(This used to be commit 8ccff6a4dd)
2007-10-10 12:16:07 -05:00
Volker Lendecke
40dc09e009 r19894: Fix klokwork id 2192
(This used to be commit 4b075f347b)
2007-10-10 12:16:06 -05:00
Volker Lendecke
7968602097 r19893: Fix klokwork id 2191
(This used to be commit a301a4a12d)
2007-10-10 12:16:05 -05:00
Volker Lendecke
7230ce8cd0 r19892: Fix klokwork id 2190
(This used to be commit 235e8c9653)
2007-10-10 12:16:05 -05:00
Volker Lendecke
76b2e7ba13 r19891: Fix klokwork id 2189
(This used to be commit b6933c3043)
2007-10-10 12:16:05 -05:00
Volker Lendecke
d128defd31 r19890: Fix klokwork ID 2188
(This used to be commit 4d44388929)
2007-10-10 12:16:04 -05:00
Volker Lendecke
433869019b r19889: Fix klokwork ID 2187
(This used to be commit 1bd660fb91)
2007-10-10 12:16:04 -05:00
Volker Lendecke
2a0e64e691 r19883: Fix bug 4248 -- thanks to Pascal Terjan :-)
(This used to be commit 66c20f2592)
2007-10-10 12:16:04 -05:00
James Peach
60936146d0 r19873: Make sure we are privileged when doing DMAPI operations on systems
that don't have capability support. Patch by J Raynor <raynorj@mn.rr.com>.
(This used to be commit 53fe047f35)
2007-10-10 12:16:03 -05:00
Volker Lendecke
015534e254 r19872: Move the value cache to srv_winreg_nt.c. Fix some minor issues found while
playing with regedit.exe.

Volker
(This used to be commit 81bd816fa2)
2007-10-10 12:16:03 -05:00
Volker Lendecke
3f62a1a3eb r19867: Introduce struct regkey_info in srv_winreg_nt.c to be able to re-add the
QueryValue and later the QueryKey cache independent of the backend.

Volker
(This used to be commit 0ed3a21fcc)
2007-10-10 12:16:03 -05:00
Volker Lendecke
6b0819e96c r19860: Streamline _winreg_QueryValue a bit. We've been pushing around memory
considerably here.

This temporarily removes a cache for the tdb based registry, I'll re-add that
in srv_winreg_nt.c in the next step.

This fixes creating/renaming values from the windows regedit.exe, as "New
Value #1" was not entering the cache after being created.

Volker
(This used to be commit c8c81f0e86)
2007-10-10 12:16:03 -05:00
Volker Lendecke
fb904d2299 r19858: Fix a memleak, add a const
(This used to be commit ed4dc40512)
2007-10-10 12:16:03 -05:00
Volker Lendecke
969a7faa7c r19853: Update a link
(This used to be commit ce44158dde)
2007-10-10 12:16:02 -05:00
James Peach
e2166a9fee r19851: Disable gcc PIE options on Darwin.
(This used to be commit 23795be8b4)
2007-10-10 12:16:02 -05:00
Jelmer Vernooij
19d7a9c315 r19849: Fix compilation after idl changes.
(This used to be commit b7f22408e9)
2007-10-10 12:16:02 -05:00
Jelmer Vernooij
4d708dfd2c r19848: Sync with Samba4 - no top-level unique pointers.
(This used to be commit 75515c5fda)
2007-10-10 12:16:02 -05:00
Volker Lendecke
7a19259051 r19841: Wrap regdb_store_keys and regdb_store_values in tdb transactions
(This used to be commit 5ec7379220)
2007-10-10 12:16:01 -05:00
Volker Lendecke
ca70f53930 r19840: Fix an uninitialized variable
(This used to be commit c4b5e8c7a0)
2007-10-10 12:16:01 -05:00
Volker Lendecke
9e29e5d2b8 r19839: Fix the build, we are not there yet :-)
(This used to be commit ff4123c8f2)
2007-10-10 12:16:01 -05:00
Volker Lendecke
45111ff1cb r19838: We have to delete the value record as well, otherwise the old values pop up
again if the key is re-created.

Volker
(This used to be commit f722f3341f)
2007-10-10 12:16:01 -05:00
Volker Lendecke
aad7194999 r19837: Some reformatting (Jerry, I hope you do not mind
(This used to be commit 6639f8c119)
2007-10-10 12:16:01 -05:00
Volker Lendecke
b724a28019 r19835: Some net sam policy improvements.
Thanks to Karolin Seeger <ks@sernet.de>

Volker
(This used to be commit 2091018a53)
2007-10-10 12:16:01 -05:00
Volker Lendecke
45fcd0f0b7 r19828: Add a helper function to pull *and* unparse local registry values
(This used to be commit 969eb9cda6)
2007-10-10 12:16:00 -05:00
Volker Lendecke
334c868b83 r19827: Move registry_push/pull_value to lib/util_reg.c
(This used to be commit 3047a4b92c)
2007-10-10 12:16:00 -05:00
Jim McDonough
807c50858f r19826: Fix typo
(This used to be commit fa656ce34e)
2007-10-10 12:16:00 -05:00
Volker Lendecke
6fad55ff89 r19825: To create a key, smbd also needs read privs assigned
(This used to be commit b2866b1318)
2007-10-10 12:16:00 -05:00
Volker Lendecke
c895111579 r19824: Fix the max value calculation in QueryInfoKey
(This used to be commit cd14b7f052)
2007-10-10 12:16:00 -05:00
Jeremy Allison
bb4fb75b22 r19823: "log" is an internal define in older versions of gcc.
Rename to log_ctx.
Jeremy.
(This used to be commit dbf0e58a1e)
2007-10-10 12:16:00 -05:00
Volker Lendecke
ef4112922a r19822: Implement net rpc registry createkey, deletekey and deletevalue
(This used to be commit 419ebc92f0)
2007-10-10 12:15:59 -05:00
Volker Lendecke
e56be1dead r19821: Make net_rpc_registry use net_run_function2.
Fix an erroneous NT_STATUS_NO_MEMORY found by Chetan S <cshring@gmail.com>.

Thanks :-)

Volker
(This used to be commit 30f02e73fd)
2007-10-10 12:15:59 -05:00
Volker Lendecke
eb96dddb28 r19820: Limit the stat cache to 1MB by default (Bug 4244). Thanks to Bjoern Jacke
<bj@sernet.de>

Volker
(This used to be commit b32c8356f7)
2007-10-10 12:15:59 -05:00
Volker Lendecke
ead21a53ae r19819: Windows returns an empty string instead of NULL here
(This used to be commit c1083216c8)
2007-10-10 12:15:59 -05:00
Volker Lendecke
c63be3a4e7 r19818: Remove reg_split_hive, make use of registry_openkey
(This used to be commit 7fd1578a90)
2007-10-10 12:15:58 -05:00
Volker Lendecke
28bbef032f r19817: Implement net rpc registry setvalue (only dword and sz so far)
(This used to be commit 9ecb69c075)
2007-10-10 12:15:58 -05:00
Volker Lendecke
3b5d82cedd r19812: dump_regval_buf is not needed anymore
(This used to be commit f24e64160d)
2007-10-10 12:15:57 -05:00
Volker Lendecke
202f63e476 r19811: Decode REG_MULTI_SZ and REG_BINARY
(This used to be commit 6793301751)
2007-10-10 12:15:57 -05:00
Gerald Carter
95bfb97547 r19809: remove winbind blacklist parameter
(This used to be commit 40cff14498)
2007-10-10 12:15:57 -05:00
Gerald Carter
932e95abde r19808: remove old smbwrapper references
(This used to be commit c142b629c8)
2007-10-10 12:15:57 -05:00
Volker Lendecke
515dea007a r19807: First attempt at wrapping something sane around the registry API. Will be
extended.

Volker
(This used to be commit 40922eb924)
2007-10-10 12:15:57 -05:00
Volker Lendecke
ef012f8e7a r19804: Fix a valgrind error
(This used to be commit cb9e16c838)
2007-10-10 12:15:57 -05:00
Volker Lendecke
ded7c032a3 r19803: Fix problem reported by Chetan S: QueryInfoKey needs to report the max name
length in *bytes* for UTF-16, not the string length. This got lost during the
conversion.

This took a while to figure out :-)

Thanks to Chetan!

Volker
(This used to be commit 8df6544fa8)
2007-10-10 12:15:56 -05:00
Gerald Carter
53c6548fbc r19800: * Remove exmpty aix directory
* remove old, commented out commands from 'make clean'
(This used to be commit 4c96a387a2)
2007-10-10 12:15:56 -05:00
Volker Lendecke
01367cdfd0 r19797: Convert the remaining pipes to the "new" unique out ptr handling
(This used to be commit bc4e0a388a)
2007-10-10 12:15:56 -05:00
Volker Lendecke
3372adce58 r19794: Convert DFS
(This used to be commit 2efd3b3509)
2007-10-10 12:15:56 -05:00
Volker Lendecke
28a01d3fdf r19793: Change the lsa calls to the new calling convention. Nobody uses the changed
calls yet.

Volker
(This used to be commit 144cddaef5)
2007-10-10 12:15:56 -05:00
Volker Lendecke
9849f04868 r19790: Check in the PIDL change and the converted unixinfo and winbind pipes without
waiting for comments. This is what version control is for, and it does fix a
segfault I ran into ;-)

Nevertheless, Jelmer & Jerry, please take a look!

Thanks,

Volker
(This used to be commit 95c14a822c)
2007-10-10 12:15:55 -05:00
Volker Lendecke
30db93664c r19786: My last checkin to winreg_StringBuf killed rpccli_winreg_EnumKeys against
W2k3. The server requires that size==0 in the [in] name. Somehow I get the
feeling that something is badly wrong here....

I did not yet recreate the gen_ndr equivalent, see next mail.

Volker
(This used to be commit 016ddce120)
2007-10-10 12:15:55 -05:00
Volker Lendecke
bfad442144 r19780: Ok, regkey_open_internal needs a regkey_close_internal. Giving a talloc ctx is
misleading here. This needs fixing properly :-)

Volker
(This used to be commit f808182346)
2007-10-10 12:15:55 -05:00
Volker Lendecke
76b320c8df r19779: Fail properly on talloc_strdup failure
(This used to be commit b57e446789)
2007-10-10 12:15:55 -05:00
Volker Lendecke
e82cd437cc r19778: Make regkey_open_internal take a talloc ctx
(This used to be commit cb7f4211b8)
2007-10-10 12:15:55 -05:00
Volker Lendecke
cbc03ec6df r19777: Make regsubkey_ctr_addkey return WERROR. Nobody checks this so far, but this
will change.

Volker
(This used to be commit 17c7c337f6)
2007-10-10 12:15:54 -05:00
Volker Lendecke
09ec562a09 r19776: Hmmm. I should have done one instead of three commits. Sorry :-)
(This used to be commit e2a35ceffe)
2007-10-10 12:15:54 -05:00
Volker Lendecke
9bb1f909fd r19775: Fix typo
(This used to be commit 370e29ebb9)
2007-10-10 12:15:54 -05:00
Volker Lendecke
e37200a82e r19774: Fix typo
(This used to be commit 842599a7fd)
2007-10-10 12:15:54 -05:00
Volker Lendecke
5e48602456 r19773: TALLOC_FREE checks for NULL itself
(This used to be commit fb3983ae1f)
2007-10-10 12:15:54 -05:00
Volker Lendecke
5f3b7ee713 r19766: Fix a const-warning. Jerry, what did you want to fix with this line?
Volker
(This used to be commit 55dc4741cf)
2007-10-10 12:15:54 -05:00
Gerald Carter
d596aa931b r19764: set version in 3.0 branch to 3.0.25
(This used to be commit d7179d945c)
2007-10-10 12:15:53 -05:00
Gerald Carter
c2aae726ea r19762: libaddns/*[ch] code fixes donated by Centeris Corporation
(http://www.centeris.com/) under my copyright.

* Rework error reporting to use DNS_ERROR instead
  of int32
* Convert memory allocation to use talloc()
* Generalize the DNS request/response packet marshalling
* Fix the secure update requests
(This used to be commit c787983336)
2007-10-10 12:15:53 -05:00
Gerald Carter
9a88644bb5 r19758: remove the LDAP_SCOPE_ONELEVEL define (not needed after svnup)
(This used to be commit e37132f219)
2007-10-10 12:15:53 -05:00
Gerald Carter
8fa0a80b49 r19754: * When using a krb5 session setup, we don't fill in the server_name
string the clis_state struct.  So call saf_store() after we
  have the short domain name in the lsa_query_inof_policy code.

* Remove unused server string in saf_delete()
(This used to be commit 3eddae2f20)
2007-10-10 12:15:53 -05:00
Lars Müller
f5a1ec7407 r19748: Ensure to link against the required libraries.
(This used to be commit 85d8c73fbb)
2007-10-10 12:15:53 -05:00
Lars Müller
571aca9927 r19747: Ensure to link with the required objects.
(This used to be commit 8d50fb3f51)
2007-10-10 12:15:52 -05:00
Stefan Metzmacher
9e7e5938ab r19744: merge from samba4
metze
(This used to be commit fe61e6ebf7)
2007-10-10 12:15:52 -05:00
Stefan Metzmacher
5a77ccfbfc r19741: fix compiler warnings
metze
(This used to be commit 18171cf54b)
2007-10-10 12:15:52 -05:00
Stefan Metzmacher
0fa75c6797 r19739: fix compiler warning
metze
(This used to be commit b7965ac26c)
2007-10-10 12:15:51 -05:00
Stefan Metzmacher
81cf0a5cd8 r19730: as libreplace always provides dlopen(), we need to always define SHLIBEXT
this fix the build on hpisgr8 HPUX 11.23

metze
(This used to be commit b61269d7e3)
2007-10-10 12:15:50 -05:00
Stefan Metzmacher
866a3b6e40 r19725: sync samba3's ldb with samba4
metze
(This used to be commit 207643e9c9)
2007-10-10 12:15:50 -05:00
Stefan Metzmacher
06715191dd r19718: define SHLIBEXT (prepare ldb merge from samba4)
metze
(This used to be commit d8f9c20055)
2007-10-10 12:15:49 -05:00
Jeremy Allison
8f723972ae r19710: Fix memory leak in get_conf_item_string(). As
we're just doing strchr on a const string there's
no need to strdup it before, we're never modifying
it. Just remove the variable "parm".
Jeremy.
(This used to be commit 1af18f613b)
2007-10-10 12:15:48 -05:00
Jeremy Allison
46e59a57eb r19709: Fix bug #4224 - deadtime timeout was broken
because of this. Probably a show-stopper for 3.0.23d.
Thanks to Alain GORLIER <alain.gorlier@altissemiconductor.com>
for the fix.
Jeremy.
(This used to be commit b167785cbd)
2007-10-10 12:15:48 -05:00
Jeremy Allison
d988af921d r19705: Fix blocker bug for 3.0.23d - find_forced_group could
return an uninitialized sid.
Jeremy.
(This used to be commit 57c60103e7)
2007-10-10 12:15:48 -05:00
Simo Sorce
b903eb231a r19703: Don't free a string if you want to return it!
(This used to be commit 3fed72ac3e)
2007-10-10 12:15:48 -05:00
Simo Sorce
4d12d3a5c8 r19692: Another fix.
(This used to be commit a86a56fed3)
2007-10-10 12:15:47 -05:00
Simo Sorce
cccf8f0633 r19691: Fix the build
(This used to be commit fd70972ad9)
2007-10-10 12:15:47 -05:00
Simo Sorce
750947dbe4 r19690: Remove this ancient module, I never realized it was ported over.
(This used to be commit 3ef6ef7cc8)
2007-10-10 12:15:47 -05:00
Volker Lendecke
64bab725f0 r19689: Fix a NULL dereference found by coverity (the call to strlen).
Jerry, please check this. The way I understood alpha_strcpy the last arg needs
to be the size of the target, not of the source.

Thanks,

Volker
(This used to be commit 287d68daab)
2007-10-10 12:15:47 -05:00
Volker Lendecke
82cd90292f r19688: Fix a deadcode warning by Coverity.
Simo, I'm not sure this is the correct fix. So I'd like you to look at it and
merge to 4 if appropriate.

Volker
(This used to be commit afd7f12124)
2007-10-10 12:15:47 -05:00
Volker Lendecke
bae1fcd20f r19687: Fix uninitialized variables found by Coverity (and gcc -O1... ;-))
Volker
(This used to be commit b7dc9b8169)
2007-10-10 12:15:47 -05:00
Volker Lendecke
782d33e1c8 r19686: Fix the build
(This used to be commit 28ac023581)
2007-10-10 12:15:46 -05:00
Volker Lendecke
3a1ada7635 r19685: Two changes inspired by problems with huge tdbs. tdbtool's list command now
prints the hash on every record for easier awk'ing, and tdbbackup allows a
different hash chain length on the backed up tdb.

Jeremy, Günther, this might be interesting for you huge domains. Not only
locking.tdb, also the winbind ones might grow huge.

In the installation I fixed with this winbind spent a huge amount of CPU
spinning through a degenerated winbindd_idmap.tdb with entries for more than
15.000 users. With a default number of hash chains of 131 on that tdb you can
imagine that the lists get large.

Not merging to 4, I don't get tdbbackup to compile there right now.

What about changing the global default hash chain number to be dramatically
larger? Disk is cheap these days.

Volker
(This used to be commit 577d0ff658)
2007-10-10 12:15:46 -05:00
Volker Lendecke
bef92ebb25 r19669: set_share_security does not need a mem_ctx passed
(This used to be commit 53eaa603eb)
2007-10-10 12:15:46 -05:00