grant all table engines in allow_database

This commit is contained in:
jsc0218 2024-04-18 02:00:28 +00:00
parent 80fa1ab89a
commit 6e5afb8b89
3 changed files with 1 additions and 2 deletions

View File

@ -371,6 +371,7 @@ namespace
if (databases)
{
user->access.revoke(AccessFlags::allFlags() - AccessFlags::allGlobalFlags());
user->access.grantWithGrantOption(AccessType::TABLE_ENGINE);
user->access.grantWithGrantOption(AccessFlags::allDictionaryFlags(), IDictionary::NO_DATABASE_TAG);
for (const String & database : *databases)
user->access.grantWithGrantOption(AccessFlags::allFlags(), database);

View File

@ -4,7 +4,6 @@
<allow_databases>
<database>default</database>
<database>test</database>
<database>Log</database>
</allow_databases>
</default>
</users>

View File

@ -10,7 +10,6 @@
<allow_databases>
<database>db1</database>
<database>Memory</database>
</allow_databases>
</restricted_user>
</users>