Questions tagged [role]

A set of permissions.

Filter by
Sorted by
Tagged with
0 votes
1 answer
27 views

How to grant read-write access to a user within the whole database cluster?

I got a database cluster with 1300 databases. I created a role and a user and granted access using the command GRANT SELECT, INSERT, UPDATE, DELETE ON ALL TABLES IN SCHEMA public TO myuser, so myuser ...
user avatar
  • 1
2 votes
1 answer
35 views

Error trying to add a login to Azure SQL Special Role 'dbmanager'

Upon running these commands on an Azure SQL instance: CREATE LOGIN test WITH PASSWORD=N'Passw0rd' GO ALTER ROLE dbmanager ADD MEMBER test GO ... I'm getting an error: Cannot add the server principal ...
user avatar
  • 429
0 votes
1 answer
55 views

Is rdstopmgr an AWS RDS user?

I am running postgres on AWS RDS. RDS creates some users on its own, such as rdsadmin and rdsrepladmin. I am familiar with these However, I also see rdstopmgr, when I query postgres for roles. Google ...
user avatar
0 votes
0 answers
20 views

Unable to drop a user in AWS Redshift

I want to drop user foo from an AWS Redshift db DROP USER foo; ERROR: user "foo" cannot be dropped because some objects depend on it DETAIL: 1 object in database bar 1 object in database ...
user avatar
  • 171
1 vote
0 answers
56 views

Default roles ticked when creating new login through SSMS GUI

When creating a new login via the GUI: In the User Mapping section, certain databases will have some roles pre-ticked in the Database Role Membership section. What controls this behavior? It's ...
user avatar
1 vote
2 answers
50 views

unable to drop user in PostgreSQL 12.4

I am unable to drop user as I am getting default privileges error. postgres=# drop user xyz; ERROR: role "xyz" cannot be dropped because some objects depend on it DETAIL: owner of default ...
user avatar
4 votes
1 answer
196 views

How to revoke SA permissions that seem to be "stuck" to a login?

Apologies in advance if I don't use some terminology correctly here. I'm not a DBA but I've been temporarily forced into the role. I've inherited an application that runs on SQL Server 2016 ...
user avatar
0 votes
1 answer
64 views

Proper roles for a backup-only user on PostgreSQL

I am working on new processes and policies for my PostgreSQL databases when they are first created, and I am trying to define what role attributes are necessary for a role specifically used for ...
user avatar
  • 37
0 votes
1 answer
211 views

Create readonly user in postgresql

Using pg 13.4, created a readonly user reader for database abc, via: CREATE ROLE reader WITH LOGIN PASSWORD 'psssswwwd' NOSUPERUSER INHERIT NOCREATEDB NOCREATEROLE NOREPLICATION VALID UNTIL 'infinity'...
user avatar
  • 179
-1 votes
1 answer
62 views

What is the benefit of application roles instead of SQL Server authentication in SQL Server?

I have a database that is used by an application. This application implements all the business logic and control what a user can do according at its privileges. I want to avoid users can access to ...
user avatar
0 votes
0 answers
11 views

Create role with Grants and a its opposite function to drop role, logic correct?

I want to create a function where I do the following: CREATE ROLE old_role GRANT masteruser TO old_role FOREACH DATABASE GRANT CONNECT ON DATABASE the_db to old_role ; FOREACH SCHEMA ...
user avatar
0 votes
1 answer
31 views

ALTER permission on database allows creation of security principals

It appears the ALTER permission granted at the database level allows the principal to which it is granted, to create security principals in the database. Consider the below example: /* setup database *...
user avatar
  • 1,349
0 votes
1 answer
183 views

SQL Server User permissions-Hide all tables and give/show access to some views

I am using SQL Server 2019. I have gone through some questions here and not found an answer. I am trying to not to show some tables (with a certain Schema e.g. Structure) for a SPECIFIC user in the ...
user avatar
0 votes
0 answers
14 views

Roles owner : why not own by database itself?

I create a database role under specific database. Would like to ask Why role owner owned by user, why not own by the database itself? Second, dbo, for my understanding is the schema, why my database ...
user avatar
  • 3
0 votes
0 answers
44 views

Creating sql server custom database role that only allows reading some columns and nothing else

I want to create an sql server Custom Database Role which only allows reading some columns of some tables, and nothing else. this is my attempt. CREATE ROLE CustomDatabaseRole01 GO GRANT ...
user avatar
  • 1
0 votes
1 answer
94 views

How do I give my non-Azure app access to Azure SQL Server without whitelisting an ip address?

I have an app that is deployed to Vercel. It is registered in Azure AD and uses AAD for authentication. I added my personal ip to the whitelist, and when I run it locally, everything works as it ...
user avatar
0 votes
1 answer
32 views

Dropping everything in a database owned by a certain role -- not working

I want to delete everything in a certain database owned by a certain role. I've tried to do and nothing has been deleted. sudo -u postgres psql postgres=# \l List ...
user avatar
1 vote
1 answer
137 views

Give a user access to restore a database that they are owner on without the server role dbcreator

A outside vendor has a SQL user with db_owner rights on two databases, live and training. From time to time they would like to be able to backup live and restore on top of training. The easiest ...
user avatar
  • 13
1 vote
0 answers
23 views

"Friendly" role name since Azure PostgreSQL connection via AD security group role requires the AD group name as the username@pgservername?

With PostgreSQL's use of the rolename@pgservername and AD auth requiring the security group name as the role name, any user connecting via AD must know their AD security group name. I'd like to user ...
user avatar
0 votes
1 answer
1k views

How to add a login to the dbcreator role?

Using SSMS, I'm having trouble adding a new login to the server dbcreator role on my Azure SQL instance. Here's the syntax I'm using: CREATE LOGIN test WITH PASSWORD = 'SuperSecret!' ALTER SERVER ROLE ...
user avatar
  • 429
1 vote
1 answer
282 views

row level security using roles in SQL Server

I would like to implement row level security on all of my tables. Each table has a column named data_classification that has a list of values. Ideally I would like to create database roles which are ...
user avatar
1 vote
0 answers
605 views

Create multi-user database schema with roles, permissions, and services

I am in the process of designing a user administration database and I am stuck in the creation of the tables and their relationships, in order to explain myself below I expose the requirements of the ...
user avatar
1 vote
0 answers
25 views

Azure SQL custom backup role

We are currently running an Elastic Pool within azure to host all our databases. We need to back up these to on-premise as well in case of an emergency, and for it we are trying to use sqlpackage. Now ...
user avatar
1 vote
0 answers
40 views

Create a specific role in a replicated AZURE SQL database, which is in read mode

Can you give me some help with my Azure Sql, I am having a difficulty with assigning a new role to a database with "geo-redundancy". My current structure is: BD1 in zone_A replicated to ...
user avatar
  • 11
0 votes
2 answers
147 views

ALTER ROLE on replica

I have a primary server, with a secondary replicating it. I want to change a role from LOGIN to NOLOGIN. I can do this easily on the primary, but the change doesn't replicate to the secondary, and I ...
user avatar
0 votes
1 answer
401 views

Drop role postgresql

I just inherited an AWS RDS PostgreSQL 12.5 instance (so, no superuser access) and I'm required to do some cleanup and delete a bunch of groups/roles/users. I'm executing the following commands with ...
user avatar
0 votes
1 answer
507 views

Can't create schema for a db with PostgreSQL

Use psql -U postgres to login. postgres=> CREATE DATABASE mydb; postgres=> \c mydb; You are now connected to database "mydb" as user "postgres". When create schema, got ...
user avatar
  • 157
1 vote
2 answers
79 views

Create a view in a user database that can access selected system database tables

Using the principle of least privilege, what access should I give to a Role "Checklist_role" that has read permission to a view "MaintenanceJobs_view" in a user database "...
user avatar
0 votes
1 answer
367 views

Postgres 13 - Grant to Active Directory Groups?

Is it possible to grant an AD group in PG 13 without sorting to creating the group in the database? Similar to how AD groups can be granted directly in SQL Server. The PG server is on a Windows server ...
user avatar
  • 301
0 votes
0 answers
44 views

Create non-sysdba user that can grant tablespace to other users

I am creating an Oracle role with Admin option Grants so that user with this role assigned, will not be a full sysdba but will be able to create other users and grant them permissions. What I ...
user avatar
  • 177
2 votes
1 answer
448 views

Adding AD Security group to a SQL linked server

I have a question about adding permissions for a user group on a linked server in SQL Server. I am not a security specialist, so I appeal to everyone. Here is the topo: I have private software that I'...
user avatar
0 votes
2 answers
320 views

Possible to disable THE postgres role?

Postgresql 9.6, if it matters. We have an audit finding which says that the "postgres" role must not be used at all. After creating a new SUPERUSER role, is it possible to disable role "...
user avatar
  • 475
0 votes
2 answers
1k views

Can I GRANT SELECT on all schemas in a database?

I need to create role users of which can only read (select) data. I can do it for a particular schema. But I need it to work with all existing and future schemas (existing at least). How can I do it? ...
user avatar
  • 115
1 vote
0 answers
186 views

Cannot use the special principal 'dbo' when addressing SQLMI risk VA2108

We've just set up a new SQL Managed Instance on Azure, and have restored a database to it for testing. After running an initial Azure Vulnerability Assessment, the results include this: VA2108 - ...
user avatar
  • 778
0 votes
1 answer
152 views

Postgres view role permissions

I am trying to work out how database roles work. Here is my user case... create role user1 login password 'user1'; create schema authorization user1; CREATE ROLE DEV_ROLE; grant connect, temporary ...
user avatar
  • 5
0 votes
1 answer
98 views

User cannot select from table when having SELECT permissions if CONTROL is denied

I'm setting up my database on an Azure SQL Server instance. (I know the principal names are terrible, it's just a dry run test) I created a login ("Test"), a user ("Test"), a ...
user avatar
-1 votes
1 answer
31 views

Allow users to restore prior days DB to view [closed]

Our application backs up DB at end of day to save End Of Day picture. We need to allow users ( Windows domain users) to restore these prior days backups using our app. This needs to done through a ...
user avatar
  • 1
2 votes
1 answer
85 views

Should roles without login have the connect permission on a database?

I want to create a read-only role in PostgreSQL and use it to assign it to multiple new users, who should have read-only access. It makes sense to me to also grant the read-only permissions to the ...
user avatar
2 votes
1 answer
118 views

Allow user to GRANT certain permissions to others

I have tried googling this but may well be using the wrong terms... permissions and the like aren't my strong point. What I want to do is first create a role - eg 'Snr_Analyst' - with certain ...
user avatar
  • 278
0 votes
1 answer
20 views

How to structure MySQL database tables for users and how to handle adding/removing permissions?

I am making a database structure for users, who can become part of a group, and within that group the admin of the group can assign as many permissions to a user as they would like. This part seems ...
user avatar
-1 votes
1 answer
183 views

Availability Group is not failovering when a cluster core resource is failedover

I have created always on availability group.The cluster core resources failover is happening. The availability group (Automatic) failover is happening. But, when the cluster core resource is failed ...
user avatar
0 votes
1 answer
151 views

Deny DDL_ADMIN permissions to a role on [dbo] schema

I have several database schemas like, [ext],[stag],etc and of course the built in [dbo] schema, and also have a role called [MyRole]. My plan is to add [MyRole] to the DDL_ADMIN role, so they can ...
user avatar
  • 266
0 votes
0 answers
88 views

Why isn't "DROP OWNED BY" freeing up my ability to drop a role?

I'm using Postgres 9.6 on Mac. I would like to drop a user/role. I logged in as my super user (postgres) and tried this postgres=# DROP ROLE chicommons; ERROR: role "chicommons" cannot be ...
user avatar
  • 605
0 votes
1 answer
541 views

Why availability group resource goes offline in WSFC?

Sometimes I find the AG Cluster role in offline state which results the AG in resolving state. It doesn't allow the application to access the databases during this time. And then after sometime it ...
user avatar
0 votes
1 answer
108 views

Can't create view using a role

I am learning Oracle and have to do roles. I created an c##admin from a sys, granted him all grants. Then I created a c##manager_role and c##manager. I granted this role to c##manager. After that I ...
user avatar
0 votes
1 answer
706 views

GRANT ROLE TO USER in MySQL

I created one role QI_RO, granted all privileges on all schemas on the server and I was trying to grant role privilege to another user but throwing error. GRANT QI_RO to test_user@'%'; Error Message: ...
user avatar
  • 358
0 votes
0 answers
28 views

SQL Group Execution Rights to Read only SPs and functions - By not changing objects' schemas

We have a SQL Developer Group.. We want to give them access to execute functions and sps but not to any that amends data in any way.. We currently only have the DBO schema and all objects sits on that ...
user avatar
  • 1
0 votes
1 answer
205 views

Postgres default privileges do not seem to work

I am trying to set up RBAC in Postgres where I have a database and a schema. I have a few roles provisioner, service, mydb_ro, and mydb_rw. I ran the following to change default privileges ALTER ...
user avatar
  • 105
2 votes
1 answer
510 views

Do I need GRANT for INSERT to table If has EXECUTION GRANT for procedure?

I have five domain users and five roles in my database. GRANT EXECUTE adds to the appropriate roles. Roles are included in other roles, i.e. at most we have one role that has grants for two procedures,...
user avatar
  • 91
0 votes
0 answers
889 views

Best practice privileges and roles for postgres schema migration

I'm having a re-look at roles and privileges in postgres to minimise the damage that a compromised account can do. Ownership and migrations is a part I'm having trouble getting my head around. As I ...
user avatar
  • 469

1
2 3 4 5 6