ira/wip.git
16 years agoChange the prototype of the vfs function get_nt_acl().
Michael Adam [Wed, 5 Dec 2007 08:53:10 +0000 (09:53 +0100)]
Change the prototype of the vfs function get_nt_acl().

Up to now, get_nt_acl() took a files_struct pointer (fsp) and
a file name. All the underlying functions should need and now
do need (after the previous preparatory work), is a connection_struct
and a file name. The connection_struct is already there in the
vfs_handle passed to the vfs functions. So the files_struct
argument can be eliminated.

This eliminates the need of calling open_file_stat in a couple
of places to produce the fsp needed.

Michael
(This used to be commit b5f600fab53c9d159a958c59795db3ba4a8acc63)

16 years agoPrepare the afs acl module for the api change in get_nt_acl().
Michael Adam [Tue, 4 Dec 2007 08:45:14 +0000 (09:45 +0100)]
Prepare the afs acl module for the api change in get_nt_acl().

This makes both of afsacl_[f]get_nt_acl() more specific,
eliminating the need for afs_get_nt_acl(). Instead, split
afs_to_nt_acl.

Michael
(This used to be commit 15caf58c81ce6b68eefa03c8f8510c2ecb5fdeb3)

16 years agoPrepare the aix2 acl module for the api change in get_nt_acl().
Michael Adam [Mon, 3 Dec 2007 17:31:03 +0000 (18:31 +0100)]
Prepare the aix2 acl module for the api change in get_nt_acl().

This makes both of aixjfs2_[f]get_nt_acl() more specific,
eliminating the need for aixjfs2_get_nt_acl_common().

Michael
(This used to be commit 36e2a814ba50feefa34c76353c0f5dec1d7cfff4)

16 years agoChange aixjfs2_get_nfs4_acl() to take file name instead of fsp.
Michael Adam [Mon, 3 Dec 2007 17:24:56 +0000 (18:24 +0100)]
Change aixjfs2_get_nfs4_acl() to take file name instead of fsp.

In preparation of the api change in api change in get_nt_acl().

Michael
(This used to be commit 40a1438e17c462990e6b71b544c39f093236d5be)

16 years agoFix two debug statements: Add missing printf parameter.
Michael Adam [Tue, 4 Dec 2007 07:25:21 +0000 (08:25 +0100)]
Fix two debug statements: Add missing printf parameter.

Michael
(This used to be commit 1c4f74551f48429ee3af2022101a97679e25cdea)

16 years agoReformatting: wrap long lines and remove trailing spaces.
Michael Adam [Tue, 4 Dec 2007 07:19:40 +0000 (08:19 +0100)]
Reformatting: wrap long lines and remove trailing spaces.

Michael
(This used to be commit f6db5a0d0571130f765d8a0fb4e20e61cc8b2487)

16 years agoPrepare the zfs acl module for the api change in get_nt_acl().
Michael Adam [Fri, 16 Nov 2007 17:33:39 +0000 (18:33 +0100)]
Prepare the zfs acl module for the api change in get_nt_acl().

Michael
(This used to be commit 04258231dc654df077638edb7cb08542e39b7547)

16 years agoPrepare the gpfs acl module for the api change in get_nt_acl().
Michael Adam [Fri, 16 Nov 2007 17:33:39 +0000 (18:33 +0100)]
Prepare the gpfs acl module for the api change in get_nt_acl().

This moves functionality from gpfsacl_get_nt_acl_common()
back to gpfsacl_get_nt_acl() and gpfsacl_fget_nt_acl(),
making both these functions more specific (calling the
corresponding fsp- and non-fsp functions).
gpfsacl_get_nt_acl_common(). is removed.

Michael
(This used to be commit d6043c1066322d2c567aedc5eae1a9d46c8fc396)

16 years agoSplit smb_get_nt_acl_nfs4 into two (f- and non-f-variant).
Michael Adam [Wed, 14 Nov 2007 23:46:20 +0000 (00:46 +0100)]
Split smb_get_nt_acl_nfs4 into two (f- and non-f-variant).

This is the next step in preparation of a get_nt_acl prototype change.

Michael
(This used to be commit 7afeb1c6cb1bdb58d1e61c54ae215d947d8dc3ea)

16 years agoSplit smbacl4_GetFileOwner into two (f- and non-f-variant).
Michael Adam [Fri, 9 Nov 2007 00:01:55 +0000 (01:01 +0100)]
Split smbacl4_GetFileOwner into two (f- and non-f-variant).

This is in preparation of a get_nt_acl prototype change.
(This used to be commit e0672a46a2e5e655da32499ca7f52a9156e9b7f0)

16 years agoSplit get_nt_acl() into two functions: fsp- and non-fsp variant.
Michael Adam [Tue, 6 Nov 2007 07:01:31 +0000 (08:01 +0100)]
Split get_nt_acl() into two functions: fsp- and non-fsp variant.

Replace smbd/posix_acls.c:get_nt_acl() by two funcions:
posix_get_nt_acl() and posix_fget_nt_acl(). The first
takes a connection struct and a file name instead of a
files_struct pointer. This is in preparation of changing
the vfs api for SMB_VFS_GET_NT_ACL.

Michael
(This used to be commit 50c82cc1456736fa634fb656e63555319742f725)

16 years agoRemove the "is_directory" parameter from canonicalise_acl():
Michael Adam [Tue, 6 Nov 2007 05:20:51 +0000 (06:20 +0100)]
Remove the "is_directory" parameter from canonicalise_acl():

It can be retrieved from the stat buffer.

Michael
(This used to be commit b0ae830bf57dcaec00b2a2eabfec7221a3b7f791)

16 years agoChange canonicalise_acl() to not take an fsp.
Michael Adam [Sat, 27 Oct 2007 23:38:59 +0000 (01:38 +0200)]
Change canonicalise_acl() to not take an fsp.

Convert canonicalise_acl() to take connection_struct, is_directory
and file name instead of files_struct pointer.

Michael
(This used to be commit d579a7f84fd47a3f00215725cecd65b21a5ff2e0)

16 years agoChange ensure_canon_entry_valid() to not take and fsp.
Michael Adam [Sat, 27 Oct 2007 23:24:41 +0000 (01:24 +0200)]
Change ensure_canon_entry_valid() to not take and fsp.

Convert ensure_canon_entry_valid() to take share_params and an is_directory
flag instead of an files_struct pointer.

Michael
(This used to be commit bdb208124bd703edee03ac4d2a4ec45ecdfc135e)

16 years agoChange apply_default_perms() to not take an fsp.
Michael Adam [Sat, 27 Oct 2007 23:14:51 +0000 (01:14 +0200)]
Change apply_default_perms() to not take an fsp.

This is a first change in a series: Pass what is needed instead of files_struct
pointers to some functions. This is in preparation of introducing two variants
of get_nt_acl - one for fname (which does not need an fsp), one for file
descriptor.

This changes apply_default_perms to take share_params (rather thatn snum)
and an is_directory flag instead of an fsp.

Michael
(This used to be commit d7e2e93758f6598a0459db3255300558618f066e)

16 years agoRemove Get_Pwnam and its associated static variable
Volker Lendecke [Wed, 19 Dec 2007 14:02:59 +0000 (15:02 +0100)]
Remove Get_Pwnam and its associated static variable

All callers are replaced by Get_Pwnam_alloc
(This used to be commit 735f59315497113aebadcf9ad387e3dbfffa284a)

16 years agoFix a "no prototype" warning
Volker Lendecke [Wed, 19 Dec 2007 19:27:47 +0000 (20:27 +0100)]
Fix a "no prototype" warning
(This used to be commit e5bd32812dd1e864e51c2199fd90d71813517f68)

16 years agoFix debug messages
Volker Lendecke [Wed, 19 Dec 2007 19:24:33 +0000 (20:24 +0100)]
Fix debug messages

When warning that "client plaintext auth" is not enabled where the server
requested them we should not talk about "client use plaintext auth"
(This used to be commit 7799e18994354b2705ee8c64ae8c75e062ace460)

16 years agoSamba Shared Repository - branch v3-2-test updated - initial-v3-2-unstable-716-g12cce3b
Volker Lendecke [Wed, 19 Dec 2007 12:48:49 +0000 (13:48 +0100)]
Samba Shared Repository - branch v3-2-test updated - initial-v3-2-unstable-716-g12cce3b

On Tue, Dec 18, 2007 at 06:04:32PM -0600, Jeremy Allison wrote:
>     Fix valgrind error in dbwrap_rbt where rec_priv->node was
>     being accessed after free. VALOKER PLEASE CHECK THIS VERY
>     CAREFULLY !!!! This is a correct fix in that it fixes the
>     valgrind error, but it looks inelegant to me. I think if
>     I understood this code better I could craft a more subtle
>     fix. Still looking at it....

Thanks a lot. Fully correct. What about the attached little
simplification?

Volker
(This used to be commit 5b72828600fb057a7aeb5f1a6fb6c23c23f28cd8)

16 years agopacket_struct is used in several places as raw memory
Volker Lendecke [Wed, 19 Dec 2007 16:05:26 +0000 (17:05 +0100)]
packet_struct is used in several places as raw memory

-> Fix more uninitialized variable warnings
(This used to be commit 0af02db6f2f84a8ce5d614e5baec27f20b413c26)

16 years agoSome paranoia checks
Volker Lendecke [Wed, 19 Dec 2007 15:48:18 +0000 (16:48 +0100)]
Some paranoia checks
(This used to be commit ff644cfa1b123e9d0f8f4817504e5b209b85dedd)

16 years agoZero the tdb key, there might be padding
Volker Lendecke [Wed, 19 Dec 2007 15:48:04 +0000 (16:48 +0100)]
Zero the tdb key, there might be padding

This leads to uninitialized variable warnings if nmbd is run under valgrind.
(This used to be commit 9ec4f91f35696e5a00e24fe9ae2dd06119482c80)

16 years agoToday is not my day...
Volker Lendecke [Wed, 19 Dec 2007 15:30:01 +0000 (16:30 +0100)]
Today is not my day...

dmapi.c certainly did compile now...
(This used to be commit 93f3a1172af2f1a20f0c4c26ec8be999546d95f8)

16 years agoRename cache.[ch] to memcache.[ch]
Volker Lendecke [Wed, 19 Dec 2007 14:45:22 +0000 (15:45 +0100)]
Rename cache.[ch] to memcache.[ch]

cache.h conflicts with an XFS DMAPI include on "opi" :-(
(This used to be commit b8db804e07cc19d406ba3892d6eecbe16132a89a)

16 years agoMerge WERR_NO_SUCH_LOGON_SESSION from Samba4.
Günther Deschner [Tue, 18 Dec 2007 12:38:14 +0000 (13:38 +0100)]
Merge WERR_NO_SUCH_LOGON_SESSION from Samba4.

Guenther
(This used to be commit 7b528647879bb55c9c85243a3e2906c09490edc9)

16 years agoAdd and use some keystr functions using talloc_tos() in secrets api.
Günther Deschner [Wed, 19 Dec 2007 09:58:58 +0000 (10:58 +0100)]
Add and use some keystr functions using talloc_tos() in secrets api.

Guenther
(This used to be commit 6ccbf67a0c6f117978df55d4e2565d34fddf9317)

16 years agoAdd cmd_wkssvc_enumeratecomputernames to rpcclient.
Günther Deschner [Wed, 19 Dec 2007 10:08:27 +0000 (11:08 +0100)]
Add cmd_wkssvc_enumeratecomputernames to rpcclient.

Guenther
(This used to be commit 289151393a43c7f0c2baafdd79d1163fc80aad6a)

16 years agoTwo more static fstrings gone.
Jeremy Allison [Wed, 19 Dec 2007 02:16:40 +0000 (18:16 -0800)]
Two more static fstrings gone.
Jeremy.
(This used to be commit 4056bb8645821fba95d6e9ca4d82e2d5084c1e5c)

16 years agoRemove last_message completely as it's no longer used.
Jeremy Allison [Wed, 19 Dec 2007 02:10:09 +0000 (18:10 -0800)]
Remove last_message completely as it's no longer used.
Jeremy.
(This used to be commit c378c3edc1197d46c5d6eb2bcabbf9e774c03ffc)

16 years agoRemove another static fstring.
Jeremy Allison [Wed, 19 Dec 2007 02:01:34 +0000 (18:01 -0800)]
Remove another static fstring.
Jeremy.
(This used to be commit f9182bbe628cb5f5395a08b2e09d4a282a99d7dc)

16 years agoWe've finished with the old node once we've copied the
Jeremy Allison [Wed, 19 Dec 2007 01:30:02 +0000 (17:30 -0800)]
We've finished with the old node once we've copied the
keyval.
Jeremy.
(This used to be commit 39f3efbcc5fbdff1db1b12e5fc7368968f240993)

16 years agoFix valgrind error in dbwrap_rbt where rec_priv->node was
Jeremy Allison [Wed, 19 Dec 2007 00:03:57 +0000 (16:03 -0800)]
Fix valgrind error in dbwrap_rbt where rec_priv->node was
being accessed after free. VALOKER PLEASE CHECK THIS VERY
CAREFULLY !!!! This is a correct fix in that it fixes the
valgrind error, but it looks inelegant to me. I think if
I understood this code better I could craft a more subtle
fix. Still looking at it....
Jeremy.
(This used to be commit 12cce3be2a24fd72106d747890caf6c7f29db43d)

16 years agoFix an error when accessing unallocated sid in error path.
Michael Adam [Tue, 18 Dec 2007 15:32:57 +0000 (16:32 +0100)]
Fix an error when accessing unallocated sid in error path.

Michael
(This used to be commit 2a0585d3093265a499c9fef60d500059f79b4112)

16 years agoAdd forgotten cache.h
Volker Lendecke [Tue, 18 Dec 2007 09:07:08 +0000 (10:07 +0100)]
Add forgotten cache.h
(This used to be commit 0dc4d6a8de84c191e339ee08c7f06ca63f83e6f3)

16 years agoAdd a in-memory cache
Volker Lendecke [Tue, 18 Dec 2007 08:41:03 +0000 (09:41 +0100)]
Add a in-memory cache

This is a more general API that caches data with a LRU scheme. See
include/cache.h. No comments yet, I'm still working on it. But Jeremy has given
me a hint in one of his checkins that he would like to make use of this now.

The idea is that we get rid of all our silly little caches and merge them all
into one cache that we can then very easily trim, for example even with a
smbcontrol message if someone decides memory is tight. The main user is the
stat cache, this patch also converts the getwd cache. More caches to come.
(This used to be commit 7a911b35713538d82001a3c9f34152e293fe1943)

16 years agoFix a debug message: add missing space.
Michael Adam [Tue, 18 Dec 2007 06:58:22 +0000 (07:58 +0100)]
Fix a debug message: add missing space.

Michael
(This used to be commit 6a7f2a59fc370e226ddacb195059155f28c6c157)

16 years agoAdd smbclient support for basic mDNS browsing.
Rishi Srivatsavai [Tue, 18 Dec 2007 06:09:09 +0000 (22:09 -0800)]
Add smbclient support for basic mDNS browsing.

Patch from Rishi Srivatsavai (bugzilla #4150), with tallocification
and minor syle changes by me.
(This used to be commit db74b99d0ef1a60894c838b4c9d0d454db6cf620)

16 years agoMore static pstring elimination.
Jeremy Allison [Tue, 18 Dec 2007 02:32:27 +0000 (18:32 -0800)]
More static pstring elimination.
Jeremy.
(This used to be commit 92acc0115d8d4111289c2ade1db7bb060ee908db)

16 years agoMore static fstring elimination.
Jeremy Allison [Tue, 18 Dec 2007 02:00:43 +0000 (18:00 -0800)]
More static fstring elimination.
Jeremy.
(This used to be commit b4dfec09e89428cac9b21a94ce4d24e60d4a54f4)

16 years agoRemove more static fstrings (yes this little cache should be
Jeremy Allison [Tue, 18 Dec 2007 01:27:29 +0000 (17:27 -0800)]
Remove more static fstrings (yes this little cache should be
in the rbtree....).
Jeremy.
(This used to be commit 97cfdae4052d46a35040d4c1a4ade8bf2c41dbc7)

16 years agoCorrectly define prototypes for accessor functions.
Jeremy Allison [Tue, 18 Dec 2007 01:13:31 +0000 (17:13 -0800)]
Correctly define prototypes for accessor functions.
Jeremy.
(This used to be commit 299ea5d122e173adf6edb6399fc90798747b0c97)

16 years agoMerge branch 'v3-2-test' of ssh://jra@git.samba.org/data/git/samba into v3-2-test
Jeremy Allison [Tue, 18 Dec 2007 01:03:07 +0000 (17:03 -0800)]
Merge branch 'v3-2-test' of ssh://jra@git.samba.org/data/git/samba into v3-2-test
(This used to be commit 8223624fea7c1b61e9231168cb4d82771576cbc5)

16 years agoMore static fstring removal.
Jeremy Allison [Tue, 18 Dec 2007 01:02:48 +0000 (17:02 -0800)]
More static fstring removal.
Jeremy.
(This used to be commit dcf624aa02cf7415a4a55e6d45606e813ae6b91f)

16 years agoFix logic error in cm_connect_sam().
Michael Adam [Tue, 18 Dec 2007 00:55:48 +0000 (01:55 +0100)]
Fix logic error in cm_connect_sam().

Don't fall back to schannel when trust creds could be obtained.
This is still not complete, but I am getting closer.

Michael
(This used to be commit 7c9fa597d684a25822b4db6615f28336f2d64ef3)

16 years agoPrevent another segfault.
Michael Adam [Tue, 18 Dec 2007 00:30:52 +0000 (01:30 +0100)]
Prevent another segfault.

Michael
(This used to be commit 0a9874c1c76c0ccc71caba7ee85a0ee1a91808c5)

16 years agoUse the %*s feature of snprintf to remove anothe static fstring.
Jeremy Allison [Tue, 18 Dec 2007 00:20:44 +0000 (16:20 -0800)]
Use the %*s feature of snprintf to remove anothe static fstring.
Jeremy.
(This used to be commit 4ae4b2358688bf289305a2db0ed01b653ac073b2)

16 years agoFix a segv in winbindd caused by trying to free an fstring.
Gerald (Jerry) Carter [Mon, 17 Dec 2007 23:33:48 +0000 (17:33 -0600)]
Fix a segv in winbindd caused by trying to free an fstring.
Make a copy of the machine_password and machine_account strings
in all conditional paths so that SAFE_FREE() will always be valid.
(This used to be commit 194c4640b158457a6d0d5ea91e28d41d619c77de)

16 years agoDo not close netlogon pipe in get_schannel_session_key_common().
Michael Adam [Mon, 17 Dec 2007 22:02:39 +0000 (23:02 +0100)]
Do not close netlogon pipe in get_schannel_session_key_common().

This removes one forgotten call of cli_rpc_pipe_close(netlogon_pipe).
Correction of e77c4022cfbb868e608edcb06b676658b0e201ad.

Michael
(This used to be commit 7f6593cddef048dd05140b05d306c708d8134f0e)

16 years agoMerge branch 'v3-2-test' of ssh://git.samba.org/data/git/samba into v3-2-simo
Simo Sorce [Mon, 17 Dec 2007 20:26:16 +0000 (15:26 -0500)]
Merge branch 'v3-2-test' of ssh://git.samba.org/data/git/samba into v3-2-simo
(This used to be commit e940537d5be870ae622712a3b76dff891739df8c)

16 years agoWhile 'data' is usually 0 terminated, nothing in the spec requires that. The correct...
Simo Sorce [Mon, 17 Dec 2007 20:21:38 +0000 (15:21 -0500)]
While 'data' is usually 0 terminated, nothing in the spec requires that. The correct way is to copy only 'length' bytes.

Simo.
(This used to be commit 814c1b0e0034fb67c7718760dfcf913904f3e7fa)

16 years agoFix bug #5121 (unix passwd sync not working on a streams based
Jeremy Allison [Mon, 17 Dec 2007 18:44:09 +0000 (10:44 -0800)]
Fix bug #5121 (unix passwd sync not working on a streams based
system).
Jeremy.
(This used to be commit 545cd2139cfc9484b733693814d4724d37125942)

16 years agoMerge in J.Layton patch and resolve conflict.
Simo Sorce [Mon, 17 Dec 2007 14:43:18 +0000 (09:43 -0500)]
Merge in J.Layton patch and resolve conflict.
(This used to be commit 6b1a118eaaab405eeef0cf3c0488a2747af562ba)

16 years agoRemove direct caller of secrets_fetch_trusted_domain_password().
Michael Adam [Mon, 17 Dec 2007 13:51:37 +0000 (14:51 +0100)]
Remove direct caller of secrets_fetch_trusted_domain_password().

This is a regession introduced by f7efc0eca9426e63b751c07a90265a12bb39cf95.
This calls pdb_get_trusteddom_pw() instead, again.

Michael
(This used to be commit 91be824d2ba0b8dccf42ba2b8555a204aa1fa56c)

16 years agoReformat: Remove trailing spaces.
Michael Adam [Mon, 17 Dec 2007 09:34:29 +0000 (10:34 +0100)]
Reformat: Remove trailing spaces.

Michael
(This used to be commit 5249b3d204bf5f9191c2a4a7e81d09227eb5ddea)

16 years agoMake usage message for net sam rights list a little more precise.
Michael Adam [Mon, 17 Dec 2007 10:57:14 +0000 (11:57 +0100)]
Make usage message for net sam rights list a little more precise.

Michael
(This used to be commit d466a5136d5151e2a3cae7464cb346f0db650554)

16 years agoFix for bug #4801: Correctly implement lsa lookup levels for lookupnames.
Michael Adam [Wed, 12 Dec 2007 17:03:20 +0000 (18:03 +0100)]
Fix for bug #4801: Correctly implement lsa lookup levels for lookupnames.

This patch is still incomplete in that winbindd does not walk
the the trusted domains to lookup unqualified names here.
Apart from that this fix should be pretty much complete.

Michael
(This used to be commit f7efc0eca9426e63b751c07a90265a12bb39cf95)

16 years agoFix flags in caller of lookup_name() in create_builtin_administrators().
Michael Adam [Mon, 17 Dec 2007 09:54:05 +0000 (10:54 +0100)]
Fix flags in caller of lookup_name() in create_builtin_administrators().

Michael
(This used to be commit 46bfbf5c8af6c030e67219a29c49fd2d40003b18)

16 years agoFix flags in all callers of lookup_name() in net_sam.c.
Michael Adam [Mon, 17 Dec 2007 10:55:05 +0000 (11:55 +0100)]
Fix flags in all callers of lookup_name() in net_sam.c.

Michael
(This used to be commit 6d0db17a9e255235d40eabc63e91c9f5d4febcde)

16 years agoFix flags in call of lookup_name() in srv_samr_nt.c: can_create().
Michael Adam [Mon, 17 Dec 2007 10:32:21 +0000 (11:32 +0100)]
Fix flags in call of lookup_name() in srv_samr_nt.c: can_create().

Use LOOKUP_NAME_LOCAL instead of LOOKUP_NAME_ISOLATED.

Michael
(This used to be commit 1d4e0ad1142c61de402c925306f02f5de2c872f6)

16 years agoFix flags in call of lookup_name() in pdb_default_create_alias().
Michael Adam [Mon, 17 Dec 2007 09:55:37 +0000 (10:55 +0100)]
Fix flags in call of lookup_name() in pdb_default_create_alias().

Use new flag LOOKUP_NAME_LOCAL.

Michael
(This used to be commit 280d6cb6c8e834ce0a08769e9187b0f40321716f)

16 years agoAdd combined flag LOOKUP_NAME_LOCAL.
Michael Adam [Mon, 17 Dec 2007 10:28:56 +0000 (11:28 +0100)]
Add combined flag LOOKUP_NAME_LOCAL.

Presence of LOOKUP_NAME_ISOLATED as the only flag is not the sign
for doing local lookups only but the sign for allowing lookups
of unqualified names. The correct sign is absence of the flag
LOOKUP_NAME_REMOTE.

Michael
(This used to be commit cd8c0057446a1311a860f6cc3876a113568f6c30)

16 years agoRemove t_doschar.c
Volker Lendecke [Mon, 17 Dec 2007 06:18:30 +0000 (07:18 +0100)]
Remove t_doschar.c
(This used to be commit b89f87242b9c949401f3fa9b352211906cb76895)

16 years agoRemove another static string and static passwd.
Jeremy Allison [Mon, 17 Dec 2007 02:32:03 +0000 (18:32 -0800)]
Remove another static string and static passwd.
Jeremy.
(This used to be commit 2a700c5a57a417add3b1975b2c396d20c8a5f301)

16 years agoRemove a static fstring.
Jeremy Allison [Mon, 17 Dec 2007 02:02:32 +0000 (18:02 -0800)]
Remove a static fstring.
Jeremy.
(This used to be commit 898c56c0ead6331721de9645ce55608cbe7cf34d)

16 years agoget rid of doschar_table[]
Volker Lendecke [Sat, 15 Dec 2007 23:25:49 +0000 (00:25 +0100)]
get rid of doschar_table[]

If I'm not completely blind, then check_dos_char is *only* used in the case
when we can't mmap() valid.dat. To me this looks as if we initialize the 65536
bits in doschar_table[] with check_dos_char_slowly, use it once to initialize
valid_table[] and *never* use them again. I think there's no point in keeping
these 8k of modified memory around for an unlikely case (no "valid.dat") and
even that only to use it exactly once.
(This used to be commit 0bfea7259e4091c6d914528a0e65fc10d8a56fb8)

16 years agoTiny fixes to init_valid_table()
Volker Lendecke [Sat, 15 Dec 2007 23:19:42 +0000 (00:19 +0100)]
Tiny fixes to init_valid_table()
(This used to be commit a8948e0727b100945ab730d4d144ccbe219bbc94)

16 years agoMake init_doschar_table() static
Volker Lendecke [Sat, 15 Dec 2007 23:17:41 +0000 (00:17 +0100)]
Make init_doschar_table() static

It's only called directly before init_valid_table() anyway, so move it there.
(This used to be commit b6d1d2428866712a550a354732e2386b4f87b67b)

16 years agoMake check_dos_char static
Volker Lendecke [Sat, 15 Dec 2007 23:15:34 +0000 (00:15 +0100)]
Make check_dos_char static

It's only called in t_doschar, a pretty bogus test program that is not compiled
by default
(This used to be commit 99c59e809ef3c5abcdfb796d50be7c40f7033787)

16 years agomake use of unmarshall_sec_desc
Volker Lendecke [Sun, 16 Dec 2007 13:15:16 +0000 (14:15 +0100)]
make use of unmarshall_sec_desc
(This used to be commit ced0c42f055a672f6b4ab6ba809b0f63c83b431e)

16 years agomake use of [un]marshall_sec_desc, allow for fd==-1 in get/set_secdesc
Volker Lendecke [Sun, 25 Nov 2007 17:26:52 +0000 (18:26 +0100)]
make use of [un]marshall_sec_desc, allow for fd==-1 in get/set_secdesc
(This used to be commit 585f5f8831f13260808a82611656fc6ca5caee81)

16 years agoCut down memory usage of registry initialization
Volker Lendecke [Thu, 13 Dec 2007 21:20:58 +0000 (22:20 +0100)]
Cut down memory usage of registry initialization
(This used to be commit 264d5dfe9fe97db0b69d7cd04086ad8ed9f78e74)

16 years agoRemove a static fstring
Volker Lendecke [Sat, 15 Dec 2007 23:03:56 +0000 (00:03 +0100)]
Remove a static fstring
(This used to be commit a9c62c57db9e580640d0265b08b3178496de76a8)

16 years agoMake smb_np_struct talloc'ed
Volker Lendecke [Sun, 16 Dec 2007 11:58:07 +0000 (12:58 +0100)]
Make smb_np_struct talloc'ed

Convert "name" from string to a talloc'ed char *
(This used to be commit e82069f921b3a22295db91e092c22c459ccd7215)

16 years agoRemove unused code
Volker Lendecke [Sun, 16 Dec 2007 11:57:06 +0000 (12:57 +0100)]
Remove unused code
(This used to be commit fcd45ad6fb8d89bf6106fbed101060dbe422661a)

16 years agoDoh, fix typo in error exit.
Jeremy Allison [Sun, 16 Dec 2007 07:32:28 +0000 (23:32 -0800)]
Doh, fix typo in error exit.
Jeremy.
(This used to be commit 44918f39c0598eec681eb9e5c65452f04809c375)

16 years agoAdded patch originally by Andreas Schneider <anschneider@suse.de>
Jeremy Allison [Sun, 16 Dec 2007 07:22:25 +0000 (23:22 -0800)]
Added patch originally by Andreas Schneider <anschneider@suse.de>
to cause us to behave like Vista when looking for remote
machine principal. Modified by me.
Jeremy.
(This used to be commit d0e33840fb4cfc85990d3ee327428b0854a22722)

16 years agoCope with valgrind > 3.2.x.
Jeremy Allison [Sun, 16 Dec 2007 07:05:30 +0000 (23:05 -0800)]
Cope with valgrind > 3.2.x.
Jeremy.
(This used to be commit e799eb8da6f5e7a2173ba6b8fb040430fd1c6f34)

16 years agoMore work on bug #5082, use LC_ALL as this takes
Jeremy Allison [Sun, 16 Dec 2007 06:28:38 +0000 (22:28 -0800)]
More work on bug #5082, use LC_ALL as this takes
precedence.
Jeremy.
(This used to be commit 446ebae76d6796b30e4c71ff7190337c28637be6)

16 years agos/sid_to_string/sid_to_fstring/
Volker Lendecke [Sat, 15 Dec 2007 21:47:30 +0000 (22:47 +0100)]
s/sid_to_string/sid_to_fstring/

least surprise for callers
(This used to be commit eb523ba77697346a365589101aac379febecd546)

16 years agoUse dom_sid_string for sid_string_talloc
Volker Lendecke [Sat, 15 Dec 2007 21:33:52 +0000 (22:33 +0100)]
Use dom_sid_string for sid_string_talloc

Remove some code duplication, but introduce one more dependency on librpc/ndr.
Easily turned around so that librpc/ndr depends on lib/util_sid if necessary
(This used to be commit 3a0b1b2060facd5f1ac1461b23dd86c75cdd9458)

16 years agosid_string_static is no more :-)
Volker Lendecke [Sat, 15 Dec 2007 21:08:09 +0000 (22:08 +0100)]
sid_string_static is no more :-)

