Skip to content

Added New Rule to Fix Security Orchestration Policy

What does this MR do and why?

This MR adds a new rule in the security orchestration policy to validate the range of vulnerabilities_allowed when people define a policy, this is done because when a policy defines vulnerabilities_allowed larger than a value of smallint, we error on policy sync with out of range for ActiveModel::Type::Integer with limit 2 bytes. Had to refactor the code because RuboCop was giving warnings on cyclomatic complexity

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Related to #443290 (closed)

Merge request reports

Loading