summaryrefslogtreecommitdiff
path: root/source4/dsdb
Commit message (Collapse)AuthorAgeFilesLines
* dsdb: Fix CID 1034902 Dereference before null checkVolker Lendecke2015-06-241-1/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Wed Jun 24 01:02:22 CEST 2015 on sn-devel-104
* dsdb: Fix CID 1034687 Logically dead codeVolker Lendecke2015-06-231-3/+0
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034719 Evaluation order violationVolker Lendecke2015-06-231-3/+2
| | | | | | | We assigned lp_ctx twice... Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034802 Dereference null return valueVolker Lendecke2015-06-231-0/+4
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034742 Dereference after null checkVolker Lendecke2015-06-231-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034743 Dereference after null checkVolker Lendecke2015-06-231-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034803 Dereference null return valueVolker Lendecke2015-06-231-0/+3
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034804 Dereference null return valueVolker Lendecke2015-06-231-0/+3
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Fix CID 1034745 Dereference after null checkVolker Lendecke2015-06-231-1/+1
| | | | | | | This is a cut&paste error Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: Relax the check for the RID set DNAndrew Bartlett2015-05-281-2/+6
| | | | | | | | | | This was preventing the correct generation of error messages and referrals on an RODC. An RODC does not have a RID set. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* kcc: Wait until the samba_kcc script runs to declare success to the callerAndrew Bartlett2015-05-282-10/+100
| | | | | | | This allows us to tell if this script even executes, without looking in the logs. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* Fix segfault in the very rare case when we are not able to find the ↵Matthieu Patou2015-05-271-1/+1
| | | | | | | | | | | rootnamingcontext Signed-off-by: Matthieu Patou <mat@matws.net> Reviewed-by: Volker Lendecke <vl@samba.org> Change-Id: I96fd5c7f39280090d5ec1dcdcb445fd7a44bd1c6 Autobuild-User(master): Matthieu Patou <mat@samba.org> Autobuild-Date(master): Wed May 27 18:40:35 CEST 2015 on sn-devel-104
* lib: Remove server_id_str()Volker Lendecke2015-04-281-1/+3
| | | | | | | | | | Call server_id_str_buf instead Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Apr 28 20:48:01 CEST 2015 on sn-devel-104
* dsdb: Fix CID 1034681 Copy-paste errorVolker Lendecke2015-03-231-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s4-dsdb/samdb: use abstract functions for MIT compatibility.Günther Deschner2015-03-201-27/+32
| | | | | | | | | | | This involves switching to krb5_data, smb_krb5_get_pw_salt and smb_krb5_create_key_from_string. Guenther Signed-off-by: Günther Deschner <gd@samba.org> Pair-Programmed-With: Andreas Schneider <asn@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* dsdb-tests: Give more helpful information about attribute differencesAndrew Bartlett2015-03-201-1/+3
| | | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* dsdb: fix error message in tombstone_reanimation test.Michael Adam2015-03-171-3/+3
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* dsdb: fix error message in sam testMichael Adam2015-03-171-1/+1
| | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* lib: Remove tdb_compatVolker Lendecke2015-03-171-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* lib: Remove tdb_fetch_compatVolker Lendecke2015-03-171-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* lib: Remove tdb_errorstr_compatVolker Lendecke2015-03-171-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* lib: Remove "use_ntdb" param from secrets_init_pathVolker Lendecke2015-03-171-1/+1
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* samdb: Ignore ntdb in secrets_tdb_syncVolker Lendecke2015-03-171-8/+2
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* dsdb: fix the user_account_control test.Michael Adam2015-03-161-1/+1
| | | | | | | | | | | | | | | | | | | On my system (Fedora 21) the test fails with: [1(0)/1 at 0s] samba4.user_account_control.python(dc) teardown_env(dc) Traceback (most recent call last): File "/home/obnox/devel/samba/master-push.git/source4/dsdb/tests/python/user_account_control.py", line 23, in <module> from subunit.run import SubunitTestRunner ImportError: No module named subunit.run This fixes it for me. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Mon Mar 16 20:25:33 CET 2015 on sn-devel-104
* dsdb-repl: Always set DRSUAPI_DRS_SPECIAL_SECRET_PROCESSING when we are an RODCAndrew Bartlett2015-03-161-0/+3
| | | | | | | | | | | | Unless we are using DRSUAPI_EXOP_REPL_SECRET, always remove DRSUAPI_DRS_WRIT_REP and always set DRSUAPI_DRS_SPECIAL_SECRET_PROCESSING Otherwise, we will not work as an RODC, because replication will fail with access denied errors. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
* s4:pydsdb: add DSDB_CONTROL_PERMIT_INTERDOMAIN_TRUST_UAC_OIDStefan Metzmacher2015-03-121-0/+1
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* dsdb: Ensure we cope with a samAccountName with a space in it in DsCrackName()Andrew Bartlett2015-03-121-1/+9
| | | | | | Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* dsdb: Allow spaces in userPrincipalName valuesAndrew Bartlett2015-03-121-2/+12
| | | | | | | | This is needed to enable a kinit with a UPN that has a space in it Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* tests/sam: Remove unnecessary calls for third party module imports.Jelmer Vernooij2015-03-061-2/+0
| | | | | | Change-Id: Iaa1af59005eaee7ea79f3260b250a2c948e07532 Signed-off-by: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* Fix the O3 developer buildVolker Lendecke2015-03-031-4/+5
| | | | | | | | | | Different gcc versions complain at different places Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Tue Mar 3 13:14:53 CET 2015 on sn-devel-104
* Fix the developer O3 buildVolker Lendecke2015-02-256-6/+8
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org> Autobuild-User(master): Alexander Bokovoy <ab@samba.org> Autobuild-Date(master): Wed Feb 25 16:32:29 CET 2015 on sn-devel-104
* Update mailing list references to point at lists.samba.orgAndrew Bartlett2015-02-101-1/+1
| | | | | | | | | | | | The mailing lists are on lists.samba.org, but there are many references that use the shorthand of samba.org Some references to samba@ have been changed to samba-technical@ where this make more sense. Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Tue Feb 10 07:08:28 CET 2015 on sn-devel-104
* s4-samdb/tests: Assert on expected set of attributes for new User objectKamen Mazdrashki2015-02-031-0/+60
| | | | | | | | | | Change-Id: I225b64ff7492b41852fecb914f464a6c8d504a2c Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Tue Feb 3 07:30:17 CET 2015 on sn-devel-104
* s4-dsdb/tests: Assert on expected set of attributes for restored objectsKamen Mazdrashki2015-02-031-5/+104
| | | | | | Change-Id: I788406d9c3839d108cea508cf2a59488d495f141 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s4-dsdb: Refactor user objects defaults setter to use attribute/value mapKamen Mazdrashki2015-02-031-28/+49
| | | | | | | Change-Id: Iaa32af4225219a4c5c42c663022e8be429b8a1d2 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* dsdb: Do not use _ prefix in tombstone_reanimate moduleAndrew Bartlett2015-02-031-6/+6
| | | | | | | | | | This should only be used by the C library. Andrew Bartlett Change-Id: I00da64de1443a7c6b21aafae79e126180eb1a3d4 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
* s4-dsdb: common helper to determine "primaryGroupID" attribute valueKamen Mazdrashki2015-02-033-20/+49
| | | | | | | | | | At the moment current implementation does not check if group RID is existing group RID - this responsibility is left to the caller. Change-Id: I8c58dd23a7185d63fa2117be0617884eb78d13c1 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb: Common helper for setting "sAMAccountType" on User objectsKamen Mazdrashki2015-02-033-20/+43
| | | | | | | Change-Id: I4480e7d1ed0c754e960028e0be9a90ee56935e94 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb: Move User object default attribute values in separate helperKamen Mazdrashki2015-02-033-52/+46
| | | | | | | Change-Id: I1e291bcf0a5c9b2fca11323dc7f8be29f5145d42 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/tests: Do not pre-create LoadParm - connect_samdb_env() will handle itKamen Mazdrashki2015-02-031-5/+1
| | | | | | | Change-Id: I3483c5aa50de2f7aca19e4d7cc4fa49bbe5f889d Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb-test: Use common base method for restoring Deleted objectsKamen Mazdrashki2015-02-031-25/+14
| | | | | | | Change-Id: I266b58ced814cf7ea3616862506df5b55f4f1d8c Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/samldb: Don't allow rename requests on Deleted objectKamen Mazdrashki2015-02-031-0/+11
| | | | | | | | | | | | | | | Windows behavior in case of renaming Deleted object is: * return ERR_NO_SUCH_OBJECT in case client is not providing SHOW_DELETED control * ERR_UNWILLING_TO_PERFORM otherwise Renaming of Deleted objects is allowed only through special Tombstone reanimation modify request Change-Id: I1eb33fc294a5de44917f6037988ea6362e6e21fc Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/test: Delete any leftover objects in the beginning of Cross-NC testKamen Mazdrashki2015-02-031-2/+4
| | | | | | | | | This way we ensure that samdb is clean before we make the test Change-Id: I3c6fc94763807394e52b6df41548e9aba8b452c1 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/samldb: Relax a bit restrictions in Config partition while restoring ↵Kamen Mazdrashki2015-02-031-1/+2
| | | | | | | | | deleted object Change-Id: Iead460d24058b160b46cf3ddedaf4d84b844da4d Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/samdb: Don't relax contraint checking during rename for Deleted objectsKamen Mazdrashki2015-02-031-3/+0
| | | | | | | | | | Now we have a module to handle to handle Tombstone reanimation and it is better we do all the check here as usual Change-Id: Ia5d28d64e99f7a961cfe8b9aa7cc96e4ca56192e Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb-test/reanimate: Fix whitespaces according to PEP8Kamen Mazdrashki2015-02-031-20/+19
| | | | | | | Change-Id: I7b46992c80178d40a0531b5afd71a7783068a9dd Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb-tests: Move base tests for Tombstone reanimation in ↵Kamen Mazdrashki2015-02-032-174/+179
| | | | | | | | | | | | | | | tombstone_reanimation module So we have them all in one place. While moving, I have: * inherited from the base class for Tombstone reanimations * replace self.ldb with self.samdb Change-Id: Id3e4f02cc2e0877d736da812c14c91e2311203d2 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb-test: Fix duplicated key in a dictionary in sam.pyKamen Mazdrashki2015-02-031-2/+2
| | | | | | | Change-Id: Ie33d92bd308262d9bfda553d6d5e2cfd98f6d7b3 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb/objectclass: remove duplicated declaration for objectclass_do_addKamen Mazdrashki2015-02-031-2/+0
| | | | | | | Change-Id: Ib88a45cea64fb661a41ca3b4a3df9dabf509fc6c Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>
* s4-dsdb-test: remove trailing ';' in ldap.pyKamen Mazdrashki2015-02-031-32/+32
| | | | | | | Change-Id: I5edc6e017b576791c1575f71a625c49ccc88fe8f Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Garming Sam <garming@catalyst.net.nz>