Skip to main content

validate_role

Function validate_role 

Source
pub fn validate_role(role: &str) -> Result<()>
Expand description

PostgreSQL cannot bind an identifier as a parameter, so the role name is interpolated into the GRANT script. This allowlist is what keeps that safe: a bare lowercase identifier needs no quoting and cannot carry a statement separator, a quote, or a comment.