Commit Graph

5905 Commits

Author SHA1 Message Date
Moritz
3de84eff1b Merge pull request #2813 from doomedraven/patch-1
Add '2.5-CAPE' to tested versions
2026-01-16 20:28:39 +01:00
doomedraven
7e16ed741c Add '2.5-CAPE' to tested versions
hello, we just released CAPE v2.5, there are no behavior/structural changes. Is focused on webgui improvements, and some other improvements that doesnt impact CAPA.
2026-01-16 14:58:48 +00:00
Mike Hunhoff
5a5545aa14 ghidra: fix unit tests (#2812)
* ghidra: fix unit tests

* fix formatting
2026-01-15 12:34:43 -07:00
Moritz
6ad4fbbb9b Merge pull request #2742 from mandiant/idalib-tests 2026-01-13 21:48:30 +01:00
dependabot[bot]
8105214dc6 build(deps-dev): bump build from 1.3.0 to 1.4.0 (#2809)
Bumps [build](https://github.com/pypa/build) from 1.3.0 to 1.4.0.
- [Release notes](https://github.com/pypa/build/releases)
- [Changelog](https://github.com/pypa/build/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pypa/build/compare/1.3.0...1.4.0)

---
updated-dependencies:
- dependency-name: build
  dependency-version: 1.4.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-13 09:08:58 -07:00
Willi Ballenthin
d1fc8446f6 pyproject: ida: silence SWIG related warnings from IDA bindings 2026-01-13 16:15:31 +01:00
Willi Ballenthin
0686305f43 ida: loader: load resource sections to help discovery of embedded files 2026-01-13 16:15:31 +01:00
Willi Ballenthin
8d6b878e79 ida: fix return value from open_database 2026-01-13 16:15:31 +01:00
Willi Ballenthin
3646fcefa2 ida: helpers: refactor discovery of alternative names 2026-01-13 16:15:31 +01:00
Willi Ballenthin
ce67d99e49 ida: skip function-name features for default names (sub_*) 2026-01-13 16:15:31 +01:00
Willi Ballenthin
c89871f257 ci: pin setup-uv 2026-01-13 16:15:31 +01:00
Willi Ballenthin
03cc901f7b tests: idalib: xfail resource test on 9.0 2026-01-13 16:15:31 +01:00
Willi Ballenthin
412ab62c42 ida: pep8 2026-01-13 16:15:31 +01:00
Willi Ballenthin
f72bd49a5f ci: enable testing of IDA 9.0 2026-01-13 16:15:31 +01:00
Willi Ballenthin
1d561bd038 tests: idalib: xfail two tests on 9.0 and 9.1 2026-01-13 16:15:31 +01:00
Willi Ballenthin
c5808c4c41 tests: idalib: use 9.1 instead of 9.0 as min ver
9.0 doesn't support disabling lumina (or loading resources, for that
matter, too)
2026-01-13 16:15:31 +01:00
Willi Ballenthin
200c8037dd tests: fix logging message 2026-01-13 16:15:31 +01:00
mr-tz
4fb6ac0d1b add ida version to test matrix name 2026-01-13 16:15:31 +01:00
mr-tz
87fb96d08b load resource for test sample 2026-01-13 16:15:31 +01:00
Willi Ballenthin
e1fd184805 ida: function: extract function name
somehow we were extracting alternate names but not function names
2026-01-13 16:15:31 +01:00
Willi Ballenthin
82be20be64 loader: idalib: disable lumina
see #2742 in which Lumina names overwrote names provided by debug info
2026-01-13 16:15:31 +01:00
Willi Ballenthin
132e64a991 tests: idalib: better detect missing idapro package 2026-01-13 16:15:31 +01:00
Willi Ballenthin
9c6db00775 ci: add configuration for idalib tests 2026-01-13 16:15:31 +01:00
Moritz
7bdd1f11bb Merge branch 'master' into idalib-tests 2026-01-13 16:15:31 +01:00
kamran ul haq
7f3e35ee62 loader: gracefully handle ELF files with unsupported architectures (#2800)
* loader: gracefully handle ELF files with unsupported architectures

When analyzing ELF files with unsupported architectures (e.g., ARM64 variant),
vivisect raises a generic Exception with message 'Unsupported Architecture: %d'.
This was not caught by existing error handlers, causing capa to crash with an
unfriendly error message.

This change adds exception handling to detect the 'Unsupported Architecture'
error message and convert it to a user-friendly CorruptFile exception,
following the same pattern as the existing 'Couldn't convert rva' handler.

The architecture number is extracted from the exception args and included
in the error message to help users understand what went wrong.

closes #2793

* loader: address review feedback for PR #2800

- Add e.args check to prevent IndexError when accessing exception arguments
- Use error_msg variable instead of directly accessing e.args[0]
- Update CHANGELOG to reference PR #2800 instead of issue #2793

Addresses feedback from @mike-hunhoff and gemini-code-assist bot

* chore: move unsupported architecture bug fix to master (unreleased) section
2026-01-09 16:20:43 -07:00
Capa Bot
80c085b08b Sync capa rules submodule 2026-01-06 17:02:03 +00:00
Capa Bot
bfd1b09176 Sync capa-testfiles submodule 2026-01-06 16:50:00 +00:00
dependabot[bot]
dc47de1439 build(deps): bump ruamel-yaml from 0.18.6 to 0.19.1 (#2803)
Bumps ruamel-yaml from 0.18.6 to 0.19.1.

---
updated-dependencies:
- dependency-name: ruamel-yaml
  dependency-version: 0.19.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 10:08:43 -07:00
dependabot[bot]
2f7db1f446 build(deps-dev): bump flake8-simplify from 0.22.0 to 0.30.0 (#2804)
Bumps [flake8-simplify](https://github.com/MartinThoma/flake8-simplify) from 0.22.0 to 0.30.0.
- [Release notes](https://github.com/MartinThoma/flake8-simplify/releases)
- [Changelog](https://github.com/MartinThoma/flake8-simplify/blob/main/CHANGELOG.md)
- [Commits](https://github.com/MartinThoma/flake8-simplify/commits)

---
updated-dependencies:
- dependency-name: flake8-simplify
  dependency-version: 0.30.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 10:08:35 -07:00
dependabot[bot]
0908343ca1 build(deps): bump intervaltree from 3.1.0 to 3.2.1 (#2805)
Bumps [intervaltree](https://github.com/chaimleib/intervaltree) from 3.1.0 to 3.2.1.
- [Release notes](https://github.com/chaimleib/intervaltree/releases)
- [Changelog](https://github.com/chaimleib/intervaltree/blob/master/CHANGELOG.md)
- [Commits](https://github.com/chaimleib/intervaltree/compare/3.1.0...3.2.1)

---
updated-dependencies:
- dependency-name: intervaltree
  dependency-version: 3.2.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 10:07:36 -07:00
dependabot[bot]
342cb9d15a build(deps-dev): bump psutil from 7.1.2 to 7.2.1 (#2806)
Bumps [psutil](https://github.com/giampaolo/psutil) from 7.1.2 to 7.2.1.
- [Changelog](https://github.com/giampaolo/psutil/blob/master/HISTORY.rst)
- [Commits](https://github.com/giampaolo/psutil/compare/release-7.1.2...release-7.2.1)

---
updated-dependencies:
- dependency-name: psutil
  dependency-version: 7.2.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-01-05 10:07:17 -07:00
Capa Bot
9aad2591c4 Sync capa rules submodule 2025-12-29 17:21:22 +00:00
dependabot[bot]
1153ca4cf7 build(deps-dev): bump types-psutil from 7.1.3.20251202 to 7.2.0.20251228 (#2801)
Bumps [types-psutil](https://github.com/typeshed-internal/stub_uploader) from 7.1.3.20251202 to 7.2.0.20251228.
- [Commits](https://github.com/typeshed-internal/stub_uploader/commits)

---
updated-dependencies:
- dependency-name: types-psutil
  dependency-version: 7.2.0.20251228
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-29 09:48:14 -07:00
dependabot[bot]
4500dd80b3 build(deps-dev): bump pygithub from 2.6.0 to 2.8.1 (#2798)
Bumps [pygithub](https://github.com/pygithub/pygithub) from 2.6.0 to 2.8.1.
- [Release notes](https://github.com/pygithub/pygithub/releases)
- [Changelog](https://github.com/PyGithub/PyGithub/blob/main/doc/changes.rst)
- [Commits](https://github.com/pygithub/pygithub/compare/v2.6.0...v2.8.1)

---
updated-dependencies:
- dependency-name: pygithub
  dependency-version: 2.8.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-29 09:46:44 -07:00
dependabot[bot]
a35379d32b build(deps): bump humanize from 4.14.0 to 4.15.0 (#2797)
Bumps [humanize](https://github.com/python-humanize/humanize) from 4.14.0 to 4.15.0.
- [Release notes](https://github.com/python-humanize/humanize/releases)
- [Commits](https://github.com/python-humanize/humanize/compare/4.14.0...4.15.0)

---
updated-dependencies:
- dependency-name: humanize
  dependency-version: 4.15.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-29 09:44:53 -07:00
dependabot[bot]
29a8fa263e build(deps-dev): bump mypy-protobuf from 3.6.0 to 4.0.0 (#2796)
Bumps [mypy-protobuf](https://github.com/nipunn1313/mypy-protobuf) from 3.6.0 to 4.0.0.
- [Changelog](https://github.com/nipunn1313/mypy-protobuf/blob/main/CHANGELOG.md)
- [Commits](https://github.com/nipunn1313/mypy-protobuf/compare/v3.6.0...v4.0.0)

---
updated-dependencies:
- dependency-name: mypy-protobuf
  dependency-version: 4.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-29 09:44:12 -07:00
dependabot[bot]
5dcf98b1af build(deps-dev): bump pytest from 8.0.0 to 9.0.2 (#2795)
Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.0.0 to 9.0.2.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/8.0.0...9.0.2)

---
updated-dependencies:
- dependency-name: pytest
  dependency-version: 9.0.2
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-29 09:43:11 -07:00
dependabot[bot]
0ad45bfdcc build(deps-dev): bump mypy from 1.17.1 to 1.19.1 (#2789)
Bumps [mypy](https://github.com/python/mypy) from 1.17.1 to 1.19.1.
- [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md)
- [Commits](https://github.com/python/mypy/compare/v1.17.1...v1.19.1)

---
updated-dependencies:
- dependency-name: mypy
  dependency-version: 1.19.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mike Hunhoff <mike.hunhoff@gmail.com>
2025-12-19 10:29:59 -07:00
dependabot[bot]
acad501b07 build(deps-dev): bump pyinstaller from 6.16.0 to 6.17.0 (#2790)
Bumps [pyinstaller](https://github.com/pyinstaller/pyinstaller) from 6.16.0 to 6.17.0.
- [Release notes](https://github.com/pyinstaller/pyinstaller/releases)
- [Changelog](https://github.com/pyinstaller/pyinstaller/blob/develop/doc/CHANGES.rst)
- [Commits](https://github.com/pyinstaller/pyinstaller/compare/v6.16.0...v6.17.0)

---
updated-dependencies:
- dependency-name: pyinstaller
  dependency-version: 6.17.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mike Hunhoff <mike.hunhoff@gmail.com>
2025-12-19 09:37:59 -07:00
dependabot[bot]
6da6035e7e build(deps-dev): bump isort from 6.0.0 to 7.0.0 (#2791)
Bumps [isort](https://github.com/PyCQA/isort) from 6.0.0 to 7.0.0.
- [Release notes](https://github.com/PyCQA/isort/releases)
- [Changelog](https://github.com/PyCQA/isort/blob/main/CHANGELOG.md)
- [Commits](https://github.com/PyCQA/isort/compare/6.0.0...7.0.0)

---
updated-dependencies:
- dependency-name: isort
  dependency-version: 7.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mike Hunhoff <mike.hunhoff@gmail.com>
2025-12-19 09:36:51 -07:00
Mike Hunhoff
66dc70a775 ghidra: support PyGhidra (#2788)
* ghidra: init commit switch to PyGhidra

* update CHANGELOG and PyGhidra version requirements

* Update capa/features/extractors/ghidra/helpers.py

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* fix black errors

* support Ghidra v12

* remove deprecated APIs

* refactor outdated code

* fix pyinstaller, code refactoring

* address PR feedback

* add back capa_explorer.py

* beef up capa_explorer.py script

* refactor README

* refactor README

* fix #2747

* add sha256 check for workflows

* add sha256 check for workflows

* add sha256 check for workflows

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2025-12-18 17:55:49 -07:00
Moritz
50300f1c8e Merge pull request #2792 from mandiant/dependabot/pip/deptry-0.24.0 2025-12-16 21:08:55 +01:00
dependabot[bot]
03f94536ca build(deps-dev): bump deptry from 0.23.0 to 0.24.0
Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.23.0 to 0.24.0.
- [Release notes](https://github.com/fpgmaas/deptry/releases)
- [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md)
- [Commits](https://github.com/fpgmaas/deptry/compare/0.23.0...0.24.0)

---
updated-dependencies:
- dependency-name: deptry
  dependency-version: 0.24.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-15 14:02:35 +00:00
mr-tz
dc08843e2d address idalib-based test fails 2025-12-11 14:18:13 +00:00
Moritz
40b01f0998 Merge pull request #2787 from mandiant/dependabot/pip/msgspec-0.20.0
build(deps): bump msgspec from 0.19.0 to 0.20.0
2025-12-11 11:17:57 +01:00
Moritz
b96a3b6b23 Merge pull request #2786 from mandiant/dependabot/pip/black-25.12.0
build(deps-dev): bump black from 25.11.0 to 25.12.0
2025-12-11 11:17:33 +01:00
Moritz
43e5e60901 Merge pull request #2785 from mandiant/dependabot/pip/types-psutil-7.1.3.20251202
build(deps-dev): bump types-psutil from 7.0.0.20250218 to 7.1.3.20251202
2025-12-11 11:17:14 +01:00
Moritz
0f9f72dbd5 build(deps-dev): bump flake8-bugbear from 25.10.21 to 25.11.29 (#2784)
Bumps [flake8-bugbear](https://github.com/PyCQA/flake8-bugbear) from 25.10.21 to 25.11.29.
- [Release notes](https://github.com/PyCQA/flake8-bugbear/releases)
- [Commits](https://github.com/PyCQA/flake8-bugbear/compare/25.10.21...25.11.29)

---
updated-dependencies:
- dependency-name: flake8-bugbear
  dependency-version: 25.11.29
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-12-11 11:16:51 +01:00
dependabot[bot]
fd9f584cc4 build(deps): bump msgspec from 0.19.0 to 0.20.0
Bumps [msgspec](https://github.com/jcrist/msgspec) from 0.19.0 to 0.20.0.
- [Release notes](https://github.com/jcrist/msgspec/releases)
- [Changelog](https://github.com/jcrist/msgspec/blob/main/docs/changelog.md)
- [Commits](https://github.com/jcrist/msgspec/compare/0.19.0...0.20.0)

---
updated-dependencies:
- dependency-name: msgspec
  dependency-version: 0.20.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-08 14:02:34 +00:00
dependabot[bot]
c3b785e217 build(deps-dev): bump black from 25.11.0 to 25.12.0
Bumps [black](https://github.com/psf/black) from 25.11.0 to 25.12.0.
- [Release notes](https://github.com/psf/black/releases)
- [Changelog](https://github.com/psf/black/blob/main/CHANGES.md)
- [Commits](https://github.com/psf/black/compare/25.11.0...25.12.0)

---
updated-dependencies:
- dependency-name: black
  dependency-version: 25.12.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-08 14:02:27 +00:00