summaryrefslogtreecommitdiffstats
path: root/fs/cifs/cifssmb.c
Commit message (Collapse)AuthorAgeFilesLines
* [CIFS] log better errors on failed mountsSteve French2007-10-181-5/+5
| | | | | | | | Also returns more accurate errors to mount for the cases of account expired and password expired Acked-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Return better error when server requires signing but client forbidsSteve French2007-10-181-1/+3
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix some endianness problems in new acl codeSteve French2007-10-161-1/+1
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] parse server_GUID in SPNEGO negProt responseJeff Layton2007-10-161-14/+18
| | | | | | | | SPNEGO NegProt response also contains a server_GUID. Parse it as we would for RawNTLMSSP. Signed-off-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS]Jeff Layton2007-10-161-2/+2
| | | | | | | | | | | [CIFS] fix error message about packet signing When packet signing is disabled and the server requires it, cifs prints an error message. The current message refers to a file in /proc that no longer exists. Fix it to refer to the correct file. Signed-off-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix endian conversion problem in posix mkdirCyril Gorcunov2007-10-141-4/+4
| | | | | Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] CIFS ACL support part 3Steve French2007-10-121-0/+2
| | | | | Signed-off-by: Shirish Pargaonkar <shirishp@us.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix cifsd so shuts down when signing fails during mountSteve French2007-10-041-3/+20
| | | | | | | | | | | | | | | | | | Fixes two problems: 1) we dropped down to negotiating lanman if we did not recognize the mechanism (krb5 e.g.) 2) we did not stop cifsd (thus will fail when doing rmod cifs with slab free errors) when we fail tcon but have a bad session (which is the case in which signing is required but we don't allow signing on the client) It also turns on extended security flag in the header when passing "sec=krb5" on mount command (although kerberos support is not done of course) Acked-by: Jeff Layton <jlayton@redhat.com> CC: Shaggy <shaggy@us.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] CIFS ACL support (part 2)Shirish Pargaonkar2007-10-031-1/+1
| | | | | Signed-off-by: Shirish Pargaonkar <shirishp@us.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix memory leak in statfs to very old serversSteve French2007-09-281-4/+0
| | | | | | | We were allocating request buffers twice in the statfs path when mounted to very old (Windows 9x) servers. Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] move cifs acl code to new file and fix build breakSteve French2007-09-251-107/+0
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Support for CIFS ACLs (part 1)Steve French2007-09-241-4/+97
| | | | | | | | Add code to be able to dump CIFS ACL information when Query Posix ACL with cifsacl mount parm enabled. Signed-off-by: Shirish Pargoankar <shirishp@us.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Print better error when server returns malformed QueryUnixInfo responseSteve French2007-09-201-0/+3
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] formatting cleanup found by checkpatchSteve French2007-08-301-24/+20
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS][KJ] use abs() from kernel.h where appropriateAndre Haupt2007-08-301-1/+1
| | | | | Signed-off-by: Andrew Haupt <andre@finow14.de> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Allow disabling CIFS Unix Extensions as mount optionSteve French2007-07-181-15/+6
| | | | | | | | | Previously the only way to do this was to umount all mounts to that server, turn off a proc setting (/proc/fs/cifs/LinuxExtensionsEnabled). Fixes Samba bugzilla bug number: 4582 (and also 2008) Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] More whitespace/formatting fixes (noticed by checkpatch)Steve French2007-07-171-11/+22
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Add support for new POSIX unlinkSteve French2007-07-151-8/+77
| | | | | | | | | | In the cleanup phase of the dbench test, we were noticing sharing violation followed by failed directory removals when dbench did not close the test files before the cleanup phase started. Using the new POSIX unlink, which Samba has supported for a few months, avoids this. Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] whitespace/formatting fixesSteve French2007-07-131-446/+477
| | | | | | | | | This should be the last big batch of whitespace/formatting fixes. checkpatch warnings for the cifs directory are down about 90% and many of the remaining ones are harder to remove or make the code harder to read. Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] more whitespace cleanupSteve French2007-07-071-270/+270
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Mount should fail if server signing off but client mount option ↵Jeff2007-07-061-1/+2
| | | | | | | | | | | | | | | | requires it Currently, if mount with a signing-enabled sec= option (e.g. sec=ntlmi), the kernel does a warning printk if the server doesn't support signing, and then proceeds without signatures. This is probably OK for people that think to look at the ring buffer, but seems wrong to me. If someone explicitly requests signing, we should error out if that request can't be satisfied. They can then reattempt the mount without signing if that's ok. Signed-off-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix sign mount option and sign proc config settingSteve French2007-06-281-11/+21
| | | | | | | | | We were checking the wrong (old) global variable to determine whether to override server and force signing on the SMB connection. Acked-by: Dave Kleikamp <shaggy@austin.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Missing flag on negprot needed for some servers to force packet signingYehuda Sadeh Weinraub2007-06-051-2/+2
| | | | | | | | | | | A related signature issue that I came across. There's a bug in win2k that when NT error codes are not negotiated, the server doesn't response that signatures are mandatory. Since there's (currently) no way turn on signatures in such case, I had to force NT error codes, so that this bug will not occur Signed-off-by: Yehuda Sadeh Weinraub <Yehuda.Sadeh@expand.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] New CIFS POSIX mkdir performance improvement (part 2)Steve French2007-04-251-4/+7
| | | | | | Fix incorrect parsing of return data Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] New CIFS POSIX mkdir performance improvementSteve French2007-04-231-3/+124
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix set file size to zero when doing chmod to Samba 3.0.26preSteve French2007-03-011-0/+10
| | | | | | | | | | | | | | | | In fixing a bug Samba 3.0.26pre allowed some clients (including Linux cifs client) to change file size to zero in SET_FILE_UNIX_BASIC (which Linux cifs client uses for chmod). The server has been "fixed" now but that also fixes the client to net send file size zero on chmod. Fixes Samba bugzilla bug # 4418. Fixed with help from Jeremy Allison Signed-off-by: Jeremy Allison <jra@samba.org> Signed-off-by: Steve French <sfrench@us.ibm.com>
* Storage class should be before const qualifierTobias Klauser2007-02-171-2/+2
| | | | | | | | | | | The C99 specification states in section 6.11.5: The placement of a storage-class specifier other than at the beginning of the declaration specifiers in a declaration is an obsolescent feature. Signed-off-by: Tobias Klauser <tklauser@distanz.ch> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [CIFS] on reconnect to Samba - reset the unix capabilitiesSteve French2007-02-141-2/+14
| | | | | | | | | | After temporary server or network failure and reconneciton, we were not resending the unix capabilities via SetFSInfo - which confused Samba posix byte range locking code. Discovered by jra Signed-off-by: Steve French <sfrench@us.ibm.com>
* [PATCH] getting rid of all casts of k[cmz]alloc() callsRobert P. J. Day2006-12-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Run this: #!/bin/sh for f in $(grep -Erl "\([^\)]*\) *k[cmz]alloc" *) ; do echo "De-casting $f..." perl -pi -e "s/ ?= ?\([^\)]*\) *(k[cmz]alloc) *\(/ = \1\(/" $f done And then go through and reinstate those cases where code is casting pointers to non-pointers. And then drop a few hunks which conflicted with outstanding work. Cc: Russell King <rmk@arm.linux.org.uk>, Ian Molton <spyro@f2s.com> Cc: Mikael Starvik <starvik@axis.com> Cc: Yoshinori Sato <ysato@users.sourceforge.jp> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Kyle McMartin <kyle@mcmartin.ca> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jeff Dike <jdike@addtoit.com> Cc: Greg KH <greg@kroah.com> Cc: Jens Axboe <jens.axboe@oracle.com> Cc: Paul Fulghum <paulkf@microgate.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Cc: Karsten Keil <kkeil@suse.de> Cc: Mauro Carvalho Chehab <mchehab@infradead.org> Cc: Jeff Garzik <jeff@garzik.org> Cc: James Bottomley <James.Bottomley@steeleye.com> Cc: Ian Kent <raven@themaw.net> Cc: Steven French <sfrench@us.ibm.com> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Neil Brown <neilb@cse.unsw.edu.au> Cc: Jaroslav Kysela <perex@suse.cz> Cc: Takashi Iwai <tiwai@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] new cifs endianness bugsAl Viro2006-10-151-5/+7
| | | | | | | | | | * missing cpu_to_le64() for ChangeTime (introduced by [CIFS] Legacy time handling for Win9x and OS/2 part 1) * missing le16_to_cpu() for DialectIndex (introduced by [CIFS] Do not send newer QFSInfo to legacy servers which can not support it) Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [CIFS] Missing flags2 for DFSSteve French2006-10-121-0/+8
| | | | | | Partly suggested by Igor Mammedov Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Level 1 QPathInfo needed for proper OS2 supportSteve French2006-10-121-3/+18
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix compiler warning with previous patchSteve French2006-10-021-1/+1
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix typoSteve French2006-10-021-1/+1
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Allow for 15 minute TZs (e.g. Nepal) and be more explicit aboutSteve French2006-10-021-13/+22
| | | | | | | not setting time on close Signed-off-by: Guenter Kukkukk <linux@kukkukk.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Allow LANMAN21 support even in both POSIX non-POSIX pathSteve French2006-10-011-0/+1
| | | | | Signed-off-by: Guenter Kukkukk <linux@kukkukk.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Do not send newer QFSInfo to legacy servers which can not support itSteve French2006-09-301-3/+5
| | | | | | | | | | | | Fix dialect negotiation to save off when we have negotiated lanman. This allows us to avoid sending some somewhat newer requests that the server can not handle and go directly to the older version (infolevel) of the same call. Make sure we try to negotiate a level which allows us to get the server OS (which we check so we can detect Win9x vs. other legacy servers and eventually work around the Win9x DOS time bug (they reverse date/time fields). Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Rename server time zone fieldSteve French2006-09-301-5/+4
| | | | | | | | Server time zone is not really a time zone, rather a time adjustement in seconds. CC: Guenter Kukkukk <linux@kukkukk.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Handle legacy servers which return undefined time zoneSteve French2006-09-301-1/+27
| | | | | Signed-off-by: Guenter Kukkukk <linux@kukkukk.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Remove static and unused symbolsSteve French2006-09-281-2/+4
| | | | | | | | | Most cases of the ones found by Shaggy by "make namespacecheck" could be removed or made static Ack: Dave Kleikamp <shaggy@austin.ibm.com> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Legacy time handling for Win9x and OS/2 part 1Steve French2006-09-281-1/+9
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] endian errors in lanman protocol supportSteve French2006-08-151-1/+1
| | | | | | | | | le16 compared to host-endian constant u8 fed to le32_to_cpu() le16 compared to host-endian constant Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS]Jeremy Allison2006-08-111-2/+13
| | | | | | | | | | | Allow Windows blocking locks to be cancelled via a CANCEL_LOCK call. TODO - restrict this to servers that support NT_STATUS codes (Win9x will probably not support this call). Signed-off-by: Jeremy Allison <jra@samba.org> Signed-off-by: Steve French <sfrench@us.ibm.com> (cherry picked from 570d4d2d895569825d0d017d4e76b51138f68864 commit)
* [CIFS] Do not time out posix brl requests when using new posix setfileinfoSteve French2006-08-111-3/+8
| | | | | | | | | | request and do not time out slow requests to a server that is still responding well to other threads Suggested by jra of Samba team Signed-off-by: Steve French <sfrench@us.ibm.com> (cherry picked from 89b57148115479eef074b8d3f86c4c86c96ac969 commit)
* [CIFS] Fix authentication choice so we do not force NTLMv2 unless theSteve French2006-06-281-3/+7
| | | | | | user specifies it is required or turns of ntlm Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix allocation of buffers for new session setup routine to allowSteve French2006-06-271-5/+13
| | | | | | longer user and domain names and allow passing sec options on mount Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix compile warning when CONFIG_CIFS_EXPERIMENTAL is offSteve French2006-06-251-2/+0
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] fix minor compile warning when config_cifs_weak_security is offSteve French2006-06-121-0/+2
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* [CIFS] Fix mask so can set new cifs security flags properlySteve French2006-06-041-1/+1
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>
* CIFS] Support for older servers which require plaintext passwords - part 2Steve French2006-06-041-135/+144
| | | | Signed-off-by: Steve French <sfrench@us.ibm.com>