1
0
mirror of https://github.com/samba-team/samba.git synced 2025-10-28 03:33:13 +03:00
Commit Graph

215 Commits

Author SHA1 Message Date
Andrew Bartlett
177b713288 r17534: Try another group for 'wheel' on True64. 2007-10-10 14:15:34 -05:00
Andrew Bartlett
009d090594 r17499: Open the main database only the minimum times during a provision.
This causes things to operate as just one transaction (locally), and
to make a minimum of TCP connections when connecting to a remote LDAP
server.

Taking advantage of this, create another file to handle loading the
Samba4 specific schema extensions.  Also comment out 'middleName' and
reassign the OID to one in the Samba4 range, as it is 'stolen' from a
netscape range that is used in OpenLDAP and interenet standards for
'ref'.

Andrew Bartlett
2007-10-10 14:15:30 -05:00
Andrew Bartlett
31225b9cb6 r17330: Enable the partitions module.
This module redirects various samdb requests into different modules,
depending on the prefix.  It also makes moving to an LDAP backend
easier, as it is just a different partition backend.

This adds yet another stage to the provision process, as we must setup
the partitions before we setup the magic attributes.

Andrew Bartlett
2007-10-10 14:15:15 -05:00
Simo Sorce
a89cc346b9 r17206: Add a modular API for share configuration.
Commit the classic backwards compatible module which is the default one
2007-10-10 14:10:18 -05:00
Andrew Bartlett
82f5f6c03d r16265: Fix 'newuser' command.
Andrew Bartlett
2007-10-10 14:09:09 -05:00
Andrew Bartlett
b49a4fbb57 r16264: Add, but do not yet enable, the partitions module.
This required changes to the rootDSE module, to allow registration of
partitions.  In doing so I renamed the 'register' operation to
'register_control' and 'register_partition', which changed a few more
modules.

Due to the behaviour of certain LDAP servers, we create the baseDN
entry in two parts: Firstly, we allow the admin to export a simple
LDIF file to add to their server.  Then we perform a modify to add the
remaining attributes.

To delete all users in partitions, we must now search and delete all
objects in the partition, rather than a simple search from the root.
Against LDAP, this might not delete all objects, so we allow this to
fail.

In testing, we found that the 'Domain Controllers' container was
misnamed, and should be 'CN=', rather than 'OU='.

To avoid the Templates being found in default searches, they have been
moved to CN=Templates from CN=Templates,${BASEDN}.

Andrew Bartlett
2007-10-10 14:09:09 -05:00
Andrew Bartlett
4e8d7b7fb3 r16063: Make is clearer when we can't write to the smb.conf
Find more possible posix group names for the 'domain users' group, as
the existing options don't exist in OSX.

Andrew Bartlett
2007-10-10 14:08:55 -05:00
Stefan Metzmacher
e896c32614 r15077: map SID_BUILTIN_USERS
metze
2007-10-10 14:04:07 -05:00
Andrew Bartlett
0859ba59ae r14200: Now we have real USN support, don't force the values in the provision
scripts.

This tests the real module, and avoids duplication.

Andrew Bartlett
2007-10-10 13:56:59 -05:00
Simo Sorce
3fb9571a76 r13369: let's have a way to show the samba4 version through ejs
and use it in provisioning to fullfill rfc 3045 requirements
2007-10-10 13:51:50 -05:00
Andrew Tridgell
dc74d8ccf1 r13102: fixed the vampire code to correctly setup foreign sids and default
unix name mappings
2007-10-10 13:51:25 -05:00
Andrew Tridgell
0cacd69dd5 r13098: make check for workgroup and realm case insensitive 2007-10-10 13:51:24 -05:00
Andrew Tridgell
95e90169f4 r13097: move the creation of the default sam name -> unix name mappings into
the main provision logic, so it can also be used as part of the
vampire process
2007-10-10 13:51:24 -05:00
Stefan Metzmacher
b7a0a778cc r13084: fix 'make test'!
I would sugguest to run 'make test && make valgrind' before each commit
at this stage...

metze
2007-10-10 13:51:23 -05:00
Andrew Tridgell
1c49ce8df0 r13076: catch a easy to make error during vampire install 2007-10-10 13:51:22 -05:00
Jelmer Vernooij
cc4cab341e r13062: Fix upgrade of WINS entries 2007-10-10 13:51:20 -05:00
Andrew Tridgell
c7951d17b1 r12947: added some error checking that I stumbled across while testing domain migration 2007-10-10 13:51:12 -05:00
Andrew Bartlett
701558b5fe r12945: Try to move closer to getting Samba3 import working again.
There still a few things to work out

