summaryrefslogtreecommitdiff
path: root/source3/smbd/service.c
AgeCommit message (Collapse)AuthorFilesLines
2009-08-24Second attempt at fix for bug 6529 - Offline files conflict with Vista and ↵Jeremy Allison1-18/+1
Office 2003. Confirmation from reporter that this fixes the issue in master on ext3/ext4. Back-ports to follow. Jeremy.
2009-08-21Log debug message when hires timestamps are available on theJeremy Allison1-0/+4
share. Jeremy.
2009-08-21Fix bug 6529 - Offline files conflict with Vista and Office 2003Jeremy Allison1-0/+13
On filesystems that can't store less than one second timestamps, round the incoming timestamp set requests so the client can't discover that a time set request has been truncated by the filesystem. Needs backporting to 3.4, 3.3, 3.2 and (even) 3.0. Jeremy
2009-08-07s3:smbd: remove dirptr and dirpath from connection_structStefan Metzmacher1-2/+0
They're both only used in the context of a function, so we can make them stack variables. metze
2009-08-07s3:smbd: add a smbd_server_connection pointer to connection_structStefan Metzmacher1-17/+16
This can be NULL for faked connection structs used in the rpc server or printing code. metze
2009-07-21do not log chdir with level 0 if reason is access deniedChristian Ambach1-2/+2
this changes the level of logs caused by users trying to access shares or subdirectories for which they do not have access to in the ACL this can fill up the samba log even with log level 0 and is more an expected kind of logs that IMHO should not be logged with such a high level. All other errors while chdir() will still be logged with level 0 Signed-off-by: Christian Ambach <christian.ambach@de.ibm.com>
2009-07-14Revert this commit :Jeremy Allison1-80/+0
s3: Make smbd aware of permission change of usershare. Since usershare are relatively volatile and non-previledge users must disconnect from smbd and reconnect to it to make share permission in effect. For now. This is a feature request and I think we need to design it a little differently so as not to touch core change_to_user() code. Jeremy.
2009-07-15s3: Make smbd aware of permission change of usershare. Since usershare are ↵Bo Yang1-0/+80
relatively volatile and non-previledge users must disconnect from smbd and reconnect to it to make share permission in effect.
2009-06-24s3: Plumb smb_filename through SMB_VFS_STAT and SMB_VFS_LSTATTim Prouty1-6/+12
This patch introduces two new temporary helper functions vfs_stat_smb_fname and vfs_lstat_smb_fname. They basically allowed me to call the new smb_filename version of stat, while avoiding plumbing it through callers that are still too inconvenient. As the conversion moves along, I will be able to remove callers of this, with the goal being to remove all callers. There was also a bug in create_synthetic_smb_fname_split (also a temporary utility function) that caused it to incorrectly handle filenames with ':'s in them when in posix mode. This is now fixed.
2009-06-03s3:smbd: make make_connection_snum() non staticStefan Metzmacher1-2/+1
metze
2009-06-03s3:smbd: move tcon specific globals to struct smbd_server_connectionStefan Metzmacher1-18/+19
metze
2009-06-03s3:smbd: move more session specific globals to struct smbd_server_connectionStefan Metzmacher1-17/+25
metze
2009-05-26Introduce "struct stat_ex" as a replacement for SMB_STRUCT_STATVolker Lendecke1-2/+2
This patch introduces struct stat_ex { dev_t st_ex_dev; ino_t st_ex_ino; mode_t st_ex_mode; nlink_t st_ex_nlink; uid_t st_ex_uid; gid_t st_ex_gid; dev_t st_ex_rdev; off_t st_ex_size; struct timespec st_ex_atime; struct timespec st_ex_mtime; struct timespec st_ex_ctime; struct timespec st_ex_btime; /* birthtime */ blksize_t st_ex_blksize; blkcnt_t st_ex_blocks; }; typedef struct stat_ex SMB_STRUCT_STAT; It is really large because due to the friendly libc headers playing macro tricks with fields like st_ino, so I renamed them to st_ex_xxx. Why this change? To support birthtime, we already have quite a few #ifdef's at places where it does not really belong. With a stat struct that we control, we can consolidate the nanosecond timestamps and the birthtime deep in the VFS stat calls. At this moment it is triggered by a request to support the birthtime field for GPFS. GPFS does not extend the system level struct stat, but instead has a separate call that gets us the additional information beyond posix. Without being able to do that within the VFS stat calls, that support would have to be scattered around the main smbd code. It will very likely break all the onefs modules, but I think the changes will be reasonably easy to do.
2009-05-04Increase debug level of "create_connection_server_info failed" messageVolker Lendecke1-1/+1
I don't think we should unconditionally send every refused connection attempt to a share to syslog, that's where all debug level 0 messages end up.
2009-04-29s3:smbd/service: switch load_registry_service/shares to use loadparm routinesMichael Adam1-70/+3
instead of reading the registry directly with tdb and activating the configure options by hand. This eliminates the need for repeating checks done in loadparm. For instance it disables registry shares without path in the server as is the case with text based shares. Michael
2009-03-23s3:smbd: use new simplified snb_signing code in the serverStefan Metzmacher1-1/+1
We keep the seqnum/mid mapping in the smb_request structure. This also moves one global variable into the smbd_server_connection struct. metze
2009-03-03Fix bug #6155 - "force group" is no longer working as expected.Jeremy Allison1-0/+8
We need to store the "force group" uid separately from the conn->server_info token as we need to apply it separately also. Volker PLEASE CHECK ! Jeremy.
2009-01-08s3:smbd: move all globals and static variables in globals.[ch]Stefan Metzmacher1-2/+1
The goal is to move all this variables into a big context structure. metze
2009-01-05smbd: prevent access to root filesystem when connecting with empty service nameMichael Adam1-0/+4
This only applies to a setup with "registry shares = yes" Michael (cherry picked from commit 288fa94ac7cfdf7457b5098c33fc840bed3d5410) (cherry picked from commit e85526b184e66f86b7faa9d0a37288a09c12c19e)
2008-11-24Remove unused make_connection_with_chdir()Volker Lendecke1-32/+0
2008-10-13Remove smb_np_structVolker Lendecke1-4/+3
2008-06-26Fix a debug messageVolker Lendecke1-1/+1
(This used to be commit 8dd94d448bc5ad067024c56c6ef498bc88a396b2)
2008-06-19Wrap the unix token info in a unix_user_token in auth_serversupplied_infoVolker Lendecke1-6/+6
No functional change, this is a preparation for more current_user ref removal (This used to be commit dcaedf345e62ab74ea87f0a3fa1e3199c75c5445)
2008-05-26Re-enable the evil "aio write behind" parameter.Jeremy Allison1-0/+2
Jeremy. (This used to be commit 5d22ca00bcdf49dcb35468400ac8cc3c57808d0d)
2008-05-25Remove some references to get_current_username() and current_user_infoVolker Lendecke1-10/+10
(This used to be commit 344d69f95e217d16213eaa6b53141af6ab459708)
2008-05-25Remove the reference to current_user_info from share_access.cVolker Lendecke1-0/+1
This required to pass around the domain a bit (This used to be commit 17b0db20d28d1b737c5e86b78106657e8ca5ce9c)
2008-05-10Remove "user" from connection_structVolker Lendecke1-10/+15
(This used to be commit 368454a27cb53a408ec416cbf37235b304592fb5)
2008-05-10Remove the unix token info from connection_structVolker Lendecke1-7/+10
(This used to be commit 2834dacc8d49f77fe55fb5d7e3eb2dda431d1d3d)
2008-05-10Replace nt_user_token with server_info in connection_structVolker Lendecke1-24/+4
(This used to be commit a3738aef59e97d4533010b048534d937d36c0950)
2008-05-10find_forced_group can directly change the token in server_infoVolker Lendecke1-72/+16
Now that we have a token that is correctly set up with gids already, this saves manual translation of the SIDs to GIDs. (This used to be commit 6136a6d9d7301c65f37e2bf485681138cddd8bd2)
2008-05-10Add an error return in find_forced_group()Volker Lendecke1-0/+5
(This used to be commit 93ce0705c14f222bda3e6204f4b54ba1893f33e1)
2008-05-10Do not unnecessarily mess with the results in find_forced_group()Volker Lendecke1-3/+0
(This used to be commit 6d9860d09b54c61625f011c2d56d710aa59d7686)
2008-05-10Replace find_forced_user by a direct call to make_serverinfo_from_usernameVolker Lendecke1-37/+26
(This used to be commit 7991e6764b4187ba86802569dfdc5816e6137f78)
2008-05-10Simplify make_connection_snum: Copy connection_struct info from server_infoVolker Lendecke1-13/+11
(This used to be commit 5aa3cdf355c179d89c2703f528919194ab084337)
2008-05-10Add "server_info" to connection_structVolker Lendecke1-97/+23
This will replace all the user identity stuff in connection_struct, for now it is just a source where the other fields in connection_struct are filled from. (This used to be commit 0f53f9e7db9f99f239c4d0950452d0e2cde2ae8b)
2008-05-10Remove unused "force_group" from connection_structVolker Lendecke1-1/+0
(This used to be commit 03944f8d8934cff74e19fc036f7611c1491e0d57)
2008-05-10"status" -> "pstatus" in make_connection_snumVolker Lendecke1-42/+38
(This used to be commit 3ce395e61e931a77c5d2f52f39c7e3f71a9605a9)
2008-05-10Add create_connection_server_info() -- not used yetVolker Lendecke1-0/+76
(This used to be commit 50bf075f7556fd09e0081175c31a5020a8eaf4d6)
2008-05-07Use talloc_tos() for a temporary getpwnam_alloc in make_connection_snumVolker Lendecke1-1/+1
(This used to be commit 1843ea64ab1df5ced5926aedbeb27c8320b0c70b)
2008-05-07Use talloc_stackframe() in find_forced_groupVolker Lendecke1-11/+5
(This used to be commit 27a9bbc645416265eebdfc866925855021bd407c)
2008-05-05Remove "userdom_struct user" from "struct user_struct"Volker Lendecke1-4/+5
(This used to be commit 420de035237bb08bc470c9eb820f3da2edaa6805)
2008-05-05Remove "guest" from "struct user_struct"Volker Lendecke1-3/+3
(This used to be commit 570a6b80feb5b0dc23213ba936c721e766cd4818)
2008-05-05Remove the unix token info from "struct user_struct"Volker Lendecke1-2/+2
(This used to be commit aa2299d42adf4d27e707ac755e07be70d0af1bb4)
2008-05-05Remove "nt_user_token" from "struct user_struct"Volker Lendecke1-3/+3
(This used to be commit 51d5d512f28eadc74eced43e5e7f4e5bdff3ff69)
2008-05-05Remove connection_struct->mem_ctx, connection_struct is its own parentVolker Lendecke1-6/+6
(This used to be commit 559180f7d30606d1999399d954ceedc798c669a4)
2008-03-12Add a debug message.Michael Adam1-0/+1
Michael (This used to be commit a39807044879ad9df7614e010db6ea16b51000a0)
2008-03-11registry shares: prevent creating regular share called "global".Michael Adam1-0/+4
This is a first quick fix. Registry shares should be rewritten to use libnet_conf. Michael (This used to be commit 71bd0bd0ea018e8c5033bbf904333c596330855a)
2008-01-21Add SMB_VFS_FS_CAPABILITIESVolker Lendecke1-9/+1
It turns out that this is a necessary operation, separate from statvfs. statvfs can fail during tcon, so conn->fs_capabilities would never see that we support streams on a particular share. James, can you check that I got the darwin variant right? Thanks! (This used to be commit 3ad798d803b3b023533bb48e6993885f22b96095)
2008-01-16Add handling of [homes] and [printers] via registry shares.Michael Adam1-39/+45
Now homes and printers shares can be accessed through the registry meachanism on demand in pure registry configurations with "config backend = registry" without the need to have a special handler for these two. Michael (This used to be commit eec3248ef90fbfe6e048394c875173b164a8b439)
2008-01-09Make use of talloc_pool in the main codepaths. Remove the sub-contexts.Jeremy Allison1-7/+1
Jeremy. (This used to be commit bc932b8ad4396f76b71c43efe9a6346f89c3632c)