1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-22 22:04:08 +03:00

2384 Commits

Author SHA1 Message Date
Stefan Metzmacher
4228ef2815 r2860: add gensec_have_feature() to check what feature are used in the connection
metze
(This used to be commit 30aa8af04498d674dbcf428a9e62df9055f53ea2)
2007-10-10 12:59:39 -05:00
Andrew Bartlett
59ef8de129 r2859: It seems useful to allow the seal/unseal functions in gensec to pass
though to the sign/check_sig functions.

Andrew Bartlett
(This used to be commit 18367c4235cf16f3c2fee003153ec9b19b02aa9b)
2007-10-10 12:59:39 -05:00
Stefan Metzmacher
f210b98804 r2858: fix a few SMB_EXT_LIB_FROM_PKGCONFIG() bugs
metze
(This used to be commit 285d1ea4b09d4fc325544ad1b98244cc1046759c)
2007-10-10 12:59:39 -05:00
Andrew Tridgell
7d32679e96 r2857: this commit gets rid of smb_ucs2_t, wpstring and fpstring, plus lots of associated functions.
The motivation for this change was to avoid having to convert to/from
ucs2 strings for so many operations. Doing that was slow, used many
static buffers, and was also incorrect as it didn't cope properly with
unicode codepoints above 65536 (which could not be represented
correctly as smb_ucs2_t chars)

The two core functions that allowed this change are next_codepoint()
and push_codepoint(). These functions allow you to correctly walk a
arbitrary multi-byte string a character at a time without converting
the whole string to ucs2.

While doing this cleanup I also fixed several ucs2 string handling
bugs. See the commit for details.

The following code (which counts the number of occuraces of 'c' in a
string) shows how to use the new interface:

size_t count_chars(const char *s, char c)
{
	size_t count = 0;

	while (*s) {
		size_t size;
		codepoint_t c2 = next_codepoint(s, &size);
		if (c2 == c) count++;
		s += size;
	}

	return count;
}
(This used to be commit 814881f0e50019196b3aa9fbe4aeadbb98172040)
2007-10-10 12:59:39 -05:00
Andrew Tridgell
48f960ab47 r2856: fixed a minor memory leak in the auth code
(This used to be commit 1b3c7d9cfa250d917a7fb96b315da9ed7d7a91d6)
2007-10-10 12:59:39 -05:00
Stefan Metzmacher
9abbd9e860 r2855: fix error codes for Compare
metze
(This used to be commit d23335bc14de7f0402e3d536006d04e813403893)
2007-10-10 12:59:39 -05:00
Andrew Tridgell
03341ec5bb r2854: added a RPC-COUNTCALLS torture test - a useful varient on the full scanner in RPC-SCANNER
(This used to be commit 04eaae59cda8a8d67bcca896a32dec2ad402a4f2)
2007-10-10 12:59:39 -05:00
Stefan Metzmacher
6aa4a9bd16 r2853: add torture test to find the defaultNamingContext on the RootDSE
try a sasl sealed CompareRequest

