Skip to content

Commit

Permalink
chore: implement method to validate suspicious packages for malicious…
Browse files Browse the repository at this point in the history
… behavior
  • Loading branch information
Yao-Wen-Chang committed Dec 19, 2024
1 parent 1ea1bd5 commit a494c61
Show file tree
Hide file tree
Showing 7 changed files with 730 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/macaron/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ def analyze_slsa_levels_single(analyzer_single_args: argparse.Namespace) -> None
analyzer_single_args.sbom_path,
deps_depth,
provenance_payload=prov_payload,
validate_malware_switch=analyzer_single_args.validate_malware_switch,
)
sys.exit(status_code)

Expand Down Expand Up @@ -483,6 +484,13 @@ def main(argv: list[str] | None = None) -> None:
"The path to the local .m2 directory. If this option is not used, Macaron will use the default location at $HOME/.m2"
),
)

single_analyze_parser.add_argument(
"--validate-malware-switch",
required=False,
action="store_true",
help=("Enable malware validation."),
)

# Dump the default values.
sub_parser.add_parser(name="dump-defaults", description="Dumps the defaults.ini file to the output directory.")
Expand Down
Loading

0 comments on commit a494c61

Please sign in to comment.