Commit Graph

11 Commits

Author SHA1 Message Date
Peter Goodman b0f7790f43 Sparc support (#709)
* Adds sparc support; formats files

* Update the readme and walkthrough

* Minor tweaks to readme/walkthrough

* Update ci.yml
2020-11-05 12:59:20 -05:00
Peter Goodman d9bbd1ea7c Python 3 support for mcsema-disass. (#699)
* Python 3 support for mcsema-disass.

* Conditional Python3 installation libraries

* Add conditional check for Python2 also

* Update CMakeLists.txt

Make the install options for py2/3 always available.

* Fix CI tool name

* Update flow.py

Co-authored-by: Eric Kilmer <eric.d.kilmer@gmail.com>
2020-10-06 16:19:52 -04:00
Peter Goodman 31f267bd5f Cmake refactor (#693)
* Update to latest remill APIs and way of using CMake.

* Minor fixes

* Bug fixes for AArch64

* Tweaks

* Adds some nifty functionality useful for debugging some aarch64 bugs

* Fixes a subtle bug

* Bug fixes

* Make the test suite use explicit args

* Bug fix in xrefs

* Disable tests for now
2020-09-22 23:22:56 -04:00
Peter Goodman 2d55d02cc3 API improvements. Must be used with the api_improvements branches of Remill and Anvill (#666)
* API improvements. Must be used with the api_improvements branch of both Remill and McSema

fixes for x86 and running the lifted code with klee

* Update dockerfile to clone anvill

* update remill commit id

* Add python3 to dockerfile

* update python3

* disable abi script

* Updated cmake to find anvill

* Update main.cpp

* update find_package for anvill

* WIP:updated prebuild cfg

* update prebuild cfg files

* enable abi build for testsuite

* Fix memory leak

* install missing package for testcases

* frontend: Reflect cfg file changes in dyninst frontend.

* frontend: Update local files copyrights to reflect overall change to agplv3.

* fix failing testcases

* update test cfgs

* Fix test failure with local state pointer

* set the flag to use local state_ptr in default mode

Co-authored-by: kumarak <iit.akshay@gmail.com>
Co-authored-by: Lukas Korencik <xkorenc1@fi.muni.cz>
2020-07-23 02:14:56 -04:00
Alessandro Gario 1a96bd3712 Update links and remotes to the new organization name (#598)
* Docs: Update links with the new organization name

* CI/Travis: Update remotes with the new organization name

* mcsema-disass: Update links with the new organization name

* Dockerfile: Update remotes with the new organization name
2019-10-27 12:56:23 -04:00
Alessandro Gario 940ccd5357 mcsema_disass: Add support for IDAPython 7.1 (#411)
* mcsema_disass: Add support for IDAPython 7.1

* Code review changes

* Fix elf thunk identification for IDA 7.0

* check if the ref addr falls into LOAD segment

* Resolved merge conflict

* Check the LOAD segment before resolving xrefs

* Changes idc.GetMnem to idc. print_insn_mnem

* Move CFG recovery scripts to ida7

* Handle addresses which are in the middle of struct and unable to make xrefs

* Update with the master

* ida import

* handle references of external vtable

* Fix string recovery for apache binary

* IDA 6.x not detecting the typeinfo symbol refs and considering it as string
2018-09-04 12:50:46 -04:00
Adrian Herrera 8dfb574bb6 Some minor fixes (#302)
* Walkthrough: removed references to entrypoint option while lifting

This option doesn't seem to exist anymore.

* setup.py: added install_requires for required packages

* binja disass: added padding for read_{d,q}word functions

bv.read is not guaranteed to return the number of bytes asked for. When it
doesn't, pad the return value.
2017-10-11 23:31:37 -04:00
Kareem El-Faramawi d798dbcf92 Add Binary Ninja CFG recovery (#297)
* Add stub binja package

* Add binary loading, defs parsing, initial structure

* Add basic segment processing

* Nicer logging

* Partial externals recovery

* Fix has_return/no_return for external funcs

* Start of function recovery

* Resolve calling convention for unknown externals

* Add local_noreturn detection

* Add xref recovery

* Add jump table recovery

* Avoid duplicate symbol definitions

* Resolve missing successors for relative jump tables

* Use new-style python classes
2017-09-19 14:24:36 -04:00
Peter Goodman c4d9172a2b Start of aarch64 support in the idapython script. I am probably missing some mappings of opcodes to instruction personalities. The next big challenge is dealing with certain types of data references. The cross-references generator tells us there are refs, but looking for target fixups or operand addresses (for pgoffs and friends) doesn't help. 2017-04-27 11:50:17 -04:00
Peter Goodman 93b4aa56b4 WIP. Modified license to apache 2.0 to follow remill, also most code is new anyway. 2017-04-15 16:27:35 -04:00
Peter Goodman bcda6a120a Llvm38 (#112)
* - Upgrade to official llvm 3.8
- remove boost
- unify all cmake files into a single cmake file
- use official protobuf
- start factoring out x86-specific stuff to eventually make an arm port easier
- simplify the CLI; now use mcsema-lift, with -arch, -os, -cfg, -entrypoint, and -o. No more having to specify the target triple.
- moves source code slightly closer to our style guide

Note:
- lifted bitcode is not quite right in some cases, so this isn't a stable branch!
- TODO: re-add test cases to discover source of stability problems.

* Some minor fixes, one to make sure xmm regs in the state struct are properly aligned

* Added missing std defs for option parsing. This makes /bin/ls work properly :-)

* Remove old cmake files

* Minor changes to get_cfg.py and raiseX86.cpp in relation to those changes. Those changes don't fix anything, the purpose was to make symbol names for things match between python and cpp. E.g. get_cfg would name things like dta_0xf00, sub_0xf00, ext_... And it seems that it was dta_ instead of data_ for a reallly flaky and dumb reason but oh well. I also fixed a subtle bug related to saving and restoring of callee saved registers on elf 64. I have not made related changes to elf 32 or pe 32/64, though those may be necessary.

* Minor fix

* Adding mcsema-disass, which is a nice wrapper around get_cfg.py.

* Working on readme and cleaning out (currently) unused stuff from the repo

* Renaming mc-sema dir to mcsema

* new travis file

* Updates to bootstrap and build process

* Minor bootstrap fixes

* Well, don't have windows working yet but this is kind of progress I think

* Travis should work now

* Updating protobuf-cmake files so we can generate a VS2015 solution

* Removing and adding some choco packages from README

* Bootstrap now builds protobuf and generates protobuf files
LLVM should now be built on Windows

* Adding Win32 specific compiler options

* Renamed ConstantInt to CreateConstantInt to satisfy MSVC

* Build Release LLVM to not have linking conflicts of MD vs MDd

* Added some missing instructions

* Adding changes to generate runtimes

* Windows bootstrap works.
2017-02-23 13:23:31 -05:00