13 Feb, 2013

1 commit

  • Convert nfs_map_name_to_uid to return a kuid_t value.
    Convert nfs_map_name_to_gid to return a kgid_t value.
    Convert nfs_map_uid_to_name to take a kuid_t paramater.
    Convert nfs_map_gid_to_name to take a kgid_t paramater.

    Tweak nfs_fattr_map_owner_to_name to use a kuid_t intermediate value.
    Tweak nfs_fattr_map_group_to_name to use a kgid_t intermediate value.

    Which makes these functions properly handle kuids and kgids, including
    erroring of the generated kuid or kgid is invalid.

    Cc: "J. Bruce Fields"
    Cc: Trond Myklebust
    Signed-off-by: "Eric W. Biederman"

    Eric W. Biederman
     

13 Oct, 2012

1 commit


31 Jul, 2012

1 commit

  • This patch exports symbols needed by the v4 module. In addition, I also
    switch over to using IS_ENABLED() to check if CONFIG_NFS_V4 or
    CONFIG_NFS_V4_MODULE are set.

    The module (nfs4.ko) will be created in the same directory as nfs.ko and
    will be automatically loaded the first time you try to mount over NFS v4.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     

06 Mar, 2012

1 commit


02 Mar, 2012

1 commit

  • This patch removes the old hashmap-based caching and instead uses a
    "request key actor" to place an upcall to the legacy idmapper rather
    than going through /sbin/request-key. This will only be used as a
    fallback if /etc/request-key.conf isn't configured to use nfsidmap.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     

07 Feb, 2012

1 commit

  • This patch removes the CONFIG_NFS_USE_NEW_IDMAPPER compile option.
    First, the idmapper will attempt to map the id using /sbin/request-key
    and nfsidmap. If this fails (if /etc/request-key.conf is not configured
    properly) then the idmapper will call the legacy code to perform the
    mapping. I left a comment stating where the legacy code begins to make
    it easier for somebody to remove in the future.

    Signed-off-by: Bryan Schumaker
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     

01 Feb, 2012

1 commit

  • v2:
    1) Added "nfs_idmap_init" and "nfs_idmap_quit" definitions for kernels built
    without CONFIG_NFS_V4 option set.

    This patch subscribes NFS clients to RPC pipefs notifications. Idmap notifier
    is registering on NFS module load. This notifier callback is responsible for
    creation/destruction of PipeFS idmap pipe dentry for NFS4 clients.

    Since ipdmap pipe is created in rpc client pipefs directory, we have make sure,
    that this directory has been created already. IOW RPC client notifier callback
    has been called already. To achive this, PipeFS notifier priorities has been
    introduced (RPC clients notifier priority is greater than NFS idmap one).
    But this approach gives another problem: unlink for RPC client directory will
    be called before NFS idmap pipe unlink on UMOUNT event and will fail, because
    directory is not empty.
    The solution, introduced in this patch, is to try to remove client directory
    once again after idmap pipe was unlinked. This looks like ugly hack, so
    probably it should be replaced in some more elegant way.

    Note that no locking required in notifier callback because PipeFS superblock
    pointer is passed as an argument from it's creation or destruction routine and
    thus we can be sure about it's validity.

    Signed-off-by: Stanislav Kinsbursky
    Signed-off-by: Trond Myklebust

    Stanislav Kinsbursky
     

08 Jan, 2012

1 commit

  • ...so that we can do the uid/gid mapping outside the asynchronous RPC
    context.
    This fixes a bug in the current NFSv4 atomic open code where the client
    isn't able to determine what the true uid/gid fields of the file are,
    (because the asynchronous nature of the OPEN call denies it the ability
    to do an upcall) and so fills them with default values, marking the
    inode as needing revalidation.
    Unfortunately, in some cases, the VFS will do some additional sanity
    checks on the file, and may override the server's decision to allow
    the open because it sees the wrong owner/group fields.

    Signed-off-by: Trond Myklebust

    Trond Myklebust
     

12 Mar, 2011

1 commit


08 Oct, 2010

1 commit

  • This patch creates a new idmapper system that uses the request-key function to
    place a call into userspace to map user and group ids to names. The old
    idmapper was single threaded, which prevented more than one request from running
    at a single time. This means that a user would have to wait for an upcall to
    finish before accessing a cached result.

    The upcall result is stored on a keyring of type id_resolver. See the file
    Documentation/filesystems/nfs/idmapper.txt for instructions.

    Signed-off-by: Bryan Schumaker
    [Trond: fix up the return value of nfs_idmap_lookup_name and clean up code]
    Signed-off-by: Trond Myklebust

    Bryan Schumaker
     

31 Jan, 2009

1 commit


23 Sep, 2006

2 commits


07 Jan, 2006

1 commit


17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds