Re: Howto read a file off disk?

From: Omen Wild (Omen.Wildat_private)
Date: Fri Jul 18 2003 - 07:39:13 PDT

  • Next message: Jesse Pollard: "Re: Howto read a file off disk?"

    Quoting Seth Arnold <sarnoldat_private> on Wed, Jul 16 21:51:
    >
    > Nah, the usermodehelper thing can't block for reading response from
    > userspace. Fire and forget. It probably isn't what you want.
    
    [ snip ]
    
    > But please give the user daemon option a shot before resorting to
    > this.
    
    I have to admit I'm confused over these two statements.  Any user
    daemon would have to block the kernel from finishing the open operation
    until it could decided if the file is intact.  Or are you suggesting a
    much more complicated scheme would be required (a queue with an upcall
    when the daemon finishes)?
    
    Has anyone compiled a list of arguments for/against implementing things
    in user space?  I want to do the right thing, but I can't convince
    myself that doing it in the kernel is wrong.
    
    > And, against my better judgement, I'll mention that you can use
    > kernel_read() to read files from within the kernel.
    
    Thanks for the pointer, that did the trick!
    
    Now, how about opening a file from within the kernel?  I have a config
    file to read.  I saw a message in the archives about this and someone
    recommended a /proc interface, but I need to be able to verify init as
    it is read off the disk, before any part of user space is running.
    
    Omen
    
    -- 
    One advantage of talking to yourself is that
    you know at least somebody's listening.
    
    
    

    _______________________________________________ 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 : Fri Jul 18 2003 - 07:40:08 PDT