diff options
author | cdn@chromium.org <cdn@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-01 22:38:10 +0000 |
---|---|---|
committer | cdn@chromium.org <cdn@chromium.org@4c0a9323-5329-0410-9bdc-e9ce6186880e> | 2010-10-01 22:38:10 +0000 |
commit | 2b4274afc4fae883d1251a7a420e24fd526a9f16 (patch) | |
tree | d9cafcfb8d68b4c005f5cb80c15e3286c291b067 /src/third_party/libdisasm/ia32_settings.h | |
parent | Add stack-scanning fallback to Stackwalker{AMD64,ARM}. (diff) | |
download | breakpad-2b4274afc4fae883d1251a7a420e24fd526a9f16.tar.xz |
Added libdisasm to the repository. This library is no longer under development so there
is no reason not to keep it locally. Implemented a basic disassembler which can be used
to scan bytecode for interesting conditions. This should be pretty easy to add to for
things other than exploitability if there is a desire. This also adds several tests to
the windows exploitability ranking code to take advantage of the disassembler for x86
code.
BUG=None
TEST=DisassemblerX86Test.*
Review URL: http://breakpad.appspot.com/203001
git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@705 4c0a9323-5329-0410-9bdc-e9ce6186880e
Diffstat (limited to 'src/third_party/libdisasm/ia32_settings.h')
-rw-r--r-- | src/third_party/libdisasm/ia32_settings.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/src/third_party/libdisasm/ia32_settings.h b/src/third_party/libdisasm/ia32_settings.h new file mode 100644 index 00000000..769c0e9f --- /dev/null +++ b/src/third_party/libdisasm/ia32_settings.h @@ -0,0 +1,27 @@ +#ifndef IA32_SETTINGS_H +#define IA32_SETTINGS_H + +#include "libdis.h" + +typedef struct { + /* options */ + unsigned char endian, /* 0 = big, 1 = little */ + wc_byte, /* wildcard byte */ + max_insn, /* max insn size */ + sz_addr, /* default address size */ + sz_oper, /* default operand size */ + sz_byte, /* # bits in byte */ + sz_word, /* # bytes in machine word */ + sz_dword; /* # bytes in machine dword */ + unsigned int id_sp_reg, /* id of stack pointer */ + id_fp_reg, /* id of frame pointer */ + id_ip_reg, /* id of instruction pointer */ + id_flag_reg, /* id of flags register */ + offset_gen_regs, /* start of general regs */ + offset_seg_regs, /* start of segment regs */ + offset_fpu_regs; /* start of floating point regs */ + /* user-controlled settings */ + enum x86_options options; +} ia32_settings_t; + +#endif |