summaryrefslogtreecommitdiff
path: root/cifs.upcall.c
AgeCommit message (Collapse)AuthorFilesLines
2010-07-27cifs.upcall: swap c99 initializers for memset callsJeff Layton1-2/+6
gcc says: cifs.upcall.c: In function ‘cifs_krb5_get_req’: cifs.upcall.c:261:2: warning: missing initializer cifs.upcall.c:261:2: warning: (near initialization for ‘in_creds.client’) cifs.upcall.c: In function ‘main’: cifs.upcall.c:622:9: warning: missing initializer cifs.upcall.c:622:9: warning: (near initialization for ‘arg.ver’) ...this is probably just gcc being balky, but we can silence the warning. It may also be a micro optimization in an error condition if we delay zeroing out the struct until it's needed. Signed-off-by: Jeff Layton <jlayton@samba.org>
2010-07-26cifs.upcall: require a uid= or creduid= parmJeff Layton1-0/+5
Even though all known kernels send the uid= parm to userspace, cifs.upcall doesn't technically require it. It should though. If one wasn't sent for some reason, then the setuid wouldn't occur. Error out if there is no uid= or creduid= parm. Signed-off-by: Jeff Layton <jlayton@samba.org>
2010-07-23cifs.upcall: use "creduid=" parm by default when availableJeff Layton1-5/+27
When I did the original krb5 implementation, I goofed and ended up making it so that when someone specifies the "uid=" mount option that also affects the owner of the krb5 credential cache and not just the ownership of the mount. I'm proposing a patch for the kernel to attempt to fix this by making the kernel send a "creduid=" parameter in the upcall which is intended to be the user that should own the credentials cache. That's not necessarily the same user that has "ownership" of the mount. Usually the creduid= will be set to the real uid of the user doing the mounting. When multisession mounts are introduced they will usually set this to the fsuid that walks into the mount. To ease the transition, this patch also adds a command line switch that makes cifs.upcall use the "legacy" uid= parameter instead. Use that if you want it to behave like it used to. Signed-off-by: Jeff Layton <jlayton@samba.org>
2010-04-02cifs-utils: bump version to 4.2cifs-utils-4.2Jeff Layton1-3/+3
- fix URL's and email addresses - update copyright notices Signed-off-by: Jeff Layton <jlayton@samba.org>
2010-04-01cifs.upcall: run it through LindentJeff Layton1-72/+66
...coding style cleanup. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-04-01cifs-upcall: krb5.h inclusion quick fixTorsten Kurbad1-0/+4
...eventually it might be better to make autoconf set -I/usr/include/krb5 or whatever and get rid of the #ifdef's here. It's a little tricky to figure out the include dir however, so this will do for now. Signed-off-by: Torsten Kurbad <torsten@tk-webart.de>
2010-04-01cifs-upcall: heimdal fixesTorsten Kurbad1-3/+13
Signed-off-by: Torsten Kurbad <torsten@tk-webart.de>
2010-03-20cifs-utils: switch to using autoconf package versionJeff Layton1-2/+1
Rather than using a hardcoded version string, use the VERSION macro that autoconf provides. This will help make it clear what version is actually being used in bug reports when someone runs "mount.cifs -V" or "cifs.upcall --version". Also, clean up AC_INIT and AM_INIT_AUTOMAKE macros. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-26cifs.upcall: use non-legacy krb5.h locationJeff Layton1-1/+1
<krb5.h> is deprecated in favor of <krb5/krb5.h>. Also, make autoconf throw a more helpful error message if it's not present. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-20autoconf: make sure C files include config.hJeff Layton1-0/+4
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-08cifs.upcall: include util.hJeff Layton1-0/+1
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-08cifs.upcall: remove strncasecmp redefinitionJeff Layton1-9/+1
...no need for that now. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: include arpa/inet.hJeff Layton1-0/+1
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: include netdb.hJeff Layton1-0/+1
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: replace SMB_XMALLOC_ARRAY with callocJeff Layton1-4/+4
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: include time.hJeff Layton1-0/+1
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: add a spnego.h fileJeff Layton1-0/+1
...to hold SPNEGO definitions. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: fix up the includesJeff Layton1-4/+11
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: replace SMB_STRNDUP with strndupJeff Layton1-1/+1
Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: replace cli_krb5_get_ticketJeff Layton1-3/+84
We need to replace the function that we use to fetch krb5 creds since that's currently provided by a libsmbclient object. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: don't use smb_krb5_unparse_nameJeff Layton1-4/+18
...we don't really need a talloc-ified version here. Just use the normal one. Also don't use strnequal. Use strncasecmp instead. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07cifs.upcall: don't use smb_krb5_principal_get_realmJeff Layton1-1/+26
...we need our own version. Signed-off-by: Jeff Layton <jlayton@redhat.com>
2010-02-07Initial import of files from samba master branchJeff Layton1-0/+653
(commit 6e510b49c03be9caba4f587f3f6cec547841b0d7)