summaryrefslogtreecommitdiffstats
path: root/python
Commit message (Collapse)AuthorAgeFilesLines
...
* tests: Allow "max open files" to differ from the documentationAndrew Bartlett2014-10-171-1/+2
| | | | | | | | | | It is system-dependent. Andrew Bartlett Change-Id: Icf21476c00295a428ad808bc56ab8153f109627f Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* urgent_replication: Use subunit reporting, remove allow_empty_output.Jelmer Vernooij2014-10-141-2/+5
| | | | | | Change-Id: I6d479b218eff6c4292fbb99e4760bbd62ce1f380 Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* samba.tests.unicodenames: Fix docstring formatting so pydoctor understands it.Jelmer Vernooij2014-10-141-3/+2
| | | | | | Change-Id: I8983cd4483c380fd0c9e4da843eb70750450a0fa Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* samba_tool_drs: Fix docstring formatting so pydoctor groks it.Jelmer Vernooij2014-10-141-23/+28
| | | | | | Change-Id: I827044ef876118935b0f91e318d3c815326a2f01 Signed-off-by: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* samba.tests.source: Fix lint.Jelmer Vernooij2014-10-141-2/+2
| | | | | | Change-Id: I3dc614c34aa2c4fca6f2ca68196e71b9129b5b76 Signed-off-by: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* Remove obsolete pep8 test.Jelmer Vernooij2014-10-141-54/+0
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: I7f6634a035e9c93820cd4eef0261ecd5dd3865ab
* Fix more pep8 issues in code I touched recently.Jelmer Vernooij2014-10-146-27/+41
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: I35f3204bdf5d00b3280d703427ded2fa2163a6f7
* Remove last instances of pep8 error E602 (old style exceptions).Jelmer Vernooij2014-10-141-3/+3
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: If709757643e6eed8cffa8950170c337f51edb9d9
* Remove last instance of pep8 error E701 (more statements on one line).Jelmer Vernooij2014-10-141-1/+2
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: I419f0536b43d98ce6bb52c5907413a02ea1a6937
* Remove remaining instance of pep8 E211 (too many spaces before operator).Jelmer Vernooij2014-10-144-19/+19
| | | | | | Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Change-Id: I9af3bf582bba8fc1094addb12cd0a5ce04406b5b
* tests: Pass the test context as lp_ctx for messaging testsMatthieu Patou2014-10-081-1/+2
| | | | | Change-Id: I1acf5c42b21465a8c45549039f0054414b8f31d1 Signed-off-by: Matthieu Patou <mat@matws.net>
* provision: Change the default functional level of new Samba domains to 2008R2.Andrew Bartlett2014-09-302-3/+3
| | | | | | | Windows 2003 is going out of support shortly, and we want users to have AES by default Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* provision: explain why this is requiredAndrew Bartlett2014-09-271-0/+8
| | | | | | Change-Id: Iaf8b13010b52e03db2eefe1ad565d7ca768ffb48 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* samba-tool: fix reply when zero day pwd expiry is setBjörn Jacke2014-09-081-4/+4
| | | | | | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=10318 Signed-off-by: Bjoern Jacke <bj@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Björn Jacke <bj@sernet.de> Autobuild-Date(master): Mon Sep 8 14:15:51 CEST 2014 on sn-devel-104
* join.py: Set NT ACL on crossRef object for new partitionAndrew Bartlett2014-09-022-4/+14
| | | | | | | | | | Change-Id: Icb1b00697cc5641481370ded26f2f0551a5b2a97 Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Tue Sep 2 14:15:54 CEST 2014 on sn-devel-104
* samba-tool/ldapcmp: update the list of non replicated attributesStefan Metzmacher2014-09-021-13/+49
| | | | | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=10788 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Tue Sep 2 03:49:49 CEST 2014 on sn-devel-104
* join.py: Ensure to fill in samAccountName so we get the domain$ accountAndrew Bartlett2014-09-011-1/+2
| | | | | | | | | | Otherwise, we get a random samAccountName Andrew Bartlett Change-Id: I87ea532fe22c1b2d2effd52859da3b357f692b5a Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* provision: Only create hard links for ForestDnsZones if it exists on this DCAndrew Bartlett2014-09-011-4/+8
| | | | | | | | | | We might be a subdomain, and not host this partition. Andrew Bartlett Change-Id: I9aa32c5692cd9fd0a6bced8bea37cd8593b31906 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
* join.py: Ensure we set the SID of the parent domain on the trust recordAndrew Bartlett2014-09-011-1/+2
| | | | | | | Change-Id: Ifaf3f2d1240d983a48ee1874fdc9c266354f6754 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
* python: Use the security.dom_sid type for ctx.domsid in join.py and provisionAndrew Bartlett2014-09-015-9/+11
| | | | | | | Change-Id: I1266f77184d68aae6a39a73bac8a432fdd707b2e Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
* provision: Use names.domainsid and names.domainguidAndrew Bartlett2014-09-013-46/+55
| | | | | | | | | | | | | This is better than passing around parameters to functions all over the provision stack and makes it easier to pass in a seperate forest SID when we start to support subdomains. Change-Id: I3787f4f3433ca04628f888135c7c0c8195379542 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Pair-programmed-with: Garming Sam <garming@catalyst.net.nz> Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
* provision: Only calculate ForestDNSZone GUID if we need itAndrew Bartlett2014-09-011-5/+4
| | | | | | | Change-Id: Ie33812627ce7ececda681c2d784b1ca97b1b73c4 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
* join.py: Reinstate full_nc_list and make creation of NTDS-DSA object commonAndrew Bartlett2014-09-011-32/+34
| | | | | | | | | | | | The new function join_ntdsdsa_obj() returns the object, to be added over LDAP or DsAddEntry(). Andrew Bartlett Change-Id: I41ac256fb3d4edffc617af4ae580acd941b4de83 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>
* samba.netcmd.domain: desactivating -> deactivating.Jelmer Vernooij2014-08-311-1/+1
| | | | | | Change-Id: I463823589049e81bcd4032f3e7bc6b5f2fb0d28d Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org>
* samba.netcmd.domain: Fix incorrect variable names, causing NameErrors.Jelmer Vernooij2014-08-311-4/+4
| | | | | | Change-Id: I1c78f07f942a8b03ac88de98b18ac636b7124e22 Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org>
* samba.netcmd.domain: Remove unused import.Jelmer Vernooij2014-08-311-1/+0
| | | | | | Change-Id: I33f3ba55540be01fd15bfc3d75ebb73cbf5ead9e Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org>
* samba.netcmd.domain: Just catch ImportError, not any parsing errors in ↵Jelmer Vernooij2014-08-311-2/+3
| | | | | | | | cmd_domain_export_keytab. Change-Id: If5710565c74e87fe218a83f31cddcf64605e522e Signed-Off-By: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org>
* python/join: use lowercase for the dnshostname.Stefan Metzmacher2014-08-261-2/+2
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* Redescribe --userou usageMarc Muehlfeld2014-08-061-2/+2
| | | | | Signed-off-by: Marc Muehlfeld <mmuehlfeld@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org>
* tests: dnsserver: Remove duplicate empty test functionAmitay Isaacs2014-07-301-4/+0
| | | | | | | | | | This test function is defined further in the file. Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Wed Jul 30 07:00:57 CEST 2014 on sn-devel-104
* tests: dnsserver: Add a update test with name set to '.'Amitay Isaacs2014-07-291-1/+40
| | | | | | | | Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Tue Jul 29 19:33:19 CEST 2014 on sn-devel-104
* dbcheck: Add check and test for various invalid userParameters valuesAndrew Bartlett2014-07-091-0/+90
| | | | | | | Bug: https://bugzilla.samba.org/show_bug.cgi?id=8077 Change-Id: I6f2f4169856ce78c62e3a7e74b48520cca9cb9ae Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* param: Amend docs.py test to check dumping of flagged parametersGarming Sam2014-07-081-1/+70
| | | | | | | | | | | | | | | | | This test uses an empty smb.conf file to check if the resulting output from testparm is empty. It also sets a parameter as default in an smb.conf file and then sets the option on the command line to ensure they are displayed correctly. Change-Id: I48f05b6e3c9e5cd856e89b196e00ae35eb93bf9f Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Tue Jul 8 01:57:59 CEST 2014 on sn-devel-104
* param: remove idmap parameters as special cases in docs.pyGarming Sam2014-07-071-3/+0
| | | | | | | Change-Id: Ie2395ddbe9e055b9972fd859615a022d9f675014 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: handle smb_ports as a special handlerGarming Sam2014-07-071-2/+4
| | | | | | | | | | Avoids some problems with using str_list_make and str_list_make_v3 and tries to verify if the ports assignment is reasonable Change-Id: I441c4cca605c7548a5023b65994004fbac57d2df Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* samba-tool domain: remove duplicate check if site is setBjörn Baumbach2014-06-181-3/+0
| | | | | | Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
* samba-tool: add --site parameter to provision commandBjörn Baumbach2014-06-181-1/+4
| | | | | | | | | This new parameter offers the option to specify a default initial site name. Otherwise it will be "Default-First-Site-Name". Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
* provision/sambadns: remove redundant site parameterBjörn Baumbach2014-06-182-3/+4
| | | | | | | | The sitename is already included in "names" parameter. Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Kamen Mazdrashki <kamenim@samba.org>
* tests: Add doc exception for spoolss: OSVERSION.Andreas Schneider2014-05-231-1/+2
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Fri May 23 20:10:49 CEST 2014 on sn-devel-104
* provision: Correctly provision the SOA record minimum TTLKai Blin2014-05-212-0/+2
| | | | | | | | | | This fixes bug #10466 Signed-off-by: Kai Blin <kai@samba.org> Reviewed-by: Guenter Kukkukk <kukks@samba.org> Autobuild-User(master): Kai Blin <kai@samba.org> Autobuild-Date(master): Wed May 21 10:55:00 CEST 2014 on sn-devel-104
* bug #10609: CVE-2014-0239 Don't reply to repliesKai Blin2014-05-201-0/+29
| | | | | | | | | | | | | | | | Due to insufficient input checking, the DNS server will reply to a packet that has the "reply" bit set. Over UDP, this allows to send a packet with a spoofed sender address and have two servers DOS each other with circular replies. This patch fixes bug #10609 and adds a test to make sure we don't regress. CVE-2014-2039 has been assigned to this issue. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10609 Signed-off-by: Kai Blin <kai@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Kai Blin <kai@samba.org> Autobuild-Date(master): Tue May 20 04:15:44 CEST 2014 on sn-devel-104
* docs: enable checking of parametric options assignmentGarming Sam2014-05-071-4/+2
| | | | | | Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* param: correctly use param_table.c as a regular C fileGarming Sam2014-05-071-1/+1
| | | | | | Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* docs: add test to docs.py to set parameters to some arbitrary valueGarming Sam2014-05-071-10/+93
| | | | | | | | This does not currently test enums. Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* docs: change docs.py to test the setting of parameters to defaultsGarming Sam2014-05-071-0/+39
| | | | | | Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* samba-tool ldapcmp: fix a typoBjörn Baumbach2014-05-031-2/+2
| | | | | | Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* dbcheck: Directly call dn.get_rdn_{val,name}() for clarity and consistencyAndrew Bartlett2014-05-021-18/+13
| | | | | | | | | | | | When looking for incorrect name values, this improves the previous code by avoiding one more manual parse step, and uses less cryptic variable names. Andrew Bartlett Change-Id: Iff8e571a6359a67bf173f729dc12b8787292b3cb Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Jelmer Vernooij <jelmer@samba.org>
* dbchecker: verify and fix broken dn valuesStefan Metzmacher2014-05-021-0/+94
| | | | | | | | | | | | | | | | | | | | | | | | | With older Samba versions (4.0.x) the following could happen: - On account was created on DC1 - It was replicated to DC2 - The connection between the dcs is offline - The account gets modified on DC2 - The account gets deleted on DC1 - The connection becomes online again - DC1 replicates the modification from DC2, this resets the dn to the original value. 'name' and 'cn' are correct (with '\nDEL${GUID}'), but 'dn' is wrong. - DC2 replicates the deletion from DC1. this doesn't include a changed dn as DC1 had a bug. 'name' is correct (with '\nDEL${GUID}'), but 'cn' and 'dn' are wrong. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10536 Change-Id: Ia70a6c12e0ff0d4c2c8100cb1d8f3c6422b65591 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* dbchecker: make the deleted objects container detection more genericStefan Metzmacher2014-05-021-2/+8
| | | | | | Change-Id: I282ad887c41412e25fdf73476e405f4e88e0b239 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* s4:kcc_util: fix loading connection transport object - used to refer to not ↵Kamen Mazdrashki2014-04-221-0/+1
| | | | | | | | defined object Change-Id: If8dc8e8db85f1a882ec73dc83d28fa1b5156de84 Signed-off-by: Kamen Mazdrashki <kamenim@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org>