SqlGrantWarn

This check warns a user when a SQL contains 'GRANT' statements so that they can ensure that the privilege being granted won't lead to security issues.

Uses

Use the check to warn when changelogs contain WITH GRANT statements. Unintended or unauthorized GRANTS 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.

Run the SQLGrantWarn check

The sqlGrantWarn check is enabled by default, so you will not need to turn it on if you have not changed your settings previously. To run the sqlGrantWarn 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 SQLGrantWarn is enabled.

Note: Please be aware that sqlGrantWarn 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 SQLGrantWarn check by running the following command in the CLI:

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

true

Default value: 1

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

<None>

This check warns a user when a SQL contains 'GRANT' statements so that they can ensure that the privilege being granted won't lead to security issues.