Thanks,
Trip
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (Darwin...@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/darwin-kernel/darwin-kernel-garchive-95844%40googlegroups.com
This email sent to darwin-kernel-...@googlegroups.com
> I have been examining the kauthORama code on the apple web site. I am interested in monitoring file_open requests. Can anyone direct me to suitable documentation or examples whch explain the way or mechanisms to send messages or strings to user land applications? Would this involve the creation of ports? Can this done in a kext? Can you /should you send messages from a kext?
I might recommend picking up a copy of:
OS X and iOS Kernel Programming [Paperback]
Ole Henry Halvorsen (Author), Douglas Clarke (Author)
• ISBN-10: 1430235365
• ISBN-13: 978-1430235361
also, do a search for Apple's documentation 'Kernel Extension Programming Topics.' It is quite good, but can be a bit dense in some places.
And, yes, it is certainly possible to send data between user land and a kext.
Trip
Singh's book is a bit dated at this point, and most of it isn't about
practical kernel programming as such - it's more of a description of
the whole system, going well beyond just the kernel, and with just one
chapter on making your own kexts. Having said that, I still look
things up in it with some regularity, as some things haven't changed
(much) since OSX 10.4. It's around 1200 pages, so even if most of it
isn't of much interest to you, there will undoubtedly be some useful
stuff in there.
Halvorsen's book is rather more practical and focused on kext
programming. Things like memory management, user/kernelspace
communication, synchronisation and threading, debugging, etc. are
generally applicable to all kinds of kernel extension. As you say
there are quite a few chapters for various different types of device
drivers, but IIRC there's also a chapter specifically about
non-device-driver network kexts. Contrary to what the title of the
book suggests, there's no practical info about iOS in there, by the
way, I can only assume that's a marketing gimmick.
Amazon's "look inside" feature is probably your best bet for deciding
what to go for.
(disclosure: I was one of the tech reviewers for the Halvorsen book -
I don't get any incentives, financial or otherwise for recommending
it; note also that I only read an early draft of the book, but as far
as I know the structure stayed the same)
Hope that helps,
phil