Commit Graph

4121 Commits

Author SHA1 Message Date
Nguyen Anh Quynh
38e9716275 wasm: remove unused variable 2019-02-21 20:52:59 +08:00
Nguyen Anh Quynh
f59dac2237 Merge branch 'next' of github.com:aquynh/capstone into next 2019-02-21 15:33:54 +08:00
Nguyen Anh Quynh
85cac968ef X86: X86_insn_reg_att uses a wrong mapping array of Intel syntax 2019-02-21 15:33:14 +08:00
Catena cyber
5f20fba9de Adds corpus generation for bpf architecture (#1396)
* Adds corpus generation for bpf architecture

* Updes HACK.txt with MC files to be added with a new architecture
2019-02-21 10:42:31 +08:00
Catena cyber
e5fa5f8735 Avoids leak in wasm details (#1372)
* Avoids leak in wasm details

Extending cs_detail in capstone.h

* Safety checks before allocating memory for brtable in WASM

* Revert "Avoids leak in wasm details"

This reverts commit 03f822b34a03f23554aaffb2951b62c62645e5e5.

* Refactoring brtable for WASM

* Fix undefined shift in WASM get_varuint64
2019-02-20 23:38:11 +08:00
Anton Bolshakov
466cb1b2fd respect libsuffix in pkgconfig (#1393)
* respect libsuffix in pkgconfig

discovered in https://bugs.gentoo.org/677946

* Update CMakeLists.txt

* Update CMakeLists.txt

* Update CMakeLists.txt
2019-02-20 10:12:42 +08:00
Nguyen Anh Quynh
3570936dc0 Merge branch 'next' of github.com:aquynh/capstone into next 2019-02-19 10:49:27 +08:00
Nguyen Anh Quynh
0561a4fc10 cstest: add issue #1129 2019-02-19 10:49:07 +08:00
david942j
a28027bbe1 wasm: fix misordering (#1391) 2019-02-19 00:10:36 +08:00
Nguyen Anh Quynh
0e0fb6de52 cstest: issues with description, rather than 2019-02-18 21:44:26 +08:00
Nguyen Anh Quynh
7ecf7c6410 cstest: add some branch instructions with absolute addresses for x86 2019-02-18 21:25:25 +08:00
Nguyen Anh Quynh
462e7e089b cstest: add issue 1389 testcase to issues.cs 2019-02-18 20:18:06 +08:00
Nguyen Anh Quynh
972617ffff suite/capstone_get_setup.c: add BPF arch 2019-02-18 20:11:19 +08:00
Nguyen Anh Quynh
a442e9d1f7 bpf: print setup config in cstool -v 2019-02-18 20:06:11 +08:00
david942j
9b3ead3ab8 fix conflicts 2019-02-18 20:04:30 +08:00
david942j
b227acc29c New architecture: BPF (#1388)
* Basic changes of new arch - BPF

* Define some constants

* defined some API methods

* Able to print MISC instruction

* Follow Linux coding style

* Ability to show ALU insn names

* decode return

* Add suite/MC/BPF

* decode jump

* decode store

* decode load

* print instruction done

* try to implement BPF_reg_access

* Implements explicit accessed registers and fix some tiny bugs

* Fix unhandled ja case

* Added BPF_REG_OFF do fix wrong display in jump class

* Great I'm able to decode cBPF with eyes

* Fix: misunderstood the 16-byte instruction's imm

* Add ldxdw

* Add extended-all.cs

* Implements cstest/bpf_getdetail.c

* Fix memory leak

* Add BPF to fuzz

* Implemented regs_read and regs_write

* Fix missing write-access on ALU's dst

* Updated cstool/, test_basic.c, test_detail.c, and test_iter.c

* Updated docs

* Fix type of cs_bpf#operands

* Implements python bindings

* Fix some bugs found by self code review

* Remove dummy tests

* remove typeof

* Address comments

* Fix MSVC's warnings and add test_bpf.py to bindings/python/Makefile

* Fix: call is not offset
2019-02-18 17:39:51 +08:00
Nguyen Anh Quynh
fd433d897a x86: 8bit Imm operand has size = 1. this fixes issue #1389 2019-02-18 17:31:03 +08:00
Nguyen Anh Quynh
0eb9f20dfe python: add test_evm.py to Makefile check target 2019-02-18 10:46:57 +08:00
Nguyen Anh Quynh
a7f12d96b0 cstool: print extra options in alphabet order 2019-02-18 10:45:52 +08:00
Nguyen Anh Quynh
19351b5b76 cstool: indent Wasm usage 2019-02-18 10:44:12 +08:00
Nguyen Anh Quynh
7b47192b1a python: make test_evm.py to output like test_evm.c 2019-02-17 23:19:56 +08:00
Семён Марьясин
059ac6d7cc Fix skipdata struct being destroyed (#1385) 2019-02-17 01:32:12 +08:00
Invincible
74c67daf35 For the benefit of mankind. (#1386)
For the peace and tranquility of the earth.
2019-02-17 01:32:08 +08:00
Catena cyber
254c58b47a Fixes more undefined left shift of negative values (#1384) 2019-02-16 10:33:21 +08:00
Catena cyber
b43db80f9a Avoids overflow in getRegisterName for TMS320C64x (#1375)
* Avoids overflow in getRegisterName for TMS320C64x

* Revert "Avoids overflow in getRegisterName for TMS320C64x"

This reverts commit 18acee60cd.

* Checks register in DecodeMemOperandSc
2019-02-16 10:32:15 +08:00
Catena cyber
53bb84df61 Updates test_corpus to support new examples (#1383) 2019-02-15 22:45:45 +08:00
Catena cyber
2426038f31 Multiply signed integer instead of left shift (#1382) 2019-02-15 22:35:04 +08:00
Nguyen Anh Quynh
b57ddf8bc5 merge master to next branch 2019-02-15 10:51:04 +08:00
Nguyen Anh Quynh
ee09a82235 README: pypi downloads 2019-02-15 08:58:46 +08:00
Catena cyber
31f8e8e0be Avoid overflow in SStream.c (#1381) 2019-02-15 08:18:31 +08:00
Catena cyber
06f042c515 Fix undefined shift in WASM disassembler (#1380) 2019-02-15 08:18:03 +08:00
Đỗ Minh Tuấn
c7fbb5d4cd Another way to solve when compare with issue (#1379)
* cstest: partial details are supported in issues.cs
2019-02-15 00:12:18 +08:00
Đỗ Minh Tuấn
74e15a0263 Integrate into travis cli (#1378)
* Comment out all failed tests
* Integrate with Travis
2019-02-14 22:15:12 +08:00
Nguyen Anh Quynh
695709f180 Merge branch 'HarDToBelieve-master' 2019-02-14 16:24:37 +08:00
Nguyen Anh Quynh
44be32dd50 cstest: code style 2019-02-14 16:24:22 +08:00
Đỗ Minh Tuấn
9e26ddb9c0 Fix bugs (#1377)
* fixing

* Done fixing
2019-02-14 16:23:18 +08:00
HarDToBelieve
8f4bf69f62 Done fixing 2019-02-14 14:13:45 +07:00
hardtobelieve
cd2e9567a2 fixing 2019-02-13 20:01:26 -08:00
Nguyen Anh Quynh
23c73c0aa1 cstest: allow space between !# and arch (issues.cs) 2019-02-14 10:19:21 +08:00
Nguyen Anh Quynh
9216f2f5c4 cstest: fix conflicts 2019-02-14 01:30:39 +08:00
Đỗ Minh Tuấn
0c2df58792 Add more features to CSTEST (#1376)
* fix crash

* MC: alias registers for Mips

* MC: alias registers for Mips - v1

* MC: alias registers for Mips

* MC: alias registers for Mips

* MC: more fix for Mips .cs

* MC: more fix for Mips .cs

* add comment feature

* free mem

* Done fixing

* Done

* rename report

* fix README
2019-02-14 01:29:07 +08:00
Nguyen Anh Quynh
3e93dfb8d5 MC: fix missing option field in some .cs files 2019-02-14 01:13:08 +08:00
Nguyen Anh Quynh
3e65606333 cstest: update README 2019-02-14 00:59:19 +08:00
hardtobelieve
71f86ed135 fix README 2019-02-13 08:30:20 -08:00
hardtobelieve
10a9e81a06 rename report 2019-02-13 08:25:13 -08:00
hardtobelieve
d71d2e4e65 Done 2019-02-13 08:03:23 -08:00
hardtobelieve
a136eda2a0 Merge remote-tracking branch 'upstream/master' 2019-02-13 07:09:45 -08:00
hardtobelieve
e2dcef5035 Done fixing 2019-02-13 06:49:54 -08:00
Nguyen Anh Quynh
bc355fffcc cstest: comment out 2 testcases 2019-02-13 22:24:32 +08:00
Nguyen Anh Quynh
f38aec3d72 arm64: fix CS_OPT_UNSIGNED option on memory operand offset 2019-02-13 22:12:00 +08:00