Windows Security
  Home arrow Windows Security arrow Page 3 - Windows Reverse Engineering
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Silverlight  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
ASP Web Hosting  
ASP.NET Web Hosting 
Windows Web Hosting
 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
WINDOWS SECURITY

Windows Reverse Engineering
By: O'Reilly Media
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 23
    2004-07-27

    Table of Contents:
  • Windows Reverse Engineering
  • History of RCE, Reversing Tools
  • Basic IDA Configuration and Manipulation Steps
  • Debuggers
  • System Monitors
  • Unpackers
  • Personal Firewalls and Install Managers
  • Reverse Engineering Examples
  • Example 2: Reversing Malicious Code

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Windows Reverse Engineering - Basic IDA Configuration and Manipulation Steps


    (Page 3 of 9 )

    A configuration file controls IDA’s preferences. Search your Program Files directory for the IDA folder and use a text editor to open Ida.cfg (the configuration file). The configuration file is read two times. The first pass is performed as soon as IDA is loaded, while the second pass is performed when IDA determines the processor type. All processor-specific tuning is located in the second part of the config file.

    IDA allows you to choose the default processor at program startup. As you can see in Example 2-1, the developers have created support for an extensive range of processor types. Here, you can view the processors that IDA supports. For example, if you mostly crack PocketPC (Windows CE) applications, you will probably be using the ARM processor. Otherwise, the default is setting is "metapc" (x86).

    Example 2-1. Processor-specific parameters in IDA Pro

    /* Extension    Processor */
    "com" :  "8086"        // IDA will try the specified
    "exe" :  "metapc"      // extensions if no extension is
    "dll" :  "metapc"      // given.
    "drv" :  "metapc"
    "sys" :  "metapc"
    "bin" :  "metapc"
    "ovl" :  "metapc"
    "ovr" :  "metapc"
    "ov?" :  "metapc"
    "nlm" :  "metapc"
    "lan" :  "metapc"
    "dsk" :  "metapc"
    "obj" :  "metapc"
    "prc" :  "68000"      // PalmPilot programs
    "axf" :  "arm710a"
    "h68" :  "68000"      // MC68000 for *.H68 files
    "i51" :  "8051"       // i8051 for *.I51 files
    "sav" :  "pdp11"      // PDP-11 for *.SAV files
    "rom" :  "z80"        // Z80 for *.ROM files
    "cla*":  "java"
    "s19":          "6811"
    "o":          "metapc"
     

    IDA allows you to tune several options for disassembly. For example, you can determine whether you want to automatically analyze 90h NOPs. The configuration for this is shown in Example 2-2.

    #ifdef __PC_ _   // INTEL 80x86 PROCESSORS
    USE_FPP  = YES
       // Floating Point Processor
       // instructions are enabled
    // IBM PC specific analyzer options
    PC_ANALYSE_PUSH = YES   // Convert immediate operand
       // of "push" to offset
       //
       // In sequence
       //
       // push seg
       // push num
       //
       // IDA will try to
       //convert <num> to offset.
       //
    PC_ANALYSE_NOP   = NO   // Convert db 90h after
       // "jmp" to "nop"
       // Now it is better to turn
       // off this option
       // because the final pass
       // of the analysis will
       // convert 90h to nops
       // more intelligently.
       //
       // Sequence
       //
       // jmp short label
       // db 90h
       //
       // will be converted to
       //
       // jmp short label
       // nop

    Now, it’s time to fire up IDA. Run the program and open the target binary that you happen to be using. Figure 2-2 shows IDA’s startup window.

    warrior

    Figure 2-2

    On most Windows files you will use the Portable Exectuable (PE) format (discussed later in this chapter), so select this option. Select your processor type if you have not already configured the default in your config file. Make sure both “Analysis” options are checked. Under Options, make sure the “Load resources” and “Make imports segment” boxes are checked. Also make sure “Rename DLL entries” and “Manual load” are unchecked.

    Make sure that you chose the correct system DLL directory when configuring IDA Pro.

    When you are ready, press OK and watch IDA work its magic.

    In order to view strings in IDA, select View -> Open Subviews -> Strings (Figure 2-3). You will also see the other subview options. The keyboard shortcut for strings is Shift-F12. Take some time to explore this sample disassembly and to get used to moving around in IDA.

    warrior

    Figure 2-3

     

    Buy the book!If you've enjoyed what you've seen here, or to get more information, click on the "Buy the book!" graphic. Pick up a copy today!

    Visit the O'Reilly Network http://www.oreillynet.com for more online content.

    More Windows Security Articles
    More By O'Reilly Media


     

    WINDOWS SECURITY ARTICLES

    - Which Version of Windows 7 Should You Use?
    - Choosing the Best Windows XP Firewall
    - Finding the Correct Drivers for Windows XP D...
    - Windows Network Troubleshooting: Tips and Te...
    - Windows XP Home Network Setup: Essential Ste...
    - Using Windows Recovery Console to Fix Blue S...
    - Fix Blue Screen of Death in Windows XP: Corr...
    - Storing Data with Windows Skydrive
    - Windows System Administrator`s Toolbox
    - Solving Windows Genuine Advantage Problems
    - Encrypted Browsing in Windows using OpenSSH
    - Working with the Hosts File on Windows XP
    - Inventorying HDDs Remotely on Windows
    - Inventorying RAMs Remotely on Windows
    - Vital Windows Security Guidelines





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek