-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support db_securityadmin #100
Conversation
Signed-off-by: Harsh Lunagariya <[email protected]>
Signed-off-by: Harsh Lunagariya <[email protected]>
Signed-off-by: Harsh Lunagariya <[email protected]>
src/bin/pg_dump/dump_babel_utils.c
Outdated
static char *default_bbf_db_principals = | ||
"('master_dbo', 'master_db_owner', 'master_guest', 'master_db_accessadmin', " | ||
"'msdb_dbo', 'msdb_db_owner', 'msdb_guest', 'msdb_db_accessadmin', " | ||
"'tempdb_dbo', 'tempdb_db_owner', 'tempdb_guest', 'tempdb_db_accessadmin') "; | ||
"('master_dbo', 'master_db_owner', 'master_guest', 'master_db_accessadmin', 'master_db_securityadmin', " | ||
"'msdb_dbo', 'msdb_db_owner', 'msdb_guest', 'msdb_db_accessadmin', 'msdb_db_securityadmin', " | ||
"'tempdb_dbo', 'tempdb_db_owner', 'tempdb_guest', 'tempdb_db_accessadmin', 'tempdb_db_securityadmin') "; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of updating this static list everytime, is it possible to get this list dynamically using some query during dump? same is applicable for default_bbf_roles
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be possible IMO, We can rely on the is_fixed_role metadata. Currently, we are not utilizing it and not even updating it for fixed roles.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets open internal jira to track this work.
@@ -1992,7 +1992,7 @@ dumpBabelPhysicalDatabaseACLs(Archive *fout) | |||
"\n SET LOCAL ROLE sysadmin;" | |||
"\n FOR rolname, original_name IN (" | |||
"\n SELECT a.rolname, a.orig_username FROM sys.babelfish_authid_user_ext a" | |||
"\n WHERE orig_username IN ('dbo','db_accessadmin') AND" | |||
"\n WHERE orig_username IN ('dbo','db_accessadmin','db_securityadmin') AND" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
redeisgn/rethink this query so that we dont need to re-write this everytime
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be backward compatible, so this will be an interesting challenge
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need @rishabhtanwar29 's opinion on this.
@@ -53,9 +53,15 @@ typedef enum { | |||
static babelfish_status bbf_status = NONE; | |||
|
|||
static char *default_bbf_db_principals = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isnt this list the same as default_bbf_roles defined in other file?
f5618f3
to
46ac851
Compare
Description This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved BABEL-5135 Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
Description Handle babelfish dump restore changes for fixed database role db_securityadmin Extension PR : amazon-aurora/babelfish_extensions#70 Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
Description Handle babelfish dump restore changes for fixed database role db_securityadmin Extension PR : amazon-aurora/babelfish_extensions#70 Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
Description Handle babelfish dump restore changes for fixed database role db_securityadmin Extension PR : amazon-aurora/babelfish_extensions#70 Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
This commit adds support for db_securityadmin fixed database roles. Members of db_securityadmin can perform following operations within a particular database: create schema create database roles alter/drop user-defined database roles manage permissions via grant/revoke statements Engine Changes - amazon-aurora/postgresql_modified_for_babelfish#100 Issues Resolved [BABEL-5135] Signed-off-by: Harsh Lunagariya <[email protected]>
Description Handle babelfish dump restore changes for fixed database role db_securityadmin Extension PR : amazon-aurora/babelfish_extensions#70 Signed-off-by: Harsh Lunagariya <[email protected]>
Description
Extension PR : amazon-aurora/babelfish_extensions#70
Issues Resolved
BABEL-5135
Check List
By submitting this pull request, I confirm that my contribution is under the terms of the Apache 2.0 and PostgreSQL licenses, and grant any person obtaining a copy of the contribution permission to relicense all or a portion of my contribution to the PostgreSQL License solely to contribute all or a portion of my contribution to the PostgreSQL open source project.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.