We now have four ways to do sid_to_string:

sid_to_string: Convert it into an existing fstring, when you have one

sid_string_talloc: The obvious thing

sid_string_tos: For the lazy, use only with care

sid_string_dbg: The one to use in DEBUG statements
(This used to be commit 7b8276aaa48852270c6b70b081c3f28e316a7a2c)

16 years agoReplace sid_string_static with sid_to_string
Volker Lendecke [Sat, 15 Dec 2007 21:00:39 +0000 (22:00 +0100)]
Replace sid_string_static with sid_to_string

This adds 28 fstrings on the stack, but I think an fstring on the stack is
still far better than a static one.
(This used to be commit c7c885078be8fd3024c186044ac28275d7609679)

16 years agoUse sid_to_string directly
Volker Lendecke [Sat, 15 Dec 2007 20:58:28 +0000 (21:58 +0100)]
Use sid_to_string directly

It seems a bit pointless to do a fstrcpy(dst, sid_string_static(src))
(This used to be commit c221c246b10e2dbbd54a9af2dc45de2eae237380)

16 years agoReplace sid_string_static with sid_string_tos
Volker Lendecke [Sat, 15 Dec 2007 20:53:26 +0000 (21:53 +0100)]
Replace sid_string_static with sid_string_tos

In utils/ I was a bit lazy...
(This used to be commit 60e830b0f4571bd5d9039f2edd199534f2a4c341)

