summaryrefslogtreecommitdiff
path: root/source4/scripting
AgeCommit message (Collapse)AuthorFilesLines
2011-08-10s4: create a small script to test drsuapi/cracknameMatthieu Patou1-0/+75
2011-08-09s4-pysamba: fixed double conversion of int32Andrew Tridgell1-1/+1
if the number is already negative, we shouldn't convert it
2011-08-09s4-samdb: support relative paths in SamDB() connectAndrew Tridgell1-1/+2
don't add the private path unless the database doesn't exist with the supplied path
2011-08-09pysamdb: move normalise_int32() to common moduleAndrew Tridgell2-7/+7
this will be needed in quite a few places
2011-08-08s4:pyglue: PyArg_ParseTuple("I") requires an 'unsigned int' argumentStefan Metzmacher1-1/+5
If we pass variable references we don't get implicit casting! metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Mon Aug 8 18:01:19 CEST 2011 on sn-devel-104
2011-08-07sd_utils: Fix some formatting, add module docstring.Jelmer Vernooij1-3/+5
Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Sun Aug 7 21:07:04 CEST 2011 on sn-devel-104
2011-08-06s4:netcmd/gpo.py: we don't need to set autogenerated attributesStefan Metzmacher1-21/+11
metze
2011-08-06s4-scripting: allow to specify the number max of iteration around getNcChangesMatthieu Patou1-1/+4
2011-08-04s4-samdb: save the url in the samdb classAndrew Tridgell1-0/+3
this is useful for debugging, so we know which database we are dealing with Pair-Programmed-With: Amitay Isaacs <amitay@gmail.com>
2011-08-03samba-tool: Rename samba-tool command gpo2 --> gpoAmitay Isaacs1-1/+1
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-03samba-tool: Add implementation of gpo create commandAmitay Isaacs1-1/+176
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-03samba-tool: Add functions to create directories and copy files over SMB shareAmitay Isaacs1-0/+32
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-03samba-tool: Rename copy_directory_recurse to copy_directory_remote_to_localAmitay Isaacs1-11/+19
gpo fetch is remote->local and gpo create is local->remote local is local filesystem and remote is smb share. Need two functions to copy local->remote and remote->local. Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-03samba-tool: Addd functions to print GPO flags and GPlink optionsAmitay Isaacs1-28/+22
Use methods from python wrapper to convert gpo flags and gplink options to string. Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-02dbcheck: Cancel transaction if operation fails.Jelmer Vernooij1-10/+15
Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Tue Aug 2 01:41:07 CEST 2011 on sn-devel-104
2011-08-01acl: Improve error message when setting acls fails.Jelmer Vernooij1-4/+12
Autobuild-User: Jelmer Vernooij <jelmer@samba.org> Autobuild-Date: Mon Aug 1 18:59:12 CEST 2011 on sn-devel-104
2011-08-01s4-upgradeprovision: try to fix the detection of @provision recordMatthieu Patou1-1/+1
Autobuild-User: Matthieu Patou <mat@samba.org> Autobuild-Date: Mon Aug 1 13:43:50 CEST 2011 on sn-devel-104
2011-07-29samba-tool: use ldb.binary_encode() on search expression elementsAndrew Tridgell9-24/+27
this allows us to deal with search elements containing characters that must be escaped in LDAP Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org> Pair-Programmed-With: Amitay Isaacs <amitay@gmail.com>
2011-07-29samba-tool: fixed binary encoding of usernames in setpasswordAndrew Tridgell1-2/+2
Pair-Programmed-With: Amitay Isaacs <amitay@gmail.com> Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-28samba-tool: ensure prompting of passwords is in the right orderAndrew Tridgell1-1/+3
ask the creds object for the password before prompting for the new password in the user password change code, to ensure the user is asked for the old password first Pair-Programmed-With: Amitay Isaacs <amitay@gmail.com> Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org> Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Thu Jul 28 08:35:45 CEST 2011 on sn-devel-104
2011-07-28samba-tool: Added gpo fetch command implementation using python smb module.Amitay Isaacs1-0/+94
To copy the GPO files, use libcli python interface list() to get directory listing and loadfile() to read the contents of the file. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Change samba-tool gpo semantics (use gpo name instead of dn)Amitay Isaacs1-78/+124
Instead of using gpo dn as the key to refer to a gpo, use the gpo name as the key. If no URL is specified (-H option), find a writable DC and use that. Extract a commonly used method as get_gpo_info() to find details of a GPO. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Add user password command to change user's own passwordAmitay Isaacs1-0/+33
This command is a user-level command and differs from setpassword command which is administrator command. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Python routine to find writable/ldap-capable DCAmitay Isaacs1-0/+13
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Catch exceptions at top-level and exit with correct return valueAmitay Isaacs1-1/+5
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Display usage for main commands and list them alphabeticallyAmitay Isaacs1-31/+35
This makes the MainCommand class similar to SuperCommand class in netcmd. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Raise exception on errors and report using base classAmitay Isaacs1-10/+3
Exceptions are captured at top-level samba-tool and reported using the base class (Command) method show_command_error(). Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Display Usage line and list commands alphabeticallyAmitay Isaacs1-3/+6
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Replace C version of samba-tool with python versionAmitay Isaacs3-4/+4
C version of samba-tool is now called samba-tool-c, which will be removed as soon as all the samba-tool commands are ported to python. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Added python version of samba-toolAmitay Isaacs1-0/+70
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Reimplement GPO functions in pythonAmitay Isaacs1-11/+412
Implementation of subcommands - show, getlink, setlink, dellink, getinheritance, setinheritance Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Removed newuserGiampaolo Lauria2-94/+0
Removed newuser as its functionality has been moved to "user add" Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: Changed "user add" implementationGiampaolo Lauria1-13/+60
Changed "user add" to use SamDB instead of Net Also, added the set of Options available in newuser Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-28samba-tool: add -H or --URL where necessaryGiampaolo Lauria7-19/+32
To improve consistency, I've made sure all the commands take either a -H or --URL when specifying a URL Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-26s4-upgradeprovision: Detect recent provision in a more reliable wayMatthieu Patou1-1/+12
2011-07-26s4:samba-tool: ldapcmp needs CredentialsOptionsDoubleStefan Metzmacher1-0/+6
metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Tue Jul 26 17:09:32 CEST 2011 on sn-devel-104
2011-07-23scripting/bin: Some formatting fixes.Jelmer Vernooij2-4/+4
2011-07-21s4-param: use "state directory" and "cache directory" optionsBjörn Baumbach1-5/+5
instead of "state dir" and "cache dir" in order be compatible with the source3 code. Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-07-21samba-tool: make sure we exit with an error on a bad commandAndrew Tridgell1-1/+2
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org> Autobuild-User: Andrew Tridgell <tridge@samba.org> Autobuild-Date: Thu Jul 21 04:58:01 CEST 2011 on sn-devel-104
2011-07-21samba-tool: fixed some more calls to samba_tool join to be 'domain join'Andrew Tridgell1-1/+1
2011-07-21dbcheck: use string DN in delete when fixing broken strings DNsAndrew Tridgell1-1/+1
this prevents the extended_dn_in module from 'fixing' the DN for us Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21s4-provision: run dbcheck on a minimal set of objects in provisionAndrew Tridgell1-4/+8
this speeds up the dbcheck in provision to fix only the objects that we know will need fixing Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21samba_backup: check that directory really existsMatthieu Patou1-1/+11
2011-07-21s4-dsdb: change the samba3sam test to add the show_deleted moduleAndrew Tridgell1-1/+1
this is needed now that the samldb module adds the show deleted control Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21samba-tool: nicer error in passwordsettings with no settingsAndrew Tridgell1-0/+2
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21samba-tool: testparm doesn't take any credentialsAndrew Tridgell1-0/+5
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21samba-tool: use 'exportkeytab' instead of 'dumpkeys'Andrew Tridgell1-3/+3
a 'keytab' is a particular format known to administrators, whereas 'keys' is a bit too vague Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-07-21samba-tool: Fix __doc_ in base classesGiampaolo Lauria1-3/+3
Changed prog to samba-tool as prog is only meaningful in Parser Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-21samba-tool: removed synopsis code in base classGiampaolo Lauria1-8/+2
As it is not always possible to determine the usage of a command solely based on the list of required and optional args, it is best to have the subclasses always define it, rather than displaying an incorrect usage statement. Currently, all commands are subclassing the synopsis. Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-21samba-tool: Fixed bugs to determine min and max # of allowed argumentsGiampaolo Lauria1-7/+14
Fixed the bugs in the code to determine both the min and the max # of allowed arguments Changed the argument suffix convention from "*" to "+" to represent one or more arguments as: 1. It follows the Regular expression convention ("*" means 0 or more) 2. It is what was missing in terms of functionality NB Currently, no command is using the "*/+", but it is a good thing to have to help out the validation of the args if/when in the future we have such need Signed-off-by: Andrew Tridgell <tridge@samba.org>