Results 1 to 8 of 8

Thread: Tools and tips to read and understand open source?

  1. #1

    Tools and tips to read and understand open source?

    Hi,

    I have downloaded some c++ open source code which I'd like to study to see how it all works. This is a multiple file project, so on first inspection there is a lot of navigation between header file and code files.

    Naturally, I searched a little using Google and found a few IDEs that claim to help with the anaylsis of unknown code. Tools like Source Insight, Understand for C++, Source Publisher, UltraEdit and so on.
    What tools do you guys use? (commercial or free).

    I'd like to ask what you guys recommend to help accomplish a quick and reliable analysis?

    This project may be complicated by the fact that I am learning C++ as I go along. Do you consider producing UML diagrams will be a helpful aid to my understanding of how things work together?

    I appreciate recommendations to help me get this project off to a productive start.

    Once I know how it all works I hope to add my own code to meet my requirements.

    Thanks,
    5aLIVE.
    Last edited by 5aLIVE; August 23rd, 2006 at 05:13.

  2. #2
    <script>alert(0)</script> disavowed's Avatar
    Join Date
    Apr 2002
    Posts
    1,281
    If you already have an idea of what functionality you want to add, you probably don't have a need to know "how it all works". Your best bet is to look for strings and/or API function references related to the functionality you want to modify/add and start reading the code around there. This is actually the same procedure when you only have a binary and no source code.

  3. #3
    very good question,

    my personal experience is: reading the source code files somehow systematically is most helping for me. header files to get an overview of functions / objects, and implementation files for hardcore analysis
    thereby using the search function of multiple file editor extensively. (or "grepping" on *nux/*nix).

    the much i like graph(ic)s i havent ever used a tool that made understanding source useful, but i'd be interested on that, too.
    syntax highlighting is probably the best invention

    you might be able to integrate new code / update existing code by concentrating on what you want to change and finding the appropriate place to do so, even without understanding all code. the involved code parts you probably should read and read and read - there is no way about that i am afraid

    regards, 0xf001

  4. #4
    Visual Studio + Visual Assist is a godsend for quickly mapping large sources. Although you'll have to spend the time up front getting the VS workspace (sorry, solution, I still use VC6) configured properly if the code doesn't come with one.
    Still here...

  5. #5
    You can't 'reverse' open-source code any more than you can unscrew a screw that's already out of its hole

    The source is the source, if you want to understand it I recommend you start at any portion that interests you, or lacking that, main(). A text editor with multifile capability and a good Find function is an asset.

  6. #6
    @disavowed,@0xf001, Having since taken the time to look through the code it is apparent that it would take forever to analyse if I were to try and understand how everything works. It is encouraging that I only need to digest only part of the code.

    It doesn't seem like such an ambitious/overwhelming proposition as I first thought.

    @Silver, Wow! Visual Assist X is absolutely fantastic! It completely transforms the usability of the VC6 IDE.
    Thanks for the headsup. A must have tool.

    @LLXX, I don't think I mentioned "reversing" in my post, however I'm not sure I agree with your statement.
    I realise that the main function of reverse code engineering is to gain understanding of how a speific part of program works when the source code is not available.

    Having said that, wouldn't you agree that trying to make sense of a third parties source code is a form of reverse engineering, producing UML diagrams after the code has been written is reverse engineering in itself.
    Once, the code is understood, the program can be developed further which is what I would describe as the process of forward engineering. Maybe a misunderstanding of the term on my part (semantics).

    Thanks for sharing your thoughts.

  7. #7
    i think reversing source code is also, reversing, has not only to do with binaries, it is a part of i think
    can also be very complex to understand all the concepts, interactions etc of an app. i must try that assist then once thx for the tip!

    cheers, 0xf001

  8. #8
    5alive, VA-X is great, isn't it. Unfortunately as a friend of mine says, it's like crack cocaine for coding. Use it for a while and you won't realise just how dependant you become on it, then try to code without it and you'll be reduced to a quivering useless wreck
    Still here...

Similar Threads

  1. Replies: 0
    Last Post: August 15th, 2010, 11:37
  2. will ollydbg ever be open source?
    By jaked in forum Bugs
    Replies: 1
    Last Post: September 27th, 2005, 04:14
  3. I can't understand this problem,who can help
    By prince in forum Plugins (General)
    Replies: 3
    Last Post: June 15th, 2004, 03:27
  4. to understand a break and a API
    By newbcrk in forum The Newbie Forum
    Replies: 2
    Last Post: May 30th, 2003, 12:56
  5. open source tools
    By neutrino in forum Tools of Our Trade (TOT) Messageboard
    Replies: 10
    Last Post: November 10th, 2002, 02:27

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •