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

5312 Commits

Author SHA1 Message Date
Stefan Metzmacher
d7fa349052 s3:auth: change num_groups to from size_t to uint32_t
This will help with the change from UNIX_USER_TOKEN to security_unix_token

metze
2011-02-22 16:20:11 +11:00
Andrew Bartlett
2e69e89456 s3-auth Rename auth_serversupplied_info varaiables: server_info -> session_info
These variables, of type struct auth_serversupplied_info were poorly
named when added into 2001, and in good consistant practice, this has
extended all over the codebase in the years since.

The structure is also not ideal for it's current purpose.  Originally
intended to convey the results of the authentication modules, it
really describes all the essential attributes of a session.  This
rename will reduce the volume of a future patch to replaced these with
a struct auth_session_info, with auth_serversupplied_info confined to
the lower levels of the auth subsystem, and then eliminated.

(The new structure will be the output of create_local_token(), and the
change in struct definition will ensure that this is always run, populating
local groups and privileges).

Andrew Bartlett

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-02-22 16:20:10 +11:00
Volker Lendecke
e99d1de3c4 s3: Protect tldap_errstr against a NULL ld 2011-02-20 15:59:48 +01:00
Volker Lendecke
88f5215560 s3: Slightly simplify Get_Pwnam_alloc 2011-02-20 10:23:29 +01:00
Volker Lendecke
13bfae95e7 s3: Fix some nonempty blank lines 2011-02-20 10:23:28 +01:00
Andrew Bartlett
1ad8e5229f lib/util/charset Add back setlocale(), but only when called from binaries
When called from a library, we don't want to call this, as we may
overwrite some of our calling program's context.

Andrew Bartlett

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Fri Feb 18 09:29:35 CET 2011 on sn-devel-104
2011-02-18 09:29:35 +01:00
Andrew Bartlett
2a3a86a86f lib/util/charcnv Move iconv handle setup in common
We now use the struct smb_iconv_convenience at the core of all our
iconv code, and use global_iconv_convenience for the callers that
don't specify one.

Andrew Bartlett
2011-02-18 18:41:01 +11:00
Andrew Bartlett
5155a5f5c1 s3-charcnv Don't genreate valid_table on the fly, rely on valid.dat
This file is always installed, and is only even required for the old,
depricated mangle hash method.

Andrew Bartlett
2011-02-18 18:41:01 +11:00
Andrew Bartlett
8afc271e2a lib/util/charset Use top level iconv.c in source3
The two files were very similar already, the only change required was
to adopt the s3 module registration fucntion name.

(NTSTATUS wasn't used as the charset code does not otherwise use that
type).

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-02-18 18:41:00 +11:00
Andrew Bartlett
92faeaeea8 charset Remove use of {isupper,islower,toupper,tolower}_w functions
These now call the common _m functions that consider UTF16 code points.

This removes the code which will make up a 'lame' table in memory, as
this can just as correctly be handled by running the algorithm at runtime (which is to call toupper() and tolower() on characters < 128).

When used, a top level waf build will always locate the correct table
- in the build tree or outside - due to relinking the installed
binary.

Andrew Bartlett
2011-02-18 17:00:34 +11:00
Andrew Bartlett
09c4a5cd9b s3-cluster Always fill in the clustering vnn element
This avoids this structure being partially uninitialised.

Adnrew Bartlett
2011-02-17 16:02:19 +01:00
Günther Deschner
bc83400d81 nsswitch: make wb_reqtrans a common subsystem.
Guenther
2011-02-17 00:52:42 +01:00
Günther Deschner
80b4e1e985 s3: move some defines to a better place.
Guenther
2011-02-14 11:47:19 +01:00
Volker Lendecke
26051b8aaa s3: Use tlap_simple_recv in tldap_sasl_bind_recv 2011-02-13 12:11:53 +01:00
Volker Lendecke
f6df16d9d2 s3: Add error checking to asn1_read_OctetString_talloc 2011-02-13 12:11:53 +01:00
Volker Lendecke
80accd3946 Fix typos 2011-02-13 12:11:53 +01:00
Volker Lendecke
fe551d6815 s3: Convert tldap_entry_values args to "array, count" 2011-02-13 12:11:53 +01:00
Volker Lendecke
84abb428f6 s3: Add an explicit counter to tldap_add_mod_[blobs|str] 2011-02-13 12:11:53 +01:00
Volker Lendecke
158c1e315b s3: Convert tldap_make_mod_fmt args to "array, count" 2011-02-13 12:11:52 +01:00
Volker Lendecke
6375e6993e s3: Convert tldap_make_mod_blob args to "array, count" 2011-02-13 12:11:52 +01:00
Volker Lendecke
67e6874651 s3: Convert tldap_make_mod_blob_int args to "array, count" 2011-02-13 12:11:52 +01:00
Volker Lendecke
3363bab875 s3: Convert tldap_add_blob_vals args to "array, count" 2011-02-13 12:11:52 +01:00
Volker Lendecke
6b492a1741 s3: Convert tldap_add_mod_blobs args to "array, count" 2011-02-13 12:11:52 +01:00
Volker Lendecke
90c8de54a0 s3: Add more checks and better fallback to addrchange
From http://netsplit.com/2011/02/09/the-proc-connector-and-socket-filters/ I
learned a bit more about netlink...

Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Fri Feb 11 10:47:09 CET 2011 on sn-devel-104
2011-02-11 10:47:09 +01:00
Volker Lendecke
efa460e291 s3: Align the args in tldap_modify
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Thu Feb 10 23:20:05 CET 2011 on sn-devel-104
2011-02-10 23:20:05 +01:00
Volker Lendecke
b524e58f9a s3: Align tldap_add and tldap_add_send 2011-02-10 22:34:01 +01:00
Günther Deschner
fa0c6c1a9e s3-system: fix malloc/talloc mismatch in sys_popen().
Guenther
2011-02-10 18:37:18 +01:00
Andrew Bartlett
2b05ba77b4 s3-auth Rename cryptic 'ptok' to security_token
This will allow the auth_serversupplied_info struct to be migrated
to auth_session_info easier.

Adnrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-02-10 06:51:06 +01:00
Jeremy Allison
c377b0e718 Fix up some buildfarm warnings. 2011-02-09 21:21:04 +01:00
Michael Adam
015b47fa14 s3:popt: add POPT_COMMON_OPTION to provide only the "--option" feature 2011-02-09 14:00:34 +01:00
Jeremy Allison
1911d483e5 Add fdopendir(). 2011-02-08 15:05:59 -08:00
Volker Lendecke
5a0ee95b95 s3: Fix some nonempty blank lines and some typos
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed Feb  9 00:01:45 CET 2011 on sn-devel-104
2011-02-09 00:01:45 +01:00
Günther Deschner
34722c72f6 pam: share pam errors in a common location.
Guenther
2011-02-08 14:05:36 +01:00
Günther Deschner
be5edba117 libndr: share some uuid helpers.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Feb  8 09:52:56 CET 2011 on sn-devel-104
2011-02-08 09:52:56 +01:00
Stefan Metzmacher
e9c45a3973 s3:lib/addrchange: set ctx->sock to -1 after close
The makes the code more consistent with similar destructors.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Fri Feb  4 15:52:55 CET 2011 on sn-devel-104
2011-02-04 15:52:55 +01:00
Stefan Metzmacher
d8d5a3fb3a s3:lib/addrchange: remove unused pointer
metze
2011-02-04 15:04:58 +01:00
Stefan Metzmacher
ff935ddf8b s3:lib/addrchange: let addrchange_done() retry and ignore unknown message types
Messages like RTM_NEWLINK should be just ignored.

metze
2011-02-04 15:04:58 +01:00
Stefan Metzmacher
91e1c8dc38 s3:lib: allow_trailing_dollar should only allow '$'
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Thu Feb  3 00:33:48 CET 2011 on sn-devel-104
2011-02-03 00:33:48 +01:00
Günther Deschner
e32b50894b s3-libnetapi: prefer dcerpc_lsa_X functions.
Guenther
2011-02-02 19:02:09 +01:00
Günther Deschner
50be0b2c1e s3: Remove superfluous ;
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Wed Feb  2 15:44:21 CET 2011 on sn-devel-104
2011-02-02 15:44:21 +01:00
Volker Lendecke
1c9cf16c95 s3: Fix the build on sles8
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Tue Feb  1 18:34:33 CET 2011 on sn-devel-104
2011-02-01 18:34:33 +01:00
Volker Lendecke
80acca1ebf s3: Add support for AF_NETLINK addr notifications
Via an AF_NETLINK socket, the Linux kernel can inform us when IP addresses are
added or dropped.

This will first be used in winbind, it was triggered by clustering with ctdb.
When winbind is connected to a domain controller and ctdb decides to move away
the IP address that winbind used locally for the connection to the DC, the next
request will run into a timeout. winbind sends out its request, but the
response will never arrive: The IP is gone.

It will also be interesting for more reliable online/offline detection, but
this is something for future winbind refactoring.
2011-02-01 15:11:06 +01:00
Günther Deschner
f9af242886 s3-libnetapi: prefer dcerpc_samr_X functions in lib/netapi/user.c.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Feb  1 13:41:42 CET 2011 on sn-devel-104
2011-02-01 13:41:42 +01:00
Günther Deschner
32fb4f5206 s3-libnetapi: prefer dcerpc_samr_X functions in lib/netapi/samr.c.
Guenther
2011-02-01 12:49:58 +01:00
Günther Deschner
b76657f8d9 s3-libnetapi: prefer dcerpc_samr_X functions in lib/netapi/localgroup.c.
Guenther
2011-02-01 12:49:52 +01:00
Günther Deschner
7f63018117 s3-libnetapi: prefer dcerpc_samr_X functions in lib/netapi/group.c.
Guenther
2011-02-01 12:49:44 +01:00
Stefan Metzmacher
ad10289ebc s3:lib/events: use DLIST_DEMOTE() for fd events
This makes sure that fd events doesn't dry out,
because a fd with a lower number is busy.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Mon Jan 31 16:59:44 CET 2011 on sn-devel-104
2011-01-31 16:59:44 +01:00
Stefan Metzmacher
1f2be10ebf s3:lib/events: don't loop over fd events is select gave -1
metze
2011-01-31 16:16:09 +01:00
Stefan Metzmacher
19d3779274 Revert "s3:events: Call all ready fd event handlers on each iteration of the main loop"
This reverts commit 455fccf86b.

I'll add a more generic fix for this problem.

metze
2011-01-31 16:16:09 +01:00
Günther Deschner
1232fb5a1e s3-rpc_client: remove some more obsolete cli_X.h header files.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Fri Jan 28 11:18:44 CET 2011 on sn-devel-104
2011-01-28 11:18:44 +01:00