abartlet: we need to check how SINGING only can work,
          it failed for me:-(

metze
(This used to be commit 1dabd04e265bbc1e8335f816708c2639746d9afd)
2007-10-10 12:59:38 -05:00
Stefan Metzmacher
dba5773d9d r2851: don't destroy the gensec context it's used for sign and seal
check the result of ldap_receive()

metze
(This used to be commit 778cf6d92bc3c50add43b573652c2aefef65026c)
2007-10-10 12:59:38 -05:00
Stefan Metzmacher
5bf740dfb8 r2850: - check for GENSEC_WANT_SEAL in gensec_unseal_packet()
- pass functions to the subcontext in spnego

metze
(This used to be commit d02fab41f8261095ca8f9a819e0c25bef41b5807)
2007-10-10 12:59:38 -05:00
Andrew Tridgell
1aabcd7312 r2836: removed a couple of unused variables
(This used to be commit 391b09dad1cb549b4ce508265a9925c405201e47)
2007-10-10 12:59:38 -05:00
Andrew Tridgell
ed6a5a1e0e r2833: - added a call to SamrQueryGroupMember for every group, and fix the
IDL so this works (the previous IDL was bogus)

- changed a hyper to uint64 after looking at output on cascade on sparc
(This used to be commit db1ed5675a5271085ea0b89dd634b037ee710178)
2007-10-10 12:59:37 -05:00
Volker Lendecke
7b77ff3720 r2831: // style comments are not supported by pure C preprocessors. Please DONT use
them. This includes idl files.

Volker
(This used to be commit e9fa997fd7747cf78ef0ac76bf70f5e34d3d1b12)
2007-10-10 12:59:37 -05:00
Volker Lendecke
44f463d9c9 r2830: // style comments are not supported by pure C preprocessors. Please DONT use
them. This includes idl files.

Volker
(This used to be commit d9f3c4e301e52d8e7d7049e657185a66bfad29f7)
2007-10-10 12:59:37 -05:00
Stefan Metzmacher
becc7302f0 r2829: REALM and netbiosname are always uppercase
dnsname and dnshostname always lowercase

metze
(This used to be commit 0b46dc6f4b3614fc1d258653f0c8df63586539b6)
2007-10-10 12:59:37 -05:00
Stefan Metzmacher
85428819e3 r2825: fix the build
this function names are unsed elsewhere in the code too

metze
(This used to be commit a8f2fe0ff0dc2b4219a2cc56272e1e929b9b59b8)
2007-10-10 12:59:37 -05:00
Simo Sorce
cf42c06c86 r2820: complete the parsing routing with correct support for escaped chars
clean up simple_ldb functions
(This used to be commit 3af61cb6cd43c8609f06d66d2678994726805063)
2007-10-10 12:59:37 -05:00
Volker Lendecke
6bedfa7166 r2818: On AIX, for some reason pidl fails in dcom.idl:29. The only thing
is a /* style comment. Try //.

Volker
(This used to be commit 73adc1f357bc0ac01729eb03b26f27cf28226c23)
2007-10-10 12:59:37 -05:00
Tim Potter
94ae449f33 r2817: Get winreg_GetKeySecurity() working but use data blob instead of
security descriptor.
(This used to be commit bc5165e40a716fb7c612b32c0b6f03cb2d331d11)
2007-10-10 12:59:36 -05:00
Stefan Metzmacher
85b78669b4 r2816: fix 'Default-First-Site-Name' dn
metze
(This used to be commit ae4b99d15c24696e0784e406e00220d2d0c0a93f)
2007-10-10 12:59:36 -05:00
Simo Sorce
44a556fd5a r2815: add some more docs
add a nearly complete rfc conformat dn parsing function
(This used to be commit 1bc5a94488f48ae5c8e67db169f24f5f24c4a234)
2007-10-10 12:59:36 -05:00
Andrew Tridgell
ffe8ecfc14 r2808: added auto-detection of unix user and groups names during provision.
(This used to be commit 036e953fac0cd5f0a5760ff0b9f9de45e8cf9479)
2007-10-10 12:59:36 -05:00
Tim Potter
263212aba5 r2807: OK I think winreg_EnumValue() finally works. The previous version
didn't work with non-NULL registry value names.

Update testsuite to enumerate all keys and values two levels deep.
(This used to be commit c09f0f355ba6a589121588492aa2db5deb7121e0)
2007-10-10 12:59:36 -05:00
Tim Potter
9880410f1f r2806: Add winreg.i to dependencies for dcerpc.i
(This used to be commit dc43666135a0d9f3be9ebe588ffb24d29027c42c)
2007-10-10 12:59:36 -05:00
Tim Potter
b6c0f2cac2 r2805: Handle NULL pointers when converting structures to Python. All the
test cases up till now haven't come across them yet!
(This used to be commit 5fd3c12d4fe3e572618bcd71c5915f69539fe7e6)
2007-10-10 12:59:36 -05:00
Andrew Tridgell
0eeb0973e9 r2804: - setup some reasonable default SAM to unixName mappings in the provisioning.
- enable the unixuid module by default on all backends
(This used to be commit e335cd4933fccc1bb53641131eb6505faca857ce)
2007-10-10 12:59:36 -05:00
Andrew Tridgell
fe3294f7f0 r2803: allow unixuid module to work with foreign security principles
(This used to be commit f522728728fa523ce7d9e73c93b27e71f3757d50)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
830ac69b1d r2802: a better provisioning script
(This used to be commit f5560f961d5b806c2f70feba568d640e6baac2f9)
2007-10-10 12:59:35 -05:00
Tim Potter
985abd104d r2801: Wrapped functions that return a DOS error code can return DCERPC
faults if they are badly formed.  Handle this by checking the value of
NTSTATUS as well as WERROR.
(This used to be commit bb1be7819741f6c7dc1ee982cb2a255b6d776b79)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
a56c984df4 r2800: removed the warning about using the posix ntvfs handler, as it is now
considerably more complete than the simple handler
(This used to be commit e6ecd31be8e91f552d891c41b2f8737519a490a1)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
ae30c7c5e6 r2799: removed one last occurance of torture_ldb_alloc()
(This used to be commit 5045482b14dfcbb535eab3e5fa63ef1c3b46c40f)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
9a415b723c r2798: get rid of a unnecessary static
(This used to be commit c3dfa7e8287811b4f54d58b45f5093521886b17e)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
c4bf8c5b2c r2797: don't free the server_info before using it for anonymous connections
(This used to be commit 5f5b04196c7930c91e6c00e0276f25f88181b317)
2007-10-10 12:59:35 -05:00
Andrew Tridgell
c5722fb81b r2796: - changed ldap attributes "UnixID" to "unixID" and "UnixName" to "unixName" to be more ldap traditional
- register the unixuid module as all 3 ntvfs backend types, as it doesn't care what type of backend
  it filters
(This used to be commit cd43def6ce280442306f14ca61508b4f7eb92cb6)
2007-10-10 12:59:34 -05:00
Tim Potter
68d2ce3320 r2795: Split status code constants into a separate file.
(This used to be commit 12a3f75c1cf39c74952077cc00fd86a4e935f74b)
2007-10-10 12:59:34 -05:00
Andrew Tridgell
5a872512b0 r2794: a very simple version of the unixuid NTVFS pass-thru module. In
conjunction with the posix backend this gives us a way to correctly
setup the unix security context in Samba4.

I chose the following method to determine the unix uid's and gid's to
use given the list of SIDs from the login process

 - look for a "UnixID" field in the sam record. If present, then use it
   (check if the record is of the right type as well)

 - if UnixID is not present, then look for the "UnixName" sam
   field. If it is present then use getpwnam() or getgrnam() to find
   the unix id.

 - if UnixID and UnixName are not present, then look for a unix
   account of the right type called by the same name as the sAMAccountName field.

 - if none of the above work then fail the operation with NT_STATUS_ACCESS_DENIED

obviously these steps only work well with a local SAM. It will need to
be more sophisticated in future.

I did not put any cache in place at all. That will need to be added
for decent performance.
(This used to be commit 78b67d19b9766131f0270e451089ee5bb1aa8bd9)
2007-10-10 12:59:34 -05:00
Andrew Tridgell
6b481af7f2 r2793: fixed the handling of primaryGroupID in auth_sam. There were two bugs,
the first was it didn't pass primaryGroupID as an attributed it
wanted, the second was it didn't cope with primaryGroupID not being
present.
(This used to be commit 8373bfcdeca13dcdce3081af420d8bb7d842ad18)
2007-10-10 12:59:34 -05:00
Andrew Tridgell
1429ed54f1 r2792: got rid of talloc_ldb_alloc() and instead created talloc_realloc_fn(),
so talloc now doesn't contain any ldb specific functions.

allow NULL to be passed to a couple more talloc() functions
(This used to be commit 1246f80d806fb5f63cfbf3879de6d546384552a8)
2007-10-10 12:59:34 -05:00
Andrew Tridgell
15b9736ed3 r2791: got rid of talloc_unreference() and instead created talloc_unlink(),
which is much clearer and simpler to use. It removes a specific parent
from a pointer, no matter whether that parent is a "reference" or a
direct parent. This gives complete control over the free process.
(This used to be commit 6c563887f1b9b8c842309a523e88b6f2a32db10f)
2007-10-10 12:59:34 -05:00
Tim Potter
a248164de5 r2790: Add code to generate WERROR exceptions. Arrange inclusion of autogenerated
interface files to divvy them up into pipes that return WERRORs and pipes
that return NTSTATUS values.
(This used to be commit 294d1ae35c09432a41e5a07a3aa1884bfb9a93be)
2007-10-10 12:59:34 -05:00
Simo Sorce
54ae58fbcd r2789: fix compile
(This used to be commit a34ba8dafebb65e59616a0e68cc3d6fe3a349801)
2007-10-10 12:59:34 -05:00
Andrew Tridgell
421ff99f5d r2788: prevent a memory leak in the pvfs search backend
(This used to be commit 1de22070610231e60d329f56997bbec2cc674a4e)
2007-10-10 12:59:33 -05:00
Andrew Tridgell
d1a5683630 r2787: force masktest to use RAW_SEARCH_BOTH_DIRECTORY_INFO so it can obtain the short name
(This used to be commit ad5a5ea08d5be812e0ef662948477add2433bc6f)
2007-10-10 12:59:33 -05:00
Andrew Tridgell
84bbe948f3 r2786: - match on both long and short name for search posix backend
- a final name component of . is illegal
(This used to be commit 11c852170b83e5adbdb58407e1c7d3aeb4ab5bb8)
2007-10-10 12:59:33 -05:00
Andrew Tridgell
c62a988c39 r2785: call init_iconv() in smbtorture to ensure we have no memory allocated
when a test started, thus making leak detection easier
(This used to be commit 6c46e4622a9851bdef25ba9d353bdebc25f6ec8d)
2007-10-10 12:59:33 -05:00
Andrew Tridgell
a46270e2fa r2784: - fixed alignment of ascii directory listings
- fixed minimum parameter size for ascii qpathinfo call
(This used to be commit ee065ae7f92e60600966cb1d44cd0e30498b93dd)
2007-10-10 12:59:32 -05:00
Andrew Tridgell
20c550d87f r2783: got rid of the unused remote architecture detection code
(This used to be commit 9a04664531601b8251dbf6a0922ab48e675adb90)
2007-10-10 12:59:32 -05:00
Tim Potter
a1cee786f0 r2782: Reformat IDL for winreg_EnumValue()
(This used to be commit 9250f745adc22b3f179cf363a9a9a5fba1ec6fc9)
2007-10-10 12:59:32 -05:00
Tim Potter
710ad9613b r2781: Got winreg_EnumValue() working. Check it in so I don't break it trying
to clean it up.  (-:
(This used to be commit cc646f73b873292eaba152770be9500beff1c988)
2007-10-10 12:59:32 -05:00
Tim Potter
7cef5fd077 r2780: Add conversion routines for DATA_BLOB. I'm not convinced that DATA_BLOB's
should be treated as scalar types though.
(This used to be commit c9e96038f821783c30b5cf509334176f982403d9)
2007-10-10 12:59:32 -05:00