Commit Graph

3899 Commits

Author SHA1 Message Date
Sebastian Macke 7436f54447 MOS65XX: Add architecture to main readme and add name to contributors
Signed-off-by: Sebastian Macke <sebastian@macke.de>
2018-12-06 22:53:43 +01:00
Sebastian Macke 87221fa742 Add support for the MOS65XX family such as the MOS 6502.
Signed-off-by: Sebastian Macke <sebastian@macke.de>
2018-12-06 22:53:33 +01:00
Catena cyber a69f7880a8 Continuous integration for fuzzing (#1297)
* Continuous integration for fuzzing

* Simplify fuzz testing output

* Makefile for suite fuzz

* fixup

* Code review taken into acount

* More readable fuzz harness

Inputs specify only on first line the mode
2018-12-04 15:02:16 +07:00
keenk 37c99df87c Fix a few registry access mode mappings (#1295) 2018-11-26 14:05:29 +07:00
Nguyen Anh Quynh 4948fd1b56 PPC: print 16bit imm as unsigned 2018-11-25 21:12:05 +07:00
Nguyen Anh Quynh f5960097e2
Update README.md
add D binding
2018-11-21 17:45:33 +08:00
Nguyen Anh Quynh 398a047dfc add D binding to README 2018-11-21 17:44:33 +08:00
Dimitri Bohlender 1d18225453 Update README (#1291) 2018-11-21 17:43:15 +08:00
amirgon 29893c63e3 Recognize MSYS compiler as MINGW compiler (#1290) 2018-11-21 00:46:12 +08:00
Dimitri Bohlender f01c267f88 Typo in register's name (#1282)
Fixed Minor typo, i.e. the friendly string representation of X86_REG_ST0 was "st(0"
2018-11-02 07:43:54 +08:00
Nguyen Anh Quynh 641a0dd95b x86: fix instruction suffix of MOV to segment register for ATT syntax. issue #1240 2018-10-26 14:08:18 +08:00
Nguyen Anh Quynh 88d0442e9f x86: fix operand access of FSTP (#1255) 2018-10-25 23:22:48 +08:00
Derrick McKee c3bc43e354 Generate capstone.pc to the location it is installed from (#1265)
* forcing capstone.pc to be generated in the same place it is installed from

* x86: fix operand access of SETE & SETNE (#1262)

* forcing capstone.pc to be generated in the same place it is installed from
2018-10-23 19:42:36 -03:00
ael 0a39b785d3 fix include path in pkg-config template (#1276) 2018-10-23 19:42:01 -03:00
Nguyen Anh Quynh 9408c0de4f Merge branch 'master' of github.com:aquynh/capstone 2018-10-10 14:14:48 +08:00
Nguyen Anh Quynh 260fbdc313 x86: fix operand access of SETE & SETNE (#1262) 2018-10-10 14:07:07 +08:00
blacktop 0999ad1b5e Remove i386 from Makefile (#1260) 2018-10-03 15:21:54 +08:00
Nguyen Anh Quynh a6b87b7bc3 x86: fix operand access of fistp & fstp, in #1255 2018-10-02 12:22:13 +02:00
Nguyen Anh Quynh fc8ba23378 x86: fix operand access of CMP in #1253 2018-10-02 12:18:29 +02:00
Hugo fbeffa489c Add python_requires and update Trove classifiers (#1251) 2018-10-02 17:45:45 +08:00
keenk d872bcdcce Add files via upload (#1256)
Correct register access flag for the movdqa instruction
2018-10-02 17:45:11 +08:00
Bruce Mitchener aed8bffd61 Fix typo: combined. (#1254) 2018-10-02 17:44:39 +08:00
Nguyen Anh Quynh 2b4aec9c76 bindings: make bindings/const_generator.py compatible with recent reformat of C headers 2018-10-01 20:29:39 +08:00
Bruce Mitchener 441d37fbd6 Adjust comments in arch headers for doxygen style. (#1250) 2018-10-01 20:11:21 +08:00
Nguyen Anh Quynh a732cb0ca1 bindings: update PPC constants 2018-09-17 21:01:01 +08:00
Bruce Mitchener 1d40b9ee0a Use doxygen style comments. (#1249)
This converts various documentation comments to use Doxygen-style
syntax so that other tools can pick up and process these comments.
2018-09-17 20:59:47 +08:00
Bruce Mitchener e8b234d237 Fix typos. (#1248) 2018-09-17 20:54:00 +08:00
Tim Brooks e2c1cd46c0 Correct use of strncpy function (#1247)
The last argument should be the max size of the destination, not the
source buffer. A null byte is added to the end of the destination buffer
since strncpy only adds one if it does not truncate the source.
This fixes the -Wstringop-overflow warning on GCC.
2018-09-15 13:47:52 +08:00
beatcracker d70e2b286a Update PowerShell bindings (#1239)
* Remove trailing whitespace

* ~2x speedup by removing array appending

More info: https://powershell.org/2013/09/16/powershell-performance-the-operator-and-when-to-avoid-it/

* Import inline C# conditionally

Avoids errors when importing module using "-Force"

* Throw exception on missing DLL

+ use idiomatic PowerShell

* Throw exception on errors

+ use idiomatic PowerShell

* Throw exception on errors

+ use idiomatic PowerShell

* Use idiomatic PowerShell

* Fix DLL path escaping

* Add native PowerShell formatting

Instruction address will display as "0xdeadbeef" in console output, but the actual value will be stored as appropriate integer type.

This allows to use "Address" property directly in code that relies on Get-Capstone disasselbly w/o type conversion.

The original module author was using hex-strings, because when you add things in PowerShell like this:  $Integer + '0xFF' , PowerShell will cast everything to the type of the first operand. And it's smart enough to cast hex-string to integer.

Example: https://github.com/FuzzySecurity/PowerShell-Suite/blob/master/Trace-Execution.ps1#L195

But this is unreliable and moreover, PowerShell has peculiar quirks when casting hex-strings: https://github.com/PowerShell/PowerShell/issues/3313

* Move Capstone init to separate function

* Add Get-CaptoneVersion function

Which resturns "version" object. Also add back erroneously deleted "return" to Get-CapstoneDisassembly -Version and convert it to advanced function.

* Fix help text

* Replace double quotes with single quotes where appropriate

* No need to assign $null to switch params

* Make return usage more obvious

* No need for double quotes in version banner

* Add space after comma

* ~3x speedup by removing New-Object usage. Requires PS 3.0

* Cosmetic fixes

* Remove PS 2.0 compatibility code

* Fix PSScriptAnalyzer warnings

* Don't load module if inline C# doesn't compile

* Return actual instruction bytes

* Fix version function

* Use lowercase for accelerators

* Remove "Mandatory = $False" since it's default

* Add spaces around "=" and ";"

* Use lowercase for built-in variables

* Tabs -> Spaces

* Update help

* Use standard manifest

* UTF-8, no BOM

* Remove remaining New-Object invocations

* Bump module version (semver anyone?)

* Restore PSv2 compatibility

Use [pscustomobject]/New-Object based on reported PS version.

* Tabs -> Spaces

* Update authors
2018-09-11 12:50:55 +08:00
Riccardo Schirone c3bc95b4a1 arch/X86: fix strncpy usage (#1243)
The `n` parameter should be the size of the destination buffer, not the
source one.
2018-09-04 08:51:02 +07:00
xambroz 5c168e515d introduce PYTHON2 and PYTHON3 variables in the makefiles (#1236)
This change makes it possible to be explicit during the build time
on what python version/binary use to compile.
2018-08-29 12:26:53 +08:00
Catena cyber 970df19f6e Avoids memory leak with fuzz driver (#1233) 2018-08-27 07:57:27 +07:00
Riccardo Schirone 87f21c2a90 WIP: arch/TMS320C64x: fix underflow (#1220)
* arch/TMS320C64x: fix underflow

(patch coming from radare2)

* arch/TMS320C64x: fix spaces between if/for/while and parenthesis

* arch/TMS320C64x: switch back to ==
2018-07-30 21:48:26 +08:00
Riccardo Schirone bfa649ff1a WIP: arch/TMS320C64x: fix underflow (#1220)
* arch/TMS320C64x: fix underflow

(patch coming from radare2)

* arch/TMS320C64x: fix spaces between if/for/while and parenthesis

* arch/TMS320C64x: switch back to ==
2018-07-30 15:17:43 +08:00
Nguyen Anh Quynh 755bfa5d1e evm: fix EVMMappingInsn.inc 2018-07-29 02:38:38 +08:00
Nguyen Anh Quynh dc7aafb87c evm: fix EVMMappingInsn.inc 2018-07-29 02:38:10 +08:00
Nguyen Anh Quynh 35bcee46a8 MacOS: do not build in Universal format by default 2018-07-28 00:25:18 +08:00
Nguyen Anh Quynh 8074420213 Merge branch 'master' of github.com:aquynh/capstone 2018-07-28 00:24:46 +08:00
Nguyen Anh Quynh 44bcb2fa38 MacOS: do not build in Universal format by default 2018-07-28 00:24:14 +08:00
Nguyen Anh Quynh d469f4bee9 README 2018-07-24 13:46:31 +08:00
Nguyen Anh Quynh 4f05e83334 README 2018-07-24 13:44:39 +08:00
Riccardo Schirone 6cfbd06b61 arch/M68k: do not return reg_name if beyond limits (#1219)
* arch/M68k: do not return reg_name if beyond limits

(patch coming from radare2)

* arch: checks index when returning reg names
2018-07-24 16:25:47 +08:00
Nguyen Anh Quynh 782ea67e17 sparc: fix issue #1221 on double printing imm operand 2018-07-24 14:53:00 +08:00
Riccardo Schirone 6ed076d41e arch/M68k: do not return reg_name if beyond limits (#1219)
* arch/M68k: do not return reg_name if beyond limits

(patch coming from radare2)

* arch: checks index when returning reg names
2018-07-24 13:40:02 +08:00
Riccardo Schirone 223ba56531 cstool: fix memleak to prevent ASAN from complaining (#1222) 2018-07-24 12:22:21 +08:00
Nguyen Anh Quynh 740f05b62d fix warnings on const char * discards qualifiers 2018-07-24 12:22:10 +08:00
Riccardo Schirone e8a818d9a7 cstool: fix memleak to prevent ASAN from complaining (#1222) 2018-07-24 10:19:07 +08:00
Nguyen Anh Quynh 2fc852dcbd fix warnings on const char * discards qualifiers 2018-07-24 01:41:59 +08:00
Nguyen Anh Quynh 443f82ee74 Merge branch 'v4' 2018-07-23 21:20:46 +08:00
Francesco Tamagni dd6e558a33 Fix testAndBranch sign extend to 64 bit (#1213) 2018-07-20 14:50:41 +08:00