summaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* debug: Remove thread-related code from debug.cVolker Lendecke2014-07-312-88/+0
| | | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Thu Jul 31 16:20:53 CEST 2014 on sn-devel-104
* param: Add errors for when an s3 context is used incorrectlyGarming Sam2014-07-311-0/+9
| | | | | | | | | | Change-Id: I176b4413769f41739639875ab874a3e340b6a184 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Michael Adam <obnox@samba.org> Autobuild-Date(master): Thu Jul 31 10:41:58 CEST 2014 on sn-devel-104
* param: get rid of unnecessary get_default_loadparm_service pointerGarming Sam2014-07-312-4/+0
| | | | | | | Change-Id: I9f512be671e5cd738c43fd97c9c3e0b4ee7a2736 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: remove unused lp_do_parameter from s3 helpersGarming Sam2014-07-311-1/+0
| | | | | | | Change-Id: I0de55ee30beb6b94350700afcdb85155e913bda8 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: remove unnecessary lp_do_parameter callGarming Sam2014-07-311-8/+2
| | | | | | Change-Id: I0cd1842bac3fcb6dde7236b87d5d235f10277e60 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* param: remove lp_get_parameterGarming Sam2014-07-312-7/+4
| | | | | | | | | Ensure lpcfg_parm_struct, its counterpart is equivalent Change-Id: I127ce5d3cf7fe02ebf161aa011ec3b41bc32a656 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: remove init printer values from s3-helpersGarming Sam2014-07-313-8/+2
| | | | | | | Change-Id: I2c4a85b4f5039158924982a277be20ebc2d6302e Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: move init_printer_values to lib/paramGarming Sam2014-07-311-0/+121
| | | | | | | Change-Id: I45df7d589c742d6e5572b0950daed563533cca3c Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: change init_printer_values to take an lp ctxGarming Sam2014-07-313-4/+5
| | | | | | | Change-Id: I55cda94bbf1daf276ec0c45b056bd81645eaa25f Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: add the necessary new line for the debug message in handle_copyGarming Sam2014-07-311-1/+1
| | | | | | | Change-Id: Ia6fc12b9d85032b6f501395cd82c31bcfe229822 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: add missing talloc_free in lpcfg_file_list_changed which are present ↵Garming Sam2014-07-311-0/+2
| | | | | | | | | in s3 Change-Id: Ib363069f5ecc4fc743aadf143efd640e00d74543 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: make is_default method static againGarming Sam2014-07-311-1/+1
| | | | | | | Change-Id: Icf509a5a8098efcc94e4372742ca9a20a987ad9e Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: use lpcfg_dump_globals in s3 loadparmGarming Sam2014-07-311-1/+1
| | | | | | | Change-Id: I7f7f5238a47e0c3634757b74f3f852ce36988614 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: rename dump_globalsGarming Sam2014-07-311-2/+2
| | | | | | | Change-Id: Ia587b8c968dedfcf9b3374d4a4f87bfaa37b01be Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: allow dump_globals to check the actual defaultsGarming Sam2014-07-311-2/+10
| | | | | | | Change-Id: Ia5f30b6922b2e836d3e93403c61458ee58d993fd Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: remove is_default method in s3Garming Sam2014-07-311-1/+1
| | | | | | | Change-Id: Ia9c7422c5f7b56eb81ad644b369bfa36849e963e Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: make is_default more genericGarming Sam2014-07-311-2/+2
| | | | | | | Change-Id: Ie380bb7083d96e4ebb1574b7d1e3df0b34f70352 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: use lpcfg_service_ok in s3 loadparmGarming Sam2014-07-311-2/+1
| | | | | | | Change-Id: Ic157d3f5ec7ac9a72db86239e76cd743149cb8e0 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: add extra condition in lpcfg_service_okGarming Sam2014-07-311-0/+9
| | | | | | | Change-Id: Id9a95748904516fd34869fee61b1e85b6d14f083 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* s3:param: remove lp_string_set from the s3_fns.Garming Sam2014-07-311-1/+0
| | | | | | | | This is not used any more. Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: remove unnecessary uses of lp_string_setGarming Sam2014-07-311-24/+9
| | | | | | | Change-Id: I190e8b62dee24c998f388eae1cc9558e6b8bc925 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* param: Use the correct flag locations with lpcfg_parm_is_cmdlineGarming Sam2014-07-311-8/+0
| | | | | | | | | | s3 flags are no longer being stored in the param table anymore. They shouldn't be used in this manner anymore. Change-Id: Ib97492fd9149e30d7756ca603f79321d7516f19b Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* lib/util: remove outdated comment from debug.cMichael Adam2014-07-301-4/+0
| | | | | | | These variables do not exist any more. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
* s3: winbindd: Add new parameter "winbind request timeout" set to 60 seconds ↵Jeremy Allison2014-07-292-0/+11
| | | | | | | | | | | | | | | | | with man page. "This parameter specifies the number of seconds the winbindd daemon will wait before disconnecting either a client connection with no outstanding requests (idle) or a client connection with a request that has remained outstanding (hung) for longer than this number of seconds." Bug 3204 winbindd: Exceeding 200 client connections, no idle connection found https://bugzilla.samba.org/show_bug.cgi?id=3204 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ira Cooper <ira@samba.org>
* Fix now erroneous comment for directory_create_or_exist()Jeremy Allison2014-07-291-1/+1
| | | | | | | | | | It doesn't do any checking that the permissions are correct. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Tue Jul 29 14:41:42 CEST 2014 on sn-devel-104
* lib: directory_create_or_exist() does not use "uid" parameterVolker Lendecke2014-07-283-6/+4
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* lib: Simplify directory_create_or_exist with an early returnVolker Lendecke2014-07-281-23/+24
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* sys_poll_intr: fix timeout arithmeticDaniel Kobras2014-07-221-2/+12
| | | | | | | | | | | | | | Callers of sys_poll_intr() assume timeout to be in milliseconds like poll(2) expects, but implementation used nanosecond units. Also make sure timeout doesn't become infinite by mistake during time arithmetic. Signed-off-by: Daniel Kobras <d.kobras@science-computing.de> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Tue Jul 22 00:12:24 CEST 2014 on sn-devel-104
* lib/util: move memcache.[ch] to the toplevel 'samba-util' libraryStefan Metzmacher2014-07-183-1/+533
| | | | | | | | | | This is generic enough that it could be used in all code. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jul 18 15:43:33 CEST 2014 on sn-devel-104
* ldb-samba: fix a memory leak in ldif_canonicalise_objectCategory()Stefan Metzmacher2014-07-171-1/+6
| | | | | | | | | | | | | Searches for '(objectCategory=Person)' will leak a ldb_dn structure on the ldb_context. These searches are typically used by Zarafa. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10469 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Thu Jul 17 00:51:57 CEST 2014 on sn-devel-104
* lib/zlib: Remove undeeded files that trigger GPL issues.Ira Cooper2014-07-164-0/+0
| | | | | | | | | | | These files have been removed in upstream versions of zlib due to the fact that binaries tend to become GPL violations. Signed-off-by: Ira Cooper <ira@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Ira Cooper <ira@samba.org> Autobuild-Date(master): Wed Jul 16 19:14:56 CEST 2014 on sn-devel-104
* s3:smb2_negprot: change "smb max {read,write,trans}" to 8MiB (as default)Stefan Metzmacher2014-07-111-3/+3
| | | | | | | | | | This matches Windows 2012R2. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Fri Jul 11 04:59:29 CEST 2014 on sn-devel-104
* param: change snum parameter in special functions to a loadparm_service pointerGarming Sam2014-07-073-41/+50
| | | | | | | | | | | | | | Using either an snum or the current service for special functions depending where it was called is unnecessary and complicates the process of handling them generically. idmap parameters now call lpcfg_do_parameter_parametric and are now set like normal. Change-Id: I3eca89791274280f9d3c7b987fbd790c16ec7981 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* lib/param: rename do_parameter to lpcfg_do_parameterGarming Sam2014-07-071-5/+3
| | | | | | | | | This should be used to allow it to be called from s3 code. Change-Id: I2f2d5526cf11a1ad78ca6ff7cb5c18fa25a98c76 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-072-1/+41
| | | | | | | | | | 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>
* param: Use set_variable instead of set_variable_helper in lp_do_parameterGarming Sam2014-07-071-5/+5
| | | | | | | | | | | | | This extends the usage of the temporary s3 context in lp_do_parameter to beyond the special functions. At least for now, this will be necessary for sorting out the differences between the do_parameter code. Change-Id: Iac380d11a927e466ab1a56d34cebe343c3608707 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: replace lp_set_cmdline in s3 helpers to store_cmdlineGarming Sam2014-07-073-9/+23
| | | | | | | Change-Id: I9a6ac66eeb8e0dd9ba356f5201f7ac09784b476d Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* param: Ensure the correct mem context is always being used from s3Garming Sam2014-07-071-2/+9
| | | | | | | Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org> Change-Id: I7b93822d0d06b00f08fecc2e55778767dd785b91
* param: set the flags on a s3 loadparm contextGarming Sam2014-07-073-0/+4
| | | | | | | | | | By setting up the flags when we initialize the context, the flags can be accessed by lib/param at any time. Change-Id: I60d4f3a9108560e204cf5f37da9c7d995939e146 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: flag fixes in s3 loadparmGarming Sam2014-07-071-0/+10
| | | | | | | | | | In s3 loadparm, the flags are stored in the param table, while in lib/param, it is individual to a loadparm context. Change-Id: I23d72eeec6b935c1897b34b8fc49d5a9992f2993 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: allow fallback to s3 do_section in lib/paramGarming Sam2014-07-071-1/+8
| | | | | | | | | | This means that pm_process will eventually only call one do_section method. Change-Id: I81ffd0d61783df3e6c267f06210d4180a291ab4c Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: add do_section to s3 helpersGarming Sam2014-07-072-0/+2
| | | | | | | Change-Id: Ib9cee580f46fcb6d5046e606b4bfbf9e68dab76a Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* lib/param: add deprecated warning to be consistent with s3Garming Sam2014-07-071-0/+10
| | | | | | | Change-Id: I79016279b8c5dce6263bff0477b808108e583d20 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: make some more changes to lp_do_parameter to match set_variable_helperGarming Sam2014-07-071-1/+1
| | | | | | | | | Attempting to make the code match exactly before moving it over. Change-Id: Ie7a30d5477f3fbf95f8f43e1ac1f76b581d87709 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* lib/param: change set_variable_helper formattingGarming Sam2014-07-071-4/+6
| | | | | | | | | Attempting to make the code match exactly before moving it over. Change-Id: Id5571b00a8afd7dffc6197f2c7e020dd4fd59f85 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: use str_list_make_v3 instead of str_list_make in s3Garming Sam2014-07-071-2/+2
| | | | | | | Change-Id: Iea5aa39b9848bb19b0df3c70f249fd63bb61455e Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: Add null checks for upcoming str_list_make changesGarming Sam2014-07-072-2/+6
| | | | | | | | | | | | | In changing str_list_make to str_list_make_v3, the list can be NULL. These are some additional checks to try to avoid any problems. Where lists are dealt with, they typically check both if the list is empty or the list is NULL. Change-Id: I9012c31dbd9832ce877728bcb3346616ba64c4c5 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: pre-emptively correct use of str_list_make_v3 in lib/paramGarming Sam2014-07-071-0/+4
| | | | | | | | | | | | | | | lib/param uses str_list_make, while, s3 uses str_list_make_v3. These differ slightly and should be made the same. Notably it returns NULL when given a null or empty string Also, includes the null check in s3 code to be consistent for merging this section of code later on. Change-Id: Ib543a5a5307e06989621ea16bfe87e315d66a7ef Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* lib/param: factor out a common portion of set_variableGarming Sam2014-07-071-14/+30
| | | | | | | Change-Id: Id8eeb480a377b4df8c3f51daf0d253f032fd0e83 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>
* param: change a number of parameters from P_LIST to P_CMDLISTGarming Sam2014-07-071-25/+25
| | | | | | | | | | | | | | | | | | These parameters are being changed to use their original syntax to match source3. netbios aliases, interfaces, auth methods, invalid users, valid users, admin users, read list, write list, hosts allow, hosts deny, preload modules, smb ports, name resolve order, svcctl list, cluster addresses, init logon delayed hosts, wins server, eventlog list, usershare prefix allow list, usershare prefix deny list, vfs objects, winbind nss info The documentation has also been changed to be consistent with the change. Change-Id: I536481098a508e0366c910b180f2db6a6f0634a9 Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@samba.org>