[cfe-dev] Reflections on Trusting Trust
John Criswell via cfe-dev
cfe-dev at lists.llvm.org
Tue Feb 28 07:09:53 PST 2017
On 2/27/17 8:33 PM, Willem Wyndham via cfe-dev wrote:
> I'm working a project to add a bug to Clang that is inspired by Ken
> Thompson's famous article. My question is where in clang should I edit
> to add source to the input source? I need my added source to be
> internal to clang so that when I compile normal clang with my binary
> the bug will still exist in the new compiler.
You probably want to examine and transform the Abstract Syntax Tree
(AST) instead of the program's actual source. I have not worked with
the Clang libraries myself, but from what I understand, Clang provides
something like LLVM's transform passes for modifying the AST.
Clang has some bug detection code that you could look at; this would
help you learn how to examine the AST.
Regards,
John Criswell
>
> Best,
> Willem Wyndham
> Phd Student UMD, College Park
>
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
--
John Criswell
Assistant Professor
Department of Computer Science, University of Rochester
http://www.cs.rochester.edu/u/criswell
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20170228/ceb787c5/attachment.html>
More information about the cfe-dev
mailing list