get_write_access hook

From: Seth Arnold (sarnoldat_private)
Date: Mon Oct 01 2001 - 16:28:51 PDT

  • Next message: Seth Arnold: "Re: get_write_access hook"

    Greetings;
    
    I've been working a on project that would benefit from having a hook in
    fs/namei.c's get_write_access function.
    
    For our own uses, we could get away with having the hook in the
    if(writecount<0) block; however, someone else may like to have the hook
    before the if statement, so that both the negative and non-negative
    clauses are covered. If no one around here thinks they could use the
    hook in both cases, let me know, and I can move the hook to just where
    we want it. :)
    
    Also, in its current state, this hook doesn't actually have input into
    the return value of get_write_access -- our application doesn't need it.
    If you think your application could benefit from having the hook have
    some input to the decision, let me know, and I can fix it. :)
    
    Chris and I have poked around, and it appears that anything calling
    get_write_access is prepared to handle most error returns, usually by
    handing the return to the userspace caller (eventually). However, this
    function isn't always called when modifying the i_writecount parameter,
    so I'd be cautious suggesting that it should be used to grant/deny
    access to the file directly.
    
    Comments?
    
    
    

    _______________________________________________ linux-security-module mailing list linux-security-moduleat_private http://mail.wirex.com/mailman/listinfo/linux-security-module



    This archive was generated by hypermail 2b30 : Mon Oct 01 2001 - 18:49:49 PDT