help regarding encryption and decryption of files on linux

we are to develope a project on linux whose aim is to automatically encrypt files after logoff and to decrypt them using password after log in
this is to be made by chging source code of linux ...........
can any one help me on this????

Never done this... useful read though!!

Linux Encryption HOWTO: Encrypting Disks