mirror of
https://github.com/crytic/slither.git
synced 2026-10-12 10:59:58 +00:00
15 lines
484 B
Python
15 lines
484 B
Python
import inspect
|
|
from slither import Slither
|
|
from slither.detectors import all_detectors
|
|
from slither.detectors.abstract_detector import AbstractDetector
|
|
|
|
|
|
def _run_all_detectors(slither: Slither) -> None:
|
|
detectors = [getattr(all_detectors, name) for name in dir(all_detectors)]
|
|
detectors = [d for d in detectors if inspect.isclass(d) and issubclass(d, AbstractDetector)]
|
|
|
|
for detector in detectors:
|
|
slither.register_detector(detector)
|
|
|
|
slither.run_detectors()
|