mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-16 19:32:07 +00:00
19 lines
546 B
C++
19 lines
546 B
C++
#pragma once
|
|
|
|
#include <Parsers/IAST_fwd.h>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
|
|
/// Checks the type of a specified AST and returns true if it can contain a password.
|
|
bool canContainPassword(const IAST & ast);
|
|
|
|
/// Removes a password or its hash from a query if it's specified there or replaces it with some placeholder.
|
|
/// This function is used to prepare a query for storing in logs (we don't want logs to contain sensitive information).
|
|
/// The function changes only following types of queries:
|
|
/// CREATE/ALTER USER.
|
|
void wipePasswordFromQuery(ASTPtr ast);
|
|
|
|
}
|