urwithajit9 / pefile Goto Github PK
View Code? Open in Web Editor NEWThis project forked from erocarrera/pefile
Automatically exported from code.google.com/p/pefile
License: Other
This project forked from erocarrera/pefile
Automatically exported from code.google.com/p/pefile
License: Other
-------------------------------------------------------------------- pefile - Portable Executable reader module -------------------------------------------------------------------- INTRODUCTION pefile will allow to access from any Python script all (or most) of the contents of a given PE file. The structures defined in the Windows header files will be accessible as the PE instance attributes and will have the same names as defined there. (The main structures will have the standard capitalized names and will be attributes of the PE instance. Their members will be attributes.) Other attributes and data, which require further processing but are very useful will be available as lowercase attributes. Some of those are, the imported and exported symbols and the sections, with direct access to their data (if any) and convenient methods to retrieve data based on the address as if the file were loaded, instead of needing to dig the offsets into the file. WRITTING SUPPORT Starting from pefile 1.2 it's possible to write back any changes done to the PE file. One has to be careful with this functionality as it will not be very intelligent reconstructing the PE file. That is, it will not handle displacing structures if that would be needed because a new section has been added. The rule of thumb is, if there's room for an additional header/structure to fit then there'll be no problem and pefile will write it. All other modifications, i.e. changing individual values in header/structure members should work well. One possible useful application of this could be to correct malformed headers used by some malware in order to cause certain analysis tools to malfunction. AVAILABILITY Last versions are available at: http://dkbza.org/pefile.html INSTALLATION/USAGE Just importing it should suffice. The module should be endianness independent and it's known to work on OS X, Windows, and Linux. TODO There might be some obscure info which is not readily accessible, this may be due to my ignorance or laziness. Patches or suggestions are, as usual, welcomed. Thinks known to be missing so far: -Reading and processing the exceptions directory entry. (Architecture dependent info) BUGS Given the amount of information embedded in the PE file format it is difficult to test all the data retrieved thoroughly. I did my best trying and verifying the accuracy of all the parsing. Most of the basic data has been tested by using this module, so no outrageously obvious problems should exist. Any feedback on inconsistent or faulty behavior will be welcome. ------------------------------------------------------------------------- Copyright (c) 2005-2013 Ero Carrera <[email protected]>. All rights reserved. -------------------------------------------------------------------------
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.