1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-24 21:34:56 +03:00
Commit Graph

85078 Commits

Author SHA1 Message Date
C. Davis
bdc40f909f regedit: Link to ncurses form library
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:06:01 +02:00
Andreas Schneider
4a87a7ab61 regedit: Don't panic if we can't open the file.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:06:00 +02:00
Andreas Schneider
86f88ee7b0 waf: Create a better wscript for finding ncurses.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:59 +02:00
C. Davis
5e0f4be8e2 regedit: Improve calculation for centering dialogs.
Add some sanity checks to avoid crashing.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:58 +02:00
C. Davis
6155abcf82 regedit: Introduce dialog windows.
Link to ncurses "panels" library to support popup dialog
windows, and begin working on a small dialog library.

Right now, it is useful for "yes/no" confirmation popups,
but later it'll be used for more complex forms for editing
values.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:57 +02:00
C. Davis
4267ec59fe regedit: Take into account that getch() may return a '\n' instead of KEY_ENTER.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:55 +02:00
C. Davis
19b9a7063b regedit: Use tab key to switch between key and value sections.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:54 +02:00
C. Davis
0fb6cc01f3 regedit: Don't overwrite the '/' when printing path.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:53 +02:00
C. Davis
6d82438c63 regedit: Print value summary, fix heap corruption and path printing.
Added code to summarize value data. Also fixed a few bugs,
including some heap corruption found with valgrind.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:52 +02:00
C. Davis
e75057a906 regedit: List values for the selected key.
Next step is to format a preview for the data and show that
next to the data type.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:51 +02:00
C. Davis
f751b36979 regedit: Print the registry path.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:50 +02:00
C. Davis
632cefa1da regedit: Make all hives browsable.
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:49 +02:00
Michael Adam
89d3067c22 regedit: load the configuration after processing the command line
this way the "-s" parameter can change the config file to be loaded...

Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-04-29 13:05:47 +02:00
C. Davis
d3633c08cd regedit: Setup a test tree view of HKLM.
Expand on the former test by allowing the user to walk HKLM
with the tree view. Subkeys are loaded dynamically in memory
as the user walks the hierarchy with tree_node_load_children().

One issue with this at the moment is detecting if the
in-memory copy of the hierarchy is out of date.

TODO: figure out when to reload out of date portions of the
hierarchy (probably by checking last_modified_time).

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:46 +02:00
C. Davis
c99675b813 regedit: Initial import of treeview code
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-04-29 13:05:45 +02:00
C. Davis
dc0029c946 regedit: First crack at linking to ncurses.
First attempt of editing build scripts to link to ncurses
libraries. It seems to work, though checks may need to be
expanded upon.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:44 +02:00
C. Davis
6c881e285b regedit: Add regedit main source file
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:43 +02:00
C. Davis
44f7d1b673 Support s3 local access with the s4 libregistry framework
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:42 +02:00
C. Davis
1ac6bb1491 s3: Wrap calls to the s3 registry API.
To use Samba 4's libregistry in the registry editor, some
compatibility issues with Samba 3 need to be addressed.
"struct registry_key" is defined differently in source3 and
source4, and so this wrapper is used to isolate conflicting
types and avoid headaches compiling the code.

Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2013-04-29 13:05:41 +02:00
Jeremy Allison
251767cde9 Fix bug #9822 - Samba crashing during Win8 sync.
When refactoring the dptr desctructor in the
fix for bug:

9778 (Samba directory code uses dirfd() without vectoring through a VFS call)

I removed the code to NULL out the struct smb_Dir *
pointer inside the fsp struct by mistake.

Re-add the NULLing out of that pointer when
closing a directory pointer associated with
an open file.

Reporter confirms it fixes the crash.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Sat Apr 27 20:44:55 CEST 2013 on sn-devel-104
2013-04-27 20:44:55 +02:00
Volker Lendecke
b7765fe63f torture: Only test leases if supported
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>

Autobuild-User(master): Richard Sharpe <sharpe@samba.org>
Autobuild-Date(master): Sat Apr 27 18:09:37 CEST 2013 on sn-devel-104
2013-04-27 18:09:36 +02:00
Volker Lendecke
27e9115eb0 torture: Use ZERO_STRUCTPN instead of explicit deref
Signed-off-by: Volker Lendecke <vl@samba.org>
2013-04-27 07:22:33 -07:00
Jeremy Allison
5185460067 Check for WRITE_ACCESS on the file before overriding an EACCESS.
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): Sat Apr 27 15:57:17 CEST 2013 on sn-devel-104
2013-04-27 15:57:17 +02:00
Jeremy Allison
77e3099483 Ensure we don't try the open_file_fchmod() if we can't write to the file.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2013-04-27 14:11:10 +02:00
Jeremy Allison
a91aac4a5f Remove indentation around code wrapped by unneeded CAN_WRITE.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2013-04-27 14:11:05 +02:00
Jeremy Allison
0d88b37fc6 Add early return in file_set_dosmode() on a read only share.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2013-04-27 14:10:52 +02:00
Volker Lendecke
8283fd0e00 smbd: Do not fetch the record in defer_open_done
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): Sat Apr 27 02:06:10 CEST 2013 on sn-devel-104
2013-04-27 02:06:10 +02:00
Volker Lendecke
e13021e3af dbwrap: Allow dbwrap_record_watch_recv to not lock the record
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:23 -07:00
Volker Lendecke
a7e803485d smbd: We don't use DEFERRED_OPEN_ENTRY anymore
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:22 -07:00
Volker Lendecke
8da5a0f1e3 smbd: Remove unused smb2_deferred_open_timer
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:22 -07:00
Volker Lendecke
78d4bdc0b8 smbd: Obsolete MSG_SMB_OPEN_RETRY
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:22 -07:00
Volker Lendecke
f52a3c3cd1 smbd: Remove the unused fsp->pending_break_messages array
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:22 -07:00
Volker Lendecke
3e7923d7af smbd: Remove unused reply_to_oplock_break_requests
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:22 -07:00
Volker Lendecke
234edb525d smbd: Obsolete MSG_SMB_BREAK_RESPONSE
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:21 -07:00
Volker Lendecke
4e4376164b smbd: Ignore OPEN_RETRY and BREAK_RESPONSE
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:21 -07:00
Volker Lendecke
afe9446985 smbd: Use dbwrap_record_watch_send for defer_open
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-26 15:17:21 -07:00
David Disseldorp
b1574ebb0b bug 9830: fix panic in nt_printer_publish_ads
Check for ads_find_machine_acct() errors, to ensure a NULL LDAPMessage
pointer doesn't get passed to ldap_get_dn().

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-By: Günther Deschner <gd@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Thu Apr 25 19:01:55 CEST 2013 on sn-devel-104
2013-04-25 19:01:55 +02:00
Sam Lang
727c611fe3 source4/libcli: Only set ctemp set on success
If open fails ctemp.out.name probably won't be valid and strdup
will cause a segv.  Only set the path if open succeeds.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Apr 24 23:58:44 CEST 2013 on sn-devel-104
2013-04-24 23:58:43 +02:00
Sam Lang
301a1f9192 Implements a vfs module for cephfs, a distributed file system
with posix semantics, built on the ceph distributed object
storage layer.  The ceph vfs module interfaces to the libcephfs
userspace API, and is primarily a lightweight wrapper around
libcephfs, translating error codes and parameters as necessary.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
Reviewed-by: Volker Lendecke <Volker.Lendecke@SerNet.DE>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-04-24 12:53:18 -07:00
Andreas Schneider
4b97a19e58 BUG 9817: Fix 'map untrusted to domain' with NTLMv2.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Wed Apr 24 17:14:48 CEST 2013 on sn-devel-104
2013-04-24 17:14:48 +02:00
Christian Ambach
19242b2916 docs-xml: document dbwrap_tool exists
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Apr 22 18:43:42 CEST 2013 on sn-devel-104
2013-04-22 18:43:42 +02:00
Christian Ambach
26515c5d47 s3:utils/dbwrap_tool add exists operation
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
2013-04-22 16:12:13 +02:00
Volker Lendecke
5512a43a93 docs: Fix bug 9809 -- missing entry in specfile
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Karolin Seeger <kseeger@samba.org>

Autobuild-User(master): Karolin Seeger <kseeger@samba.org>
Autobuild-Date(master): Mon Apr 22 11:35:52 CEST 2013 on sn-devel-104
2013-04-22 11:35:51 +02:00
Jeremy Allison
5727bfa410 Fix bug in old create temp SMB request. Only use VFS functions.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Sat Apr 20 21:13:36 CEST 2013 on sn-devel-104
2013-04-20 21:13:36 +02:00
Jeremy Allison
95f7fc83b2 Ensure the RECVFILE path in vfs_pwrite_data() operates on a blocking socket.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Sat Apr 20 01:04:05 CEST 2013 on sn-devel-104
2013-04-20 01:04:05 +02:00
Jeremy Allison
1ed710c2ff Ensure the RECVFILE path in vfs_write_data() operates on a blocking socket.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>
2013-04-19 14:11:27 -07:00
Jeremy Allison
1b46db7b24 Ensure drain_socket() operates on a blocking socket.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>
2013-04-19 14:11:23 -07:00
Jeremy Allison
1a7cec37e7 Add the internals of is_smb2_recvfile_write.
This turns on the real receivefile detection, and completes
the receivefile code path changes.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>
2013-04-19 14:11:19 -07:00
Jeremy Allison
53b87f2fba The guts of the receivefile code changes.
If an incoming PDU might qualify, only read
SMBD_SMB2_SHORT_RECEIVEFILE_WRITE_LEN = (SMB2_HEADER + SMB2_WRITE_BODY_LEN)
bytes rather than the whole PDU.

Next time we're called, use is_smb2_recvfile_write() to decide if
this is an SMB2_WRITE that fit the receivefile criteria, otherwise
just read the rest of the PDU.

If we did do a short receivefile read, set up the smb2_req->smb1req->unread_bytes
value to show what bytes remain in the TCP buffers.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>
2013-04-19 14:11:15 -07:00
Jeremy Allison
fdcaf0fa36 Add stub static function that will turn on/off receivefile code path.
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan (metze) Metzmacher <metze@samba.org>
2013-04-19 14:11:11 -07:00