VFS open call intercept

Sharayu Mantri sm25541994 at gmail.com
Sun Mar 15 02:00:22 MDT 2015


Sir,
I wanted to intercept Open Vfs call and when file from shared folder is
accessed from windows open call should update the increased frequency (no
of times the file is accessed) of that file in database. Here i am using
Berkeley DB . But I am not sure if the way i have intercepted the open call
is correct. Or is it possible to that whenever i file is created in shared
folder by server or windows client then VFS adding tht file in databse ? In
such case which function call shou;d be interrupted because these functions
keep on calling continoulsy.
I have attached my skel_transparent code which intercepts Open vfs call ,
If you could just lok into and advice me if it is correct or it could be
done any better.

Also I am encountering another problem that i have  berkeley db in my
samba. And the close function is conflicted by some close function of vfs.
Although my dbp->close() takes in DB_CLOSE takes 2 parameters it says error
that  Close should  take one parameter. Is their a way where  i could
resolve this conflict of vfs close and db close.

Thanks and regards,
Sharayu Mantri.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: skel_transparent.c
Type: text/x-csrc
Size: 17946 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20150315/2099233e/attachment.c>


More information about the samba-technical mailing list