1. 15 12月, 2009 2 次提交
  2. 26 11月, 2009 1 次提交
    • J
      nfsd: simplify fh_verify access checks · 864f0f61
      J. Bruce Fields 提交于
      All nfsd security depends on the security checks in fh_verify, and
      especially on nfsd_setuser().
      
      It therefore bothers me that the nfsd_setuser call may be made from
      three different places, depending on whether the filehandle has already
      been mapped to a dentry, and on whether subtreechecking is in force.
      
      Instead, make an unconditional call in fh_verify(), so it's trivial to
      verify that the call always occurs.
      
      That leaves us with a redundant nfsd_setuser() call in the subtreecheck
      case--it needs the correct user set earlier in order to check execute
      permissions on the path to this filehandle--but I'm willing to accept
      that minor inefficiency in the subtreecheck case in return for more
      straightforward permission checking.
      Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
      864f0f61
  3. 15 11月, 2009 1 次提交
  4. 14 11月, 2009 1 次提交
  5. 06 11月, 2009 1 次提交
  6. 05 11月, 2009 1 次提交
    • P
      nfsd: register NFS_ACL with rpcbind · 1b7e0403
      Peter Staubach 提交于
      Modify the NFS server to register the NFS_ACL services with the rpcbind
      daemon.  This allows the client to ping for the existence of the NFS_ACL
      support via commands such as "rpcinfo -t <server> nfs_acl".
      
      This patch also modifies the NFS_ACL support so that responses to
      version 2 NULLPROC requests can be made.
      
      The changelog for the patch which turned off this functionality
      mentioned something about not registering the NFS_ACL as being part of
      some tradition.  I can't find this tradition and the only other
      implementation which supports NFS_ACL does register them with the
      rpcbind daemon.
      Signed-off-by: NPeter Staubach <staubach@redhat.com>
      Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
      1b7e0403
  7. 28 10月, 2009 3 次提交
  8. 02 10月, 2009 1 次提交
  9. 29 9月, 2009 4 次提交
  10. 24 9月, 2009 1 次提交
  11. 23 9月, 2009 1 次提交
  12. 22 9月, 2009 2 次提交
  13. 16 9月, 2009 11 次提交
  14. 14 9月, 2009 1 次提交
  15. 05 9月, 2009 2 次提交
  16. 04 9月, 2009 2 次提交
  17. 03 9月, 2009 2 次提交
  18. 02 9月, 2009 3 次提交
    • D
      CRED: Add some configurable debugging [try #6] · e0e81739
      David Howells 提交于
      Add a config option (CONFIG_DEBUG_CREDENTIALS) to turn on some debug checking
      for credential management.  The additional code keeps track of the number of
      pointers from task_structs to any given cred struct, and checks to see that
      this number never exceeds the usage count of the cred struct (which includes
      all references, not just those from task_structs).
      
      Furthermore, if SELinux is enabled, the code also checks that the security
      pointer in the cred struct is never seen to be invalid.
      
      This attempts to catch the bug whereby inode_has_perm() faults in an nfsd
      kernel thread on seeing cred->security be a NULL pointer (it appears that the
      credential struct has been previously released):
      
      	http://www.kerneloops.org/oops.php?number=252883Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Signed-off-by: NJames Morris <jmorris@namei.org>
      e0e81739
    • A
      nfsd41: replace page based DRC with buffer based DRC · 557ce264
      Andy Adamson 提交于
      Use NFSD_SLOT_CACHE_SIZE size buffers for sessions DRC instead of holding nfsd
      pages in cache.
      
      Connectathon testing has shown that 1024 bytes for encoded compound operation
      responses past the sequence operation is sufficient, 512 bytes is a little too
      small. Set NFSD_SLOT_CACHE_SIZE to 1024.
      
      Allocate memory for the session DRC in the CREATE_SESSION operation
      to guarantee that the memory resource is available for caching responses.
      Allocate each slot individually in preparation for slot table size negotiation.
      
      Remove struct nfsd4_cache_entry and helper functions for the old page-based
      DRC.
      
      The iov_len calculation in nfs4svc_encode_compoundres is now always
      correct.  Replay is now done in nfsd4_sequence under the state lock, so
      the session ref count is only bumped on non-replay. Clean up the
      nfs4svc_encode_compoundres session logic.
      
      The nfsd4_compound_state statp pointer is also not used.
      Remove nfsd4_set_statp().
      
      Move useful nfsd4_cache_entry fields into nfsd4_slot.
      
      Signed-off-by: Andy Adamson <andros@netapp.com
      Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
      557ce264
    • A
      nfsd41: replace nfserr_resource in pure nfs41 responses · bdac86e2
      Andy Adamson 提交于
      nfserr_resource is not a legal error for NFSv4.1. Replace it with
      nfserr_serverfault for EXCHANGE_ID and CREATE_SESSION processing.
      
      We will also need to map nfserr_resource to other errors in routines shared
      by NFSv4.0 and NFSv4.1
      Signed-off-by: NAndy Adamson <andros@netapp.com>
      Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
      bdac86e2