1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00
Commit Graph

4521 Commits

Author SHA1 Message Date
Chris Lamb
5089e03b1e Correct "Openened" typos.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
2017-02-22 08:26:24 +01:00
Chris Lamb
8de5c2e967 Correct "heirarchy" typos.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
2017-02-22 08:26:23 +01:00
Chris Lamb
7e20f1e200 Correct "incluing" typos.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
2017-02-22 08:26:23 +01:00
Chris Lamb
1429428caa Correct "errror" typos.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
2017-02-22 08:26:22 +01:00
Chris Lamb
a4ab7c73bd Correct "occured" typos.
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
2017-02-22 08:26:21 +01:00
Ralph Boehme
e08110ece6 s3/rpc_server/mdssvc: add attribute "kMDItemContentType"
Bug: https://bugzilla.samba.org/show_bug.cgi?id=12545

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Feb 15 06:20:52 CET 2017 on sn-devel-144
2017-02-15 06:20:52 +01:00
Ralph Boehme
9785fe5af6 s3/rpc_server: shared rpc modules loading
The previous commit 58889e04bd for this
bug was broken as it didn't move the goto into the "if (errno !=
ENOENT)" condition.

This updated fix folds the test "mod_init_fns == NULL" and the check for
the errno into one if condition.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12184

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2017-01-31 00:45:18 +01:00
Noel Power
1820209b9e s3/rpc_server/mdssvc: Generate flex/bison files in build
Build the generated files at build time instead of using a committed version
generated at some point in the past.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12528

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Sat Jan 28 13:26:01 CET 2017 on sn-devel-144
2017-01-28 13:26:01 +01:00
Andreas Schneider
9d60ad53b8 rpc_server: Allow to configure the port range for RPC services
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12521

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Andreas Schneider <asn@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2017-01-27 08:09:15 +01:00
Andreas Schneider
35dfa5c6e2 rpc_server: Use the RPC TCPIP ports of Windows
Since Windows Server 2008 Microsoft uses a different port range for RPC
services. Before it was 1024-65535 and they changed it to 49152-65535.

We should use the same range as these are the ports the firewall in AD
networks normally allow.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=12521

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2017-01-27 08:09:15 +01:00
Volker Lendecke
9af73f62ce lib: Add lib/util/server_id.h
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
2017-01-22 18:30:11 +01:00
Ralph Boehme
35460d92bb s3/rpc_server/mdssvc: prefix public flex and bison global symbols
This fixes a clash with a parser in Heimdal when building with
--nonshared-binary=smbd/smbd:

...
[3139/3620] Linking default/source3/smbd/smbd
...
default/source4/heimdal/lib/hx509/sel-lex_116.o: In function `yy_get_previous_state':
/usr/build/packages/samba-4.5/bin/../source4/heimdal/lib/hx509/sel-lex.c:1122:multiple definition of `yyin'
default/source3/rpc_server/mdssvc/sparql_lexer_28.o:/usr/build/packages/samba-4.5/bin/sparql_lexer.c:1149:first defined here
...

The fix is to use namespace prefixes in the parser and the lexer as
described here:
<https://www.gnu.org/software/bison/manual/html_node/Multiple-Parsers.html>

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12528

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): Ralph Böhme <slow@samba.org>
Autobuild-Date(master): Sat Jan 21 13:13:19 CET 2017 on sn-devel-144
2017-01-21 13:13:19 +01:00
Ralph Boehme
7933c2a60f s3/rpc_server/mdssvc: use flex noyyalloc noyyrealloc
Redefine the symbols used for malloc and realloc in the flex source
instead of running sed over the generated one.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12528

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2017-01-21 09:26:15 +01:00
Ralph Boehme
be8e90f27a s3/rpc_server: move rpc_modules.c to its own subsystem
The source file rpc_modules.c was used in two places which lead to the
following build error when configuring with '--nonshared-binary=smbd/smbd':

  ERROR: source source3/rpc_server/rpc_modules.c is in more than one
  subsystem of target 'smbd/smbd': ['RPC_SERVICE', 'MDSSD']

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12524

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Noel Power <nopower@suse.com>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Fri Jan 20 15:00:45 CET 2017 on sn-devel-144
2017-01-20 15:00:45 +01:00
Günther Deschner
b9199945e7 s3-spoolss: globally set print server environment/architecture.
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-12 15:35:13 +01:00
Günther Deschner
92fc6a6c25 s3-spoolss: make us appear as a 64bit print server.
This makes us behave like all recent windows systems.

Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-12 15:35:13 +01:00
Günther Deschner
d6a9377b6d s3-spoolss: Use a more accurate DefaultSpoolDirectory
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-12 15:35:13 +01:00
Stefan Metzmacher
4b295b106c wscript: remove executable bits for all wscript* files
These files should not be executable.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Wed Jan 11 20:21:01 CET 2017 on sn-devel-144
2017-01-11 20:21:01 +01:00
Günther Deschner
90deb9f04c s3-spoolss: Create a sperate header file for 'struct printer_handle'
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
bb24649051 s3-spoolss: remove unused type field in printer handle
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
a2501843b6 s3-iremotewinspool: update api struct map so we only end up implementing 8 calls
In the end, these calls are the only ones we need to implement:

3.1.4.2. Printer Driver Management Methods

* AsyncInstallPrinterDriverFromPackage
* AsyncUploadPrinterDriverPackage
* AsyncCorePrinterDriverInstalled
* AsyncDeletePrinterDriverPackage

3.1.4.9. Printing Related Notification Methods

* SyncRegisterForRemoteNotifications
* SyncUnRegisterForRemoteNotifications
* SyncRefreshRemoteNotifications
* AsyncGetRemoteNotifications

All other calls are 1:1 mapped to spoolss calls.

Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
7dd880f4b9 s3-iremotewinspool: add generated server stubs and no longer compile autogenerated ones
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
29266c0a90 s3-iremotewinspool: add generated srv_iremotewinspool_nt.c file
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
567465546f s3-rpc_server: setup secondary address for tcp transport in bind_ack packet.
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
3e084ea6ce s3-rpc_server: enforce packet level authentication for iremotewinspool server
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Günther Deschner
1ec825b28a s3-rpc_server: allow to set minimal auth level for a DCE/RPC service
Guenther

Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Guenther Deschner <gd@samba.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2017-01-06 12:28:18 +01:00
Volker Lendecke
80bb18d896 samr3: Use "all_zero" where appropriate
... Saves a few bytes of footprint

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
2017-01-03 16:04:28 +01:00
Volker Lendecke
2d9409341f rpc_server: svcctl xfile->stdio
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-12-11 11:17:23 +01:00
Günther Deschner
941173d14c s3-spoolss: use architecture in spoolss_MonitorInfo calls consistently
Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2016-11-21 14:52:24 +01:00
Andreas Schneider
95b738badb s3:spoolss: Add some useful debug messages on error
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12415

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 17:29:08 +01:00
Andreas Schneider
4d9f4bfc69 s3:spoolss: Add support for COPY_FROM_DIRECTORY in AddPrinterDriverEx
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12415

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 17:29:07 +01:00
Volker Lendecke
df9e7c7ae5 lib: Remove global xfile.h includes
This makes it more obvious where this legacy code is used

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): Sun Nov 20 06:23:19 CET 2016 on sn-devel-144
2016-11-20 06:23:19 +01:00
Andreas Schneider
cd9d957adb s3:spoolss: Improve debug messages in construct_printer_driver
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 02:28:11 +01:00
Andreas Schneider
f5154f2eb7 s3:spoolss: Return error when there is no driver assigned
If you create a new printer in Samba, there is no driver assinged.
Detect that early and return the right error code.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 02:28:11 +01:00
Günther Deschner
17bc1427f0 s3-spoolss: set the defaults for os_version defines globally.
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 02:28:10 +01:00
Günther Deschner
3fa58844d2 s3-spoolss: also set new os_major,minor,build values in printer info 0
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 02:28:10 +01:00
Andreas Schneider
b9d73fb4cb s3:spoolss: Set default OS Version to Windows Server 2003 R2 SP2
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12416

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-11-20 02:28:10 +01:00
Andreas Schneider
cc081c7831 s3-epmapper: Ignore epm_Map object guid
Tests revealed that you can pass random GUIDs to epm_Map and Windows will
happily answer the query.

Pair-Programmed-With: Guenther Deschner <gd@samba.org>
Signed-off-by: Andreas Schneider <asn@samba.org>
Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Nov 12 02:49:23 CET 2016 on sn-devel-144
2016-11-12 02:49:23 +01:00
Andreas Schneider
07505429cc s3-spoolss: Remove printer from registry if it is unpublished
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11665

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): Tue Nov  8 18:05:10 CET 2016 on sn-devel-144
2016-11-08 18:05:09 +01:00
Stefan Metzmacher
55b07e1dec s3:rpc_server: pass the full ndr_interface_table to rpc_pipe_open_internal()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-10-26 11:20:18 +02:00
Stefan Metzmacher
3b82d6cc2e s3:rpc_server: add support for DCERPC_AUTH_LEVEL_PACKET
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-10-26 11:20:16 +02:00
Stefan Metzmacher
4464896167 dcerpc.idl: split the padding from a possible fault buffer in dcerpc_fault
The 4 bytes of padding are always present and part of the header.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2016-10-26 11:20:12 +02:00
Volker Lendecke
d7214a8216 spoolss: Fix caching of printername->sharename
time_mono() gives seconds since boot, gencache expects seconds since epoch.
With time_mono(), the values are always expired immediately.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12374

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Thu Oct 13 13:48:52 CEST 2016 on sn-devel-144
2016-10-13 13:48:52 +02:00
Trever L. Adams
7accec7f78 Update smbrun to allow for settings environment variables.
Signed-off-by: Trever L. Adams <trever.adams@gmail.com>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Oct 13 04:26:26 CEST 2016 on sn-devel-144
2016-10-13 04:26:26 +02:00
Günther Deschner
d60f3f0554 werror: removed WERR_UNKNOWN_LEVEL
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:35 +02:00
Günther Deschner
5b2ce01b77 werror: replace WERR_UNKNOWN_LEVEL with WERR_INVALID_LEVEL in source3/rpc_server/
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:34 +02:00
Günther Deschner
7186ecac94 werror: replace WERR_DFS_CANT_CREATE_JUNCT with WERR_NERR_DFSCANTCREATEJUNCTIONPOINT in source3/rpc_server/dfs/srv_dfs_nt.c
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:30 +02:00
Günther Deschner
8cc1b5bcfa werror: replace WERR_DFS_INTERNAL_ERROR with WERR_NERR_DFSINTERNALERROR in source3/rpc_server/dfs/srv_dfs_nt.c
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:30 +02:00
Günther Deschner
5a375c144a werror: replace WERR_DFS_NO_SUCH_SERVER with WERR_NERR_DFSNOSUCHSERVER in source3/rpc_server/dfs/srv_dfs_nt.c
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:30 +02:00
Günther Deschner
43cdc9de43 werror: replace WERR_DFS_NO_SUCH_SHARE with WERR_NERR_DFSNOSUCHSHARE in source3/rpc_server/dfs/srv_dfs_nt.c
Guenther

Signed-off-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2016-09-28 00:04:29 +02:00