SqlGrantSpecificPrivsWarn

This check warns a user when SQL contains GRANT statements that grant specific privileges to a user or role, so that they can ensure that the specific privilege being granted won't lead to security issues or violate compliance regulations.

Uses

Use the check to warn when changelogs contain Grants with specific privileges statements. Unintended or unauthorized GRANTS of specific privileges can lead to security and compliance issues, especially in regulated industries. This quality check alerts users so they can exercise more control over privileges and permission changes, which is especially important in automated data pipelines, before these changes are deployed to your quality checked environments. This quality check, like other checks, can be configured with a severity level which returns an exit code designed to stop automated jobs, giving your team time to inspect these changes.

Run the SqlGrantSpecificPrivsWarn check

To run the SqlGrantSpecificPrivsWarn check, ensure you have a Liquibase Pro license and the checks-scope property includes changelog. The checks-scope parameter is set in the default properties file, environment variable, or any standard method. Then, check the changelog to see if SqlGrantSpecificPrivsWarn is enabled.

Note: Please be aware that SqlGrantSpecificPrivsWarn only supports unmodeled changeset types. If you use this Quality Check with modeled changesets (XML, JSON, and YAML changelogs as well as all ChangeTypes except sql and sqlFile), a message will appear stating the changeset was skipped.

Enable the SqlGrantSpecificPrivsWarn check by running the following command in the CLI:

liquibase checks enable --check-name=SqlGrantSpecificPrivsWarn
Short Name Scope Enabled Severity Customization Description
SQLGrantAdminWarn changelog

false

Default value: 0

  • 'INFO' | 0
  • 'MINOR' | 1
  • 'MAJOR' | 2
  • 'CRITICAL' | 3
  • 'BLOCKER' | 4

PRIVILEGE_LIST = null

This check warns a user when a changeset includes or generates sql that grants specific privileges to a user or role.