1
0
mirror of https://github.com/samba-team/samba.git synced 2025-11-08 16:23:49 +03:00
Commit Graph

40 Commits

Author SHA1 Message Date
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
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
Andrew Tridgell
696fa87a21 r11501: change provision code to use the new display specifiers 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
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 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
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
Jelmer Vernooij
87f25fe49c r10190: Do some very basic input checking when provisioning. 2007-10-10 13:38:06 -05:00
Jelmer Vernooij
488d737fb0 r9816: Work on testsuite for upgrade
Add 'paths' object to provision code.
2007-10-10 13:35:04 -05:00
Jelmer Vernooij
d9541535e3 r9770: Couple other bugfixes
Update TODO-list
2007-10-10 13:34:58 -05:00
Jelmer Vernooij
a8f309aa81 r9756: One-way upgrade from Samba3->Samba4 basically works now
Still need to polish some rough edges
2007-10-10 13:34:56 -05:00
Jelmer Vernooij
b1d9ef8998 r9746: Add "staff" as possible alternative to wheel
(should fix standard provisioning on AIX)
2007-10-10 13:34:56 -05:00
Andrew Tridgell
a22d0d02ee r9707: r11080@blu: tridge | 2005-08-28 12:41:12 +1000
make sure we leave the account enabled after creating a new user
2007-10-10 13:34:52 -05:00
Andrew Bartlett
1f071b0609 r8790: Finish the migration of aliases and privilages with SamSync, by adding
templating support for foreignSecurityPrincipals to the samdb module.
This is an extension beyond what microsoft does, and has been very
useful :-)

The setup scripts have been modified to use the new template, as has
the SAMR and LSA code.

Other cleanups in LSA remove the assumption that the short domain name
is the first component of the realm.

Also add a lot of useful debug messages, to make it clear how/why the
SamSync may have gone wrong.  Many of these should perhaps be hooked
into an error string.

Andrew Bartlett
2007-10-10 13:30:05 -05:00
Andrew Bartlett
2303e24be7 r8677: The first part of the domain name may not be equal to the netbios domain name.
Remove the use of flatname from the main domain object, we no longer
reference it.

Andrew Bartlett
2007-10-10 13:29:53 -05:00
Andrew Bartlett
4a8ef7197f r8660: Use templates for the initial provision of user and computer accounts.
This ensures the templating code is used, and also makes it clearer
what I need to duplicate in the vampire area.

Also fix a silly bug in the template application code (the samdb
module) that caused templates to be compleatly unused (my fault, from
my commit last night).

Andrew Bartlett
2007-10-10 13:29:51 -05:00
Andrew Bartlett
940ed9827f r8650: Use the timestamps and a new objectguid module rather than placing
boilerplate attributes in every entry in provision.ldif.

The next step will be to use templates.

Andrew Bartlett
2007-10-10 13:29:50 -05:00
Andrew Tridgell
78fb559c08 r8648: automatically redirect to provisioning if not yet provisioned when the
home page in swat is accessed
2007-10-10 13:29:49 -05:00
Andrew Tridgell
c2691ef712 r8643: - make lp_configfile() work again
- get rid of redundeny dyn_CONFIGFILE argument to lp_load()

- fixed provisioning to work with completely pristine install,
  creating an initial smb.conf is none is present

- added lp.set() and lp.reload() to loadparm ejs object interface
2007-10-10 13:29:48 -05:00
Andrew Tridgell
ed4fb68ef7 r8640: continue the trend by moving the ejs random calls into an object 2007-10-10 13:29:48 -05:00
Andrew Tridgell
2dc493eea6 r8639: moved loadparm calls into an ejs object 2007-10-10 13:29:48 -05:00
Andrew Tridgell
1183f54c8d r8603: we have to use the same db name as the rest of smbd uses so the ldb connect
works when already open
2007-10-10 13:29:44 -05:00
Andrew Tridgell
71004aa165 r8570: delete all records in the old db when provisioning, rather than using
sys.unlink(). This allows smbd to see the new db without restarting.
2007-10-10 13:29:39 -05:00
Andrew Tridgell
a3f3292e66 r8561: as with the other ejs subsystems, make nss into a object 2007-10-10 13:29:38 -05:00
Andrew Tridgell
b6ef32ddd1 r8558: move newuser logic into the provision.js lib 2007-10-10 13:29:37 -05:00
Andrew Tridgell
cf35818648 r8488: after discussions with simo, moved to a full OO interface, so you don't need to keep
a 'db' variable around. The ldb object knows what it is connected to.

Added a simple ldb testsuite in testprogs/ldb.js
2007-10-10 13:23:08 -05:00
Andrew Tridgell
98c9c4ecb8 r8486: switched to a separate connection operation in ldb interface
(a suggestion from simo)
2007-10-10 13:23:08 -05:00
Andrew Tridgell
9991e924e9 r8484: switched the sys_*() calls to the OO interface
tim, do you want to do the cli_*() calls now?
2007-10-10 13:23:08 -05:00
Andrew Tridgell
3093057d97 r8481: switched ldb ejs called over to an OO interface, so you do:
var ldb = ldb_init();

res = ldb.search(dbfile, "(objectClass=user)");

you can also do:

ldbSearch = ldb.search;
res = ldbSearch(dbfile, "(objectClass=user)");

if you want the old interface (ie. you can use this to import
functions into the global or local namespace).
2007-10-10 13:23:07 -05:00
Andrew Tridgell
433f9d0a61 r8445: if a system doesn't have "nogroup" then try "nobody" 2007-10-10 13:23:04 -05:00
Andrew Tridgell
7476cb9413 r8372: - split out provisioning logic into a separate ejs library
- added a provisioning web page
2007-10-10 13:20:13 -05:00