16 years agoUse sid_string_talloc where we have a tmp talloc ctx
Volker Lendecke [Sat, 15 Dec 2007 20:49:15 +0000 (21:49 +0100)]
Use sid_string_talloc where we have a tmp talloc ctx
(This used to be commit 0a911d38b8f4be382a9df60f9c6de0c500464b3a)

16 years agoReplace sid_string_static by sid_string_dbg in DEBUGs
Volker Lendecke [Sat, 15 Dec 2007 20:11:36 +0000 (21:11 +0100)]
Replace sid_string_static by sid_string_dbg in DEBUGs
(This used to be commit bb35e794ec129805e874ceba882bcc1e84791a09)

16 years agoAdd sid_string_dbg
Volker Lendecke [Sat, 15 Dec 2007 20:06:20 +0000 (21:06 +0100)]
Add sid_string_dbg

This makes use of the just added debug_ctx and will kill many
sid_string_static() calls
(This used to be commit 3e4148c280efe154c3f8d552731c8b29d6977507)

16 years agoAdd debug_ctx according to an idea by Tridge
Volker Lendecke [Sat, 15 Dec 2007 20:05:11 +0000 (21:05 +0100)]
Add debug_ctx according to an idea by Tridge

Sorry, Jeremy, I think for debug messages this is just the right way to do it.
(This used to be commit 6312016e2727c2b5b1a4964a98cfb9585d77cc8c)

16 years agoUse sid_string_talloc where we have a tmp talloc ctx
Volker Lendecke [Sat, 15 Dec 2007 20:10:58 +0000 (21:10 +0100)]
Use sid_string_talloc where we have a tmp talloc ctx
(This used to be commit f00ab810d2540679bec109498ac89e1eafe18f03)

16 years agoadd sid_string_talloc
Volker Lendecke [Sat, 15 Dec 2007 18:00:42 +0000 (19:00 +0100)]
add sid_string_talloc
(This used to be commit 9e3ef0923d71cc06b8445be2625ebd8dfed1b42d)

16 years agoFix a segfault
Volker Lendecke [Sat, 15 Dec 2007 10:38:28 +0000 (11:38 +0100)]
Fix a segfault

sid_to_string still expects a fstring
(This used to be commit 1f352cdd1976ad36484e146165df585b88ec5527)

16 years agoFix for bug #5082 from Mathias Gug <mathiaz@ubuntu.com>, Steve Langasek <vorlon@debia...
Jeremy Allison [Sat, 15 Dec 2007 01:02:50 +0000 (17:02 -0800)]
Fix for bug #5082 from Mathias Gug <mathiaz@ubuntu.com>, Steve Langasek <vorlon@debian.org>.
Recent versions of Linux-PAM support localization of user prompts,
so Samba must use the C locale when invoking PAM (directly or via
/usr/bin/passwd) to ensure that password chat values match the prompts in a
locale-invariant fashion.
Jeremy.
(This used to be commit bc13e939546a5bcb78925a6b117e89fde20f6451)

16 years agoselftest: reenable wbinfo tests and pass --configfile instead of -s
Stefan Metzmacher [Fri, 14 Dec 2007 18:39:49 +0000 (19:39 +0100)]
selftest: reenable wbinfo tests and pass --configfile instead of -s

metze
(This used to be commit 56251f78524416435299e26fca405e77d0f42043)

16 years agowbinfo: use POPT_COMMON_CONFIGFILE
Stefan Metzmacher [Fri, 14 Dec 2007 18:38:23 +0000 (19:38 +0100)]
wbinfo: use POPT_COMMON_CONFIGFILE

We can't use POPT_COMMON_SAMBA as the -s option is
already used by -s, --sid-to-name=SID.

Also load the config file after processing the cmdline options

metze
(This used to be commit 33cbd6903e8b468a782fb5d6913eb82824d3b347)

16 years agoadd POPT_COMMON_CONFIGFILE which only provides --configfile (not -s)
Stefan Metzmacher [Fri, 14 Dec 2007 18:36:14 +0000 (19:36 +0100)]
add POPT_COMMON_CONFIGFILE which only provides --configfile (not -s)

metze
(This used to be commit af3392cc20942158ac9e0a533799c5904ff23347)

16 years agoselftest: disable wbinfo tests
Stefan Metzmacher [Fri, 14 Dec 2007 17:02:05 +0000 (18:02 +0100)]
selftest: disable wbinfo tests

wbinfo needs to take --config-file to work...

metze
(This used to be commit a8a74fc88cb6f4be1efdc1afab9b91defcd015ae)

16 years agoselftest: add a bunch of wbinfo based tests for winbindd
Stefan Metzmacher [Fri, 14 Dec 2007 15:54:01 +0000 (16:54 +0100)]
selftest: add a bunch of wbinfo based tests for winbindd

metze
(This used to be commit 88b6d2c0e83f515e2f83e5b4edc0728c434c7294)

16 years agoselftest: move workgroup name into WORKGROUP envvar
Stefan Metzmacher [Fri, 14 Dec 2007 15:14:32 +0000 (16:14 +0100)]
selftest: move workgroup name into WORKGROUP envvar

metze
(This used to be commit 8ace8fa82c2ccd6fdb9ca076fb2d6fed203c8126)

16 years agoRevert smbclient changes.
Karolin Seeger [Fri, 14 Dec 2007 11:02:49 +0000 (12:02 +0100)]
Revert smbclient changes.

Patch broke option -p.
Sorry for breaking the build!

Karolin
(This used to be commit 81dab4145ffaf21d5d2176b16b5989f4035dd791)

16 years agoMake smbclient to display error message and usage in the case of invalid options.
Karolin Seeger [Fri, 14 Dec 2007 09:52:31 +0000 (10:52 +0100)]
Make smbclient to display error message and usage in the case of invalid options.
(This used to be commit 04131b26de08b3cea948ef89921c56561d69dd1d)