Andrew Bartlett
2007-10-10 13:51:12 -05:00
Andrew Bartlett
def3195618 r12929: Fix more implict global and shadowing variables.
Andrew Bartlett
2007-10-10 13:51:07 -05:00
Andrew Bartlett
a38ceefd11 r12928: This patch improves the interaction between the vampire and provsion code.
Previously, we had to know (or guess) the host and domain guid at the
provision stage.  Now we query the database post-provision, to extract
the values and fill in the zone file.

This allows us to generate a correct zone file in the Windows migration case.

In an effort to make SWAT easier to use, I have removed and renamed
some of the provision options.

I have also fixed a nasty issue in my js code.  I had implictly
declared a global variable of the name 'join', with disasterious
results for any subsequent user of the string utility function:

esp exception - ASSERT at lib/appweb/ejs/ejsParser.c:2064, 0

Backtrace:
        [ 0]       substitute_var:20   ->               list[i] = join("", list2)
        [ 1]           setup_file:9    ->       data = substitute_var(data, subobj)

Andrew Bartlett
2007-10-10 13:51:07 -05:00
Andrew Bartlett
a5e7c17c34 r12892: Add a 'Migrate from Windows' page to our installation section in SWAT.
Doing this required reworking ejsnet, particularly so it could take a
set of credentials, not just a username and password argument.

This required fixing the ejsnet.js test script, which now adds and
deletes a user, and is run from 'make test'.  This should prevent it
being broken again.

Deleting a user from ejsnet required that the matching backend be
added to libnet, hooking fortunetly onto already existing code for the
actual deletion.

The js credentials interface now handles the 'set machine account' flag.

New functions have been added to provision.js to wrap the basic
operations (so we can write a command line version, as well as the web
based version).

Andrew Bartlett
2007-10-10 13:50:59 -05:00
Andrew Bartlett
7b169aad3f r12891: We no longer manually set the 'name' attribute.
Andrew Bartlett
2007-10-10 13:50:58 -05:00
Andrew Bartlett
002cdcf3ca r12823: Fix up the provison and newuser code in SWAT. This also cleans up the
main provision script a bit, as the argument list was getting out of
control.  (It has been replaced in part with an object).

This also returns the session_info from the auth code into ejs.

We still need access control allowing only root to re-provision.

Andrew Bartlett
2007-10-10 13:50:02 -05:00
Andrew Bartlett
42cdad5e3f r12749: Fix the newuser script.
Andrew Bartlett
2007-10-10 13:49:49 -05:00
Andrew Bartlett
b349d2fbfe r12739: Add support for using credentials in the provision process.
This should allow us to provision to a 'normal' LDAP server.

Also add in 'session info' hooks (unused).  Both of these need to be
hooked in on the webserver.

Andrew Bartlett
2007-10-10 13:49:48 -05:00
Jelmer Vernooij
5884a7efff r12704: role => server role 2007-10-10 13:49:43 -05:00
Jelmer Vernooij
4c562c42b4 r12703: Fix handling of short passdb backends (also reported by Steinar Gunderson) 2007-10-10 13:49:43 -05:00
Jelmer Vernooij
10da56fb6c r12699: correctly escape invalid DN characters (reported by Steinar H. Gunderson).
this still doesn't work as a bug in ldb causes it to not understand
escaped characters in DNs when parsing DNs
2007-10-10 13:49:41 -05:00
Jelmer Vernooij
3d70ebca0b r12697: Support empty fullname fields in unix accounts 2007-10-10 13:49:40 -05:00
Jelmer Vernooij
f4ac7d6359 r12695: A dot is allowed in NetBIOS names. 2007-10-10 13:49:39 -05:00
Andrew Bartlett
fe36cb6767 r12533: Get the ldb.errstring() out to the user on failure. It helps a lot
with debugging!

Andrew Bartlett
2007-10-10 13:47:52 -05:00
Andrew Bartlett
175f616d74 r12252: With this change (hack) we can now do an provision onto Samba4's LDAP
server.  Now to try another one...

Andrew Bartlett
2007-10-10 13:47:24 -05:00
Andrew Bartlett
ae2f3a64ee r12227: I realised that I wasn't yet seeing authenticated LDAP for the ldb
backend.

The idea is that every time we open an LDB, we can provide a
session_info and/or credentials.  This would allow any ldb to be remote
to LDAP.  We should also support provisioning to a authenticated ldap
server.

(They are separate so we can say authenticate as foo for remote, but
here we just want a token of SYSTEM).

Andrew Bartlett
2007-10-10 13:47:22 -05:00
Andrew Bartlett
6b75573df4 r11995: A big kerberos-related update.
This merges Samba4 up to current lorikeet-heimdal, which includes a
replacement for some Samba-specific hacks.

In particular, the credentials system now supplies GSS client and
server credentials.  These are imported into GSS with
gss_krb5_import_creds().  Unfortunetly this can't take an MEMORY
keytab, so we now create a FILE based keytab as provision and join
time.

Because the keytab is now created in advance, we don't spend .4s at
negprot doing sha1 s2k calls.  Also, because the keytab is read in
real time, any change in the server key will be correctly picked up by
the the krb5 code.

To mark entries in the secrets which should be exported to a keytab,
there is a new kerberosSecret objectClass.  The new routine
cli_credentials_update_all_keytabs() searches for these, and updates
the keytabs.

This is called in the provision.js via the ejs wrapper
credentials_update_all_keytabs().

We can now (in theory) use a system-provided /etc/krb5.keytab, if

krb5Keytab: FILE:/etc/krb5.keytab

is added to the secrets.ldb record.  By default the attribute

privateKeytab: secrets.keytab

is set, pointing to allow the whole private directory to be moved
without breaking the internal links.
2007-10-10 13:46:56 -05:00
Andrew Tridgell
4b56c129c6 r11956: removed the old rootdse.ldif, and the provision.js code that uses it 2007-10-10 13:46:50 -05:00
Stefan Metzmacher
acd3e644e0 r11781: rename tree to tcons to match the sessions substructure of smbsrv_connection
metze
2007-10-10 13:46:26 -05:00
Andrew Tridgell
696fa87a21 r11501: change provision code to use the new display specifiers 2007-10-10 13:45:45 -05:00
Andrew Tridgell
25131efea8 r11500: fixed a bug in the variable substition code using the new limit argument to split() 2007-10-10 13:45:45 -05:00
Andrew Tridgell
cbbce4fe40 r11496: add a minimal ads-compatible schema into our sam.ldb setup. This is
needed for mmc management of Samba4.
2007-10-10 13:45:45 -05:00
Andrew Tridgell
daa9dcd8f4 r11475: removed a extraneous ldb_delete() call (i had it there for debugging) 2007-10-10 13:45:42 -05:00
Andrew Tridgell
91dfe304cf r11474: - enable ldb transactions from ejs
- speed up provisioning a bit using a ldb transaction (also means you
  can't end up with a ldb being half done)
2007-10-10 13:45:41 -05:00
Andrew Tridgell
ebdd1393fd r11458: fixed our ejs smbscript interfaces to use arrays where appropriate. In
js arrays are a special type of object where the length property is
automatic, and cannot be modified manually. Our code was manually
setting length, which made it abort when someone passed in a real ejs
array. To fix this we need to create real arrays instead of objects,
and remove the code that manually sets the length
2007-10-10 13:45:39 -05:00
Andrew Tridgell
62d5253a03 r11363: fixed a problem with provisioning when hklm already exists (the
problem is really caused by hklm not having objectclass attributes on
its records, but this is a workaround)
2007-10-10 13:45:26 -05:00
Andrew Tridgell
27f46b4f18 r11285: fixed winreg.js for the recent change to winreg.idl 2007-10-10 13:45:13 -05:00
Andrew Bartlett
10d692a1c2 r11222: Small provision fixes: canonicalName is now generated, and the DC=
list should be from the dnsdomain (ie lowercae).

Andrew Bartlett
2007-10-10 13:45:05 -05:00
Andrew Bartlett
0c29f0e30d r11217: Ensure the realm is substituted in UPPER case.
Andrew Bartlett
2007-10-10 13:45:04 -05:00
Andrew Bartlett
df6a40c2d2 r11203: Use different variable names to make it easier to tell which assert fired.
Andrew Bartlett
2007-10-10 13:45:01 -05:00
Stefan Metzmacher
9f3b6746d8 r11087: - add type,name,scope as attributes to winsRecords,
so you can use them in search filters,
  only for administration not used inside the winserver code
- fix the samba3 ugrade scripts to create a correct samba4 wins.ldb

metze
2007-10-10 13:44:46 -05:00
Jelmer Vernooij
c5e3a1c55d r10515: Handle replacement of "domain logons" and "domain master" by "server role" 2007-10-10 13:38:59 -05:00
Andrew Tridgell
173655aec2 r10193: r11632@blu: tridge | 2005-08-30 23:08:27 +1000
if we fail to erase a ldb during provision by traversing
 and deleting records (an in-place erase) then just unlink it
 and start it again. This makes provisioning much more robust
 to changes in ldb that make it not backward compatible with
 old DBs.
2007-10-10 13:38:07 -05:00