fluidattacks / makes

A software supply chain framework powered by Nix.
https://makes.fluidattacks.tech/
MIT License
428 stars 42 forks source link

[APK scan] An error occurred while analyzing your targets #1236

Closed Stoisss closed 8 months ago

Stoisss commented 8 months ago

An error occurred while analyzing your targets.

nix-env: 2.19.2 OS: Mac 🦄 Makes v24.01-darwin

The command docker run --memory=12g -v .:/working-dir ghcr.io/fluidattacks/makes/arm64 m gitlab:fluidattacks/universe@trunk /skims scan ./casa_config.yaml which after around 20 minutes leads to

2024-01-08 06:42:37.025 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.103 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.176 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.197 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.208 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.212 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.214 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.218 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.221 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
2024-01-08 06:42:37.234 | ERROR    | androguard.decompiler.graph:construct:527 - Multiple exit nodes found !
[INFO] APK analysis completed                                                   
[INFO] Running SAST analysis on specified paths
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
....
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[ERROR] Exception: BrokenProcessPool, A process in the process pool was terminated abruptly while the future was running or pending., {}
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter-libraries__ms-connect__ms-connect-server__src__main__java__com__mobisystems__connect__server__admin__payments__ProductsAndPremiums_java*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter-common__src__main__java__com__mobisystems__monetization__crosspromo__CrossPromo_java*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter-libfilemng__build__intermediates__data_binding_dependency_artifacts__gplayRelease__androidx_databinding_library_baseAdapters-setter_store_json*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter*18557
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter-officecommon__build__intermediates__data_binding_dependency_artifacts__gplayRelease__com_mobisystems_office_poiCommon-setter_store_json*
[INFO] An output will be generated at /home/root/.skims/debug/tree-sitter*
[INFO] SAST/Graph: ...setter_store.json:   0%|                         | 3/5259
[WARNING] Function: __main__.cli_scan_wrapped, type in : A child process terminated abruptly, the process pool is not usable anymore
Traceback (most recent call last):
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/utils/function.py", line 180, in wrapper
    return function(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/cli/__init__.py", line 259, in cli_scan_wrapped
    success: tuple[bool, int] = run(core.scan.main())
                                ^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/m2lp6djimilzx8al7338llyqwgyh3sid-skims-runtime/lib/python3.11/site-packages/aioextensions/__init__.py", line 292, in run
    return asyncio.run(coroutine, debug=debug)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/v4ln57kzvq6c3q2041xmgig8vyh5nm20-python3-3.11.6/lib/python3.11/asyncio/runners.py", line 190, in run
    return runner.run(main)
           ^^^^^^^^^^^^^^^^
  File "/nix/store/v4ln57kzvq6c3q2041xmgig8vyh5nm20-python3-3.11.6/lib/python3.11/asyncio/runners.py", line 118, in run
    return self._loop.run_until_complete(task)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/v4ln57kzvq6c3q2041xmgig8vyh5nm20-python3-3.11.6/lib/python3.11/asyncio/base_events.py", line 653, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/core/scan.py", line 441, in main
    stores = await execute_skims()
             ^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/utils/telemetry.py", line 38, in async_wrapper
    result = await _func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/core/scan.py", line 202, in execute_skims
    analyze_sast(stores=vuln_stores)
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/utils/telemetry.py", line 45, in wrapper
    result = _func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/lib/sast/analyze.py", line 34, in analyze
    analyze_lib_root(paths=paths.ok_paths, stores=stores)
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/utils/telemetry.py", line 45, in wrapper
    result = _func(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/lib/root/analyze.py", line 153, in analyze
    futures = get_futures(
              ^^^^^^^^^^^^
  File "/nix/store/nm4c4rd3h39cj4ib6vv2cw13m91w4zgx-skims/lib/root/analyze.py", line 192, in get_futures
    future = worker.submit(
             ^^^^^^^^^^^^^^
  File "/nix/store/v4ln57kzvq6c3q2041xmgig8vyh5nm20-python3-3.11.6/lib/python3.11/concurrent/futures/process.py", line 791, in submit
    raise BrokenProcessPool(self._broken)
concurrent.futures.process.BrokenProcessPool: A child process terminated abruptly, the process pool is not usable anymore

[INFO] Summary: An error occurred while analyzing your targets.

casa_config.yaml:

namespace: PDFExtra
output:
  file_path: ./Fluid-Attacks-Results.csv
  format: CSV
working_dir: .
  #/AndroidStudio
language: EN
debug: true
strict: false
file_size_limit: false
sast:
  include:
    - .
sca:
  include:
    - .
apk:
  include:
    - glob(./PdfExtra/**/*.apk)
ndreisg commented 7 months ago

Hi. Why is this closed? I have a similar issue. How do I fix it?

[WARNING] Function __main__.cli_scan_wrapped failed analyzing  with error type: A child process terminated abruptly, the process pool is not usable anymore
[INFO] Summary: An error occurred while analyzing your targets.