1
0
mirror of https://github.com/samba-team/samba.git synced 2025-12-02 00:23:50 +03:00
Commit Graph

296 Commits

Author SHA1 Message Date
Jeremy Allison
00f71fc836 More gentest error fixups.
Jeremy.
-
Jeremy Allison
87eb336d65 Remove unneeded second open for filename ending in '.' now we know it's
a mangled name. Added const. Fix inspired by Andrew Bartlett ideas.
Jeremy.
-
Jeremy Allison
63f3315643 Fix signing miss-sequence noticed by Stefan Metzmacher <metze@metzemix.de>
Jeremy.
-
Jeremy Allison
27af1f9fea Implement SMBexit properly. Found by Samba4 tester. You must do a make
clean proto all; after this commit.
Jeremy.
-
Jeremy Allison
10d90171ed Fix SMBseek and get/set position information SMBs. Works against
Samba4 tester. You will need a make clean; make all after this !
Jeremy.
-
Jeremy Allison
b43ce1ff61 An oplock break reply from the client causes the sequence number to be
updated by 2 if there is no open reply outstanding, else by one....
Yes - this makes no sense....
Jeremy.
-
Jeremy Allison
7f111e545d Finish tridge's patch as referenced here :
make sure we don't allow the creation of directories containing
wildcard characters. I've only put this in mkdir at the moment, but I
suspect this will apply to all places that can create new filenames.

We need to allow the opening of existing filenames that contain
wildcards, but not allow the creation of new ones.

Jeremy.
-
Jeremy Allison
b826e8c898 Fix from matt.zinkevicius@hp.com to stop files being created on read-only
shares in some circumstances.
Jeremy.
-
Tim Potter
f93528ba00 Fixup a bunch of printf-style functions and debugs to use unsigned long when
displaying pid_t, uid_t and gid_t values.  This removes a whole lot of warnings
on some of the 64-bit build farm machines as well as help us out when 64-bit
uid/gid/pid values come along.
-
Jeremy Allison
cbde1c8dfc Fix spotted by Nadav Danieli <nadavd@exanet.com> - ensure dev and inode
to fix open mode race condition.
Jeremy.
-
Jeremy Allison
ff222716a0 Removed strupper/strlower macros that automatically map to strupper_m/strlower_m.
I really want people to think about when they're using multibyte strings.
Jeremy.
-
Jeremy Allison
84a7714eba More fixes for debug log to catch logic error.
Jeremy.
-
Jeremy Allison
6d3b72b499 Add more info to debug info...
Jeremy.
-
Alexander Bokovoy
c2689ed118 Prefix VFS API macros with SMB_ for consistency and to avoid problems with VFS_ macros at system side. We currently have one clash with AIX and its VFS_LOCK. Compiled and tested -- no new functionality or code, just plain rename of macros for yet-unreleased VFS API version. Needs to be done before a24 is out -
Alexander Bokovoy
af0a17349e Eliminate NULL pointers from VFS interface. All hooks now really callable, producing either correct result or returning error if the feature isn't supported in the configuration -
Alexander Bokovoy
91984ef5ca Fix VFS layer:
1. Finally work with cascaded modules with private data storage per module
2. Convert VFS API to macro calls to simplify cascading
3. Add quota support to VFS layer (prepare to NT quota support)

Patch by Stefan (metze) Metzemacher, with review of Jelmer and me
Tested in past few weeks. Documentation to new VFS API for third-party developers to follow
-
Jeremy Allison
a2af45154d Fix for bugid 51 from Dragan Krnic.
Jeremy.
-
Andrew Bartlett
0e04761abe This is really trying to be a StrnCpy (most names will overflow the 10 char
limit)
-
Andrew Bartlett
32fb801ddc Merge the 'safe' parts of my StrnCpy patch - many of the users really wanted
a pstrcpy/fstrcpy or at most a safe_strcpy().

These have the advantage of being compiler-verifiable.

Get these out of the way, along with a rewrite of 'get_short_archi' in the
spoolss client and server.  (This pushes around const string pointers, rather
than copied strings).

Andrew Bartlett
-
Jeremy Allison
546d1a941b Add runtime tests for "impossible" case with -DDEVELOPER. Trying to catch logic
error on Linux.
Jeremy.
-
Jeremy Allison
7844a53df7 Correctly return access denied on share mode deny when we can't open the
file. This is a regression that was damaged by other code.
Jeremy.
-
Jeremy Allison
d8a42753cc Ensure we only ever set fsp->conn in one place.
Jeremy.
-
Jeremy Allison
b3df40bc80 Ensure Samba passes the open attribute truncate tests in smbtorture.
Jeremy.
-
Jeremy Allison
33e3e863eb Fix for interesting resource constraint condition. When all opens are
level 2 and a request for open with no oplock is received then the
smbd should send *synchronous* break messages, not asynchronous,
otherwise it spins very rapidly, releasing the lock, sending the
'break to none' messages and then re-acquiring the lock before
any other process has a chance to get the lock and remove it's own
oplock (at least on linux).
Jeremy
-
Jeremy Allison
1cff725e37 Fix open problem with changing attributes on an existing file - based
on work by  <steve@griffin.sio2.nl>.
Jeremy.
-
Jeremy Allison
62038a0abf Fix problem with "hide unreadable". stat file opens are baaack :-).
Jeremy.
-
Jeremy Allison
3bf21ca936 Very curious. It turns out attribute matching on truncate only matters
when opening truncate with current SYSTEM|HIDDEN -> NONE. It's fine to
truncate on open with current NONE -> SYSTEM | HIDDEN.
Jeremy.
-
Jeremy Allison
4ec381d642 Fix to correctly return NT_STATUS_DELETE_PENDING.
Jeremy.
-
Jeremy Allison
40eafb9dde First cut of new ACL mapping code from Andreas Gruenbacher <agruen@suse.de>.
This is not 100% the same as what SuSE shipped in their Samba, there is
a crash bug fix, a race condition fix, and a few logic changes I'd like to
discuss with Andreas. Added Andreas to (C) notices for posix_acls.c
Jeremy.
-
Gerald Carter
65e7b5273b sync'ing up for 3.0alpha20 release -
Andrew Tridgell
03ac082dcb updated the 3.0 branch from the head branch - ready for alpha18 -
Jeremy Allison
6819e81da4 Matched W2K *insane* open semantics....
Jeremy.
-
Jeremy Allison
3b1b8ac435 Fix the mp3 rename bug - also tidy up our open code and remove the special
cases for rename and unlink. Had to add desired_access into the share mode record.
Jeremy.
-
Jeremy Allison
d0b58f66ed Fix stupid typo !
Jeremy.
-
Jeremy Allison
504e5ef049 Remove the "stat open" code - make it inline. This should fix the
bugs with opening and renaming mp3 files, also the word rename
problems that people have had for a while.
Needs a make clean :-) make.
Also added JohnR's printing fix.
Jeremy.
-
Jeremy Allison
7d59445b69 Added POSIX ACL layer into the vfs.
Jeremy.
-
Jeremy Allison
d85133e269 Implemented default ACL patch (set inherit acls = true on a per share basis).
Based on code donated by Olaf Frczyk <olaf@cbk.poznan.pl>. Further commit
will change to sending via vfs interface.
Jeremy.
-
Jeremy Allison
25dd73be29 Fixed delete on close semantics - preparing for share mode rewrite.
Jeremy.
-
Andrew Tridgell
d09ae0c667 This is a nasty hack to fix "xcopy /o" from win2000 on a Samba share
The hack passes the true ntcreate desired_access down to open_file_shared1()
from the ntcreatex function. This is used to determine if share modes
should be used in denying this open.

This hack will become unnecessary when we redo open.c to use the proper
NTCreateX semantics rather than trying to jam the ntcreate semantics into
openX semantics.
-
Tim Potter
a56298d56a Merge of smbclient print crash bug fix from app head. -
Tim Potter
6a58c9bd06 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
-
Jeremy Allison
248770d730 Fixed display of "remote downlevel document" in old print job submission
case.
Jeremy.
-
Andrew Tridgell
c3a83002cf don't use O_NONBLOCK in open(). This was added erroneously for kernel
oplocks and really shouldn't be used
-
Jeremy Allison
4f1f5f28b5 Added the O_NOFOLLOW flag if follow symlinks is set off.
Jeremy.
-
Jeremy Allison
32dffa0ba7 Moved fchown_acl change to the point where we *really* know if we
created the file or not.
Jeremy.
-
Jeremy Allison
0187d4ba16 Spelling pedents strike again :-).
Jeremy.
-
Jeremy Allison
1f3dcd99bd Ensure the CAN_WRITE is checked and prevents O_CREAT and O_TRUNC from
being set. Also prevent an open on a file on a readonly share from
setting delete on close.
Jeremy.
-
Jeremy Allison
b69127391b Re-added "Share modes" meaning don't allow deny mode conflict. Due to
user demand (don't talk to me about removing parameters.... :-).
Jeremy.
-
Jeremy Allison
8150f0f3f7 Fix for the logic bug wrt. existant oplocks. See long message
in samba-technical for explaination.
Jeremy.
-
Jeremy Allison
014b0973a3 nsswitch/winbindd_group.c nsswitch/winbindd_user.c: formatting fixups.
smbd/open.c: Fix "delete on close" for directories.
Jeremy.
-