Pierre Gagelin via llvm-dev
2016-Jun-09 09:57 UTC
[llvm-dev] Fatpointer Pass already existing?
Hi everyone, After spending 2 months on LLVM generally speaking and more specifically on security passes (ASan, SAFECode, BoundsChecking) I wanted to know if there were an available implementation of strictly fat-pointer based approach to enforce bounds? If not, I wanted to implement one. I think it is interessant to have such a tool available even if there are better designs (SoftBound does have a fat-pointer approach with separated metadata accessible by hash table or shadow space which allows to have compatibility). Thanks for your advice, Pierre -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160609/4f6ed59c/attachment.html>
David Chisnall via llvm-dev
2016-Jun-09 10:12 UTC
[llvm-dev] Fatpointer Pass already existing?
On 9 Jun 2016, at 10:57, Pierre Gagelin via llvm-dev <llvm-dev at lists.llvm.org> wrote:> > After spending 2 months on LLVM generally speaking and more specifically on security passes (ASan, SAFECode, BoundsChecking) I wanted to know if there were an available implementation of strictly fat-pointer based approach to enforce bounds? > > If not, I wanted to implement one. I think it is interessant to have such a tool available even if there are better designs (SoftBound does have a fat-pointer approach with separated metadata accessible by hash table or shadow space which allows to have compatibility).I had a student implement one a couple of years ago, though I don’t think his code will work with a recent LLVM. Note that it’s quite difficult to do in the general case, because (for inline metadata) you must do whole-program analysis to know which allocations need to be bigger, which function signatures need changing to pass the metadata, and so on. His work included generating ABI-compilant unsafe wrappers for the memory-save modified versions. It’s also difficult to get the atomicity guarantees that most code expects (i.e. that any thread will see either the before or after view of a pointer). David
Pierre Gagelin via llvm-dev
2016-Jun-09 14:59 UTC
[llvm-dev] Fatpointer Pass already existing?
Hi David, I am still working on the model to define it clearly so thanks for these leads, I'll might contact you again to have a deeper discussion on some points if that doesn't bother you. For the moment I am just establishing the theoretical model, didn't had a look on the technical issues (like multi-threaded applications for instance) yet. If it is possible to have an access to the source code of your student's project it would be welcome! Thanks, Pierre -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160609/b91ca82a/attachment.html>