728 questions
1
vote
1
answer
118
views
Unallowed GRANT does not raise an exception and doesn't grant the privilege either, if user already has other privileges on the object
I have a regression test for a PostgreSQL database that checks to make sure a particular user cannot self-assign additional privileges to a particular schema. I do this by logging in as the user "...
0
votes
1
answer
251
views
Can we use refresh token grant type with PKCE?
Is there any way to create public client that supports refresh token grant type? If not, how can I refresh tokens in my single page application?
I created spring boot authentication server
spring ...
0
votes
0
answers
44
views
utPLSQL in Oracle SQL Developer: ORA-01031: insufficient privileges
I'm using utPLSQL to perform unit testing in Oracle. Here are all the privileges I granted to the user in the utPLSQL schema:
GRANT EXECUTE ON DBMS_LOCK TO utester;
GRANT CREATE SESSION TO utester;
...
1
vote
1
answer
105
views
Grant with Grant option not working in SQL Server
I have two server logins, OMEGACA and TEST, and an ALL SERVER for LOGON trigger:
CREATE TRIGGER [OMEGACA_ACC]
ON ALL SERVER WITH EXECUTE AS 'OMEGACA'
FOR LOGON
AS
-- ...............
OMEGACA has ...
0
votes
1
answer
79
views
Access system object via a view whose owner is granted with grant option
I have created the following view in my database, my schema
CREATE VIEW [OMEGACA].[V_SYS_MANAGE_ACC]
AS
SELECT
name, object_id, parent_class, parent_class_desc, parent_id,
...
1
vote
1
answer
59
views
Prevent user from manipulating subset of columns by RLS on view with no RLS on table
I want to use use VIEWS for column security. db<>fiddle
create table users(user_id, first_name, create_time)as values
(1, 'Adam', 'yesterday'::timestamptz)
, (2, 'Bob' , 'today');
create ...
0
votes
1
answer
54
views
No privileges when executing Oracle stored procedure
I have a problem with an Oracle stored procedure that dynamically creates some materialized views.
The procedure first drops the materialized views if there are any with the same name of the ones that ...
0
votes
1
answer
156
views
PostgreSQL privilege, setting or feature to limit number of rows a user can select
Using PostgreSQL, is it somehow possible to restrict the SELECT privilege of a certain user so that he can only select a certain limited number of rows from a certain table?
For example, user joe ...
1
vote
1
answer
400
views
ORA-27486: Insufficient Privileges
I'm getting "ORA-27486: Insufficient privileges" error.
What grants am I missing here?
I'm executing an insert script using DBMS_PARALLEL_EXECUTE and I'm getting getting this error in ...
3
votes
1
answer
189
views
Postgres Permissions violated by before-insert trigger function
I've got a table with row level permissions enabled. I've got an insert policy for my user, and I've granted permissions for them on specific columns. I added a new column to track the id of whoever ...
1
vote
0
answers
303
views
Why one superuser cannot use GRANT in Postgres 16
Postgres 16 has user ingmar which is marked as superuser and has create role rights:
CREATE ROLE ingmar WITH
LOGIN
SUPERUSER
INHERIT
CREATEDB
CREATEROLE
NOREPLICATION
BYPASSRLS
...
0
votes
1
answer
576
views
How to get Future Grants over Schema in Snowflake?
I have a use case where I need to check for FUTURE grants on an input database and schema. If FUTURE grants are found and not match with Input Role then I want to revoke them and then assign the ...
0
votes
1
answer
343
views
Cannot grant user privilege to create REFERENCES in MySQL 8
I tried to create the quartz table with a user that has privilege as below.
Privileges: [Select, Insert, Update, Delete, Create, Drop, File, Index, Alter, Show databases, Create temporary tables, Lock ...
1
vote
1
answer
978
views
How to add permission to custom role in postgres to create index
I am currently creating a role for a particular database using the below sql script executed as master user (postgres).
CREATE USER customrole WITH PASSWORD 'mypassword';
-- removed CREATE ...
0
votes
1
answer
79
views
Grant user to create table oracle
In my oracle 23ai instance, as ADMIN user I created this user:
CREATE USER IF NOT EXISTS USER000 IDENTIFIED BY MyHardP4ssword';
Then I granted him some privileges:
GRANT RESOURCE, CONNECT, CREATE ...
2
votes
1
answer
2k
views
user cannot create table on schema public Postgres 16
I have to create a table in Postgres public schema for Airflow implementation. When I create a table with airflow user I get this error
permission denied for schema public
LINE 1: CREATE TABLE public....
0
votes
0
answers
56
views
Oracle Revoke Invalid Grants
I'm currently in the process of migrating a database, and dropping several schemas in the move.
The schemas I'm excluding have grants on some of the schemas that are included. Like grant update on ...
0
votes
1
answer
194
views
Views Creation Permissions without table Creation Permissions in POSTGRESQL
I have a use case where I want to create a user which should have access on select for public schema and Views Creation On public schema but not table creation User can create a new view but not table
...
2
votes
1
answer
152
views
How to retrieve user access rights with FireDAC
I am using FireDAC to access a MySQL database from within Delphi.
When logging in into the database I give in the database user name, which is defined within MySQL and has certain access right.
How ...
0
votes
0
answers
185
views
supabase postgress roles error in flutter
in supabase
after creating role 'adminRole'
then granting the role to an email through
update auth.users set role = 'adminRole' where email='my email';
i checked the table and it did update.
then ...
0
votes
1
answer
277
views
Only allow user to Execute a specific procedure
I'm looking for a solution where a user's only permission it to execute a procedure. In my example below, that procedure is lowlevel.ZipFile (Main Procedure). The problem is that the procedure itself ...
0
votes
0
answers
67
views
'Grant' Word 403 Forbidden Issue in Ajax Form Submission
403 Forbidden Issue with 'grant' (example: [email protected]) word in email ID if we send an email to multiple email IDs. When we send mail to a single email (including [email protected]) to anyone, it's ...
0
votes
1
answer
221
views
How to grant execution permission on procedure to ALL USERS
I need to grant all users with execution permissions to execute myprocedure
I'm using this:
grant execute on procedure myprocedure to '*'@'%%';
And I got this:
SQL Error [1410] [42000]: You are not ...
-2
votes
1
answer
44
views
Set/Reset Superuser/Root in MySql [duplicate]
I don't have a superuser in mysql (v8.0, with Linux Mint) and I cannot log into any database or alter any record or table (including the Grant table)
I've tried reinstalling mysql and deleting all ...
0
votes
1
answer
2k
views
postgres user has no access to public schema
I am getting the following error on postgresql 12:
ERROR: permission denied for schema public
even though I am logged in as postgres (who is superuser), and I have granted all on the schema, and on ...
1
vote
1
answer
107
views
User-name case sensitivity in MySQL grant statement
My impression is that MySQL is generally not case-sensitive, especially in MS Windows. In MySQL 8.0.34, I ran the following statements and got an error for the last statement. The error message is &...
2
votes
1
answer
1k
views
GRANT USER to another user does not grant permissions
I have user 'administrator' with CREATEROLE privileges. I create new user like this:
CREATE USER test_user;
And then i grant privileges to the new user:
GRANT administrator TO test_user;
When i'm ...
1
vote
1
answer
252
views
Oracle grant execute to package doesn't work
I created package in schema CUST_DEV. In proc from my package I use proc from other package CUST_DS.CUST_CTL.proc(). When i recompile my package i received error: PLS-00201: CUST_DS.CUST_CTL.proc ...
2
votes
1
answer
3k
views
Is there any way to grant RDSADMIN USER privileges to a user?
GRANT APPLICATION_PASSWORD_ADMIN,BACKUP_ADMIN,FLUSH_OPTIMIZER_COSTS,FLUSH_STATUS,FLUSH_TABLES,FLUSH_USER_RESOURCES,
INNODB_REDO_LOG_ARCHIVE,PASSWORDLESS_USER_ADMIN,SHOW_ROUTINE
I want to grant these ...
1
vote
1
answer
184
views
DB owner can not grant select
I want to have an owner of a database that can create roles and do all administrative tasks for that db. All roles created by the db owner must have select on all tables in the public schema as well ...
1
vote
0
answers
330
views
How to assign query permissions to a role for all tables in a database when hive.security.authorization.enabled is set to true
I want to restrict the access rights of different users through the standard SQL permission control that comes with Hive, but I don't know that if you can batch authorize tables under a certain ...
0
votes
1
answer
391
views
Oracle database link to a package saying table not found
We've created a database link from an Oracle 12.1 DB to Oracle APEX 21.2 (Oracle 19c) and have granted EXECUTE to a package and granted SELECT to all the listed tables inside the function that's used ...
0
votes
1
answer
190
views
DBA grant option and permission issue
In MySQL database, If a DBA grant select to a user1 as well as with grant option, then this user1 grant select access to user 2, can the DBA revoke user2 but not affect user 1 permission?
I tried ...
1
vote
1
answer
3k
views
grant particular table access to role in Snowflake
I have created a new table called db.public.newTable.
Now I need to give this table access to the role developer in Snowflake. What will the correct query grant this table access to the role developer?...
0
votes
1
answer
263
views
Clear/remove all GRANT and DENY of a user in SQL
I see a lot of GRANT and DENY records in table sys.database_permissions for a specific user.
How can I delete/clear all these entries?
I need to clear to run a script that will do the appropriate ...
0
votes
1
answer
115
views
Allow only Service Account to Execute block of Code to Decrypt Column Level Values in SQL Server
We have implemented Column level encryption on CON_String column which has username/password based connection strings. We have been using following code in order to see the decrypted column values
...
1
vote
1
answer
496
views
oracle sql 'Alter USER test_user2 GRANT CONNECT THROUGH test_user1 ROLE myTestRole1;' throwing 'ORA-00933: SQL command not properly ended' error
I'm executing the following sql
Alter USER test_user2 GRANT CONNECT THROUGH test_user1 ROLE myTestRole1;
in Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 database and running in to the ...
0
votes
1
answer
155
views
Cannot assign permissions to a user to perform a backup in MySQL
I am trying make an user for make backups in my database with the next privileges:
GRANT SELECT, LOCK TABLES, SHOW VIEW, TRIGGER, EXECUTE, PROCESS ON mydatabase.* to op_backup@'localhost';
but i ...
0
votes
1
answer
158
views
Creating users with different privileges and list these users with their privileges in PostgreSQL
I want to create users with different priviledges for example read and write and admin for just a database.
I create users with grants but when I use \du it doesn't show me anything that I can use to ...
-1
votes
1
answer
608
views
Oracle: Grants for select from SYS.DBMS_LOCK_ALLOCATED
I'm wondering do I need just SELECT FROM grant to select from SYS.DBMS_LOCK_ALLOCATED or there is some special role for it?
I'm unable to grant SELECT FROM SYS.DBMS_LOCK_ALLOCATED to my test user, so ...
0
votes
0
answers
36
views
GRANT ALL doesnt work for new tables in postgres [duplicate]
I have script to create user and grant all privileges for table in postgres
create user dev_api with encrypted password 'xxx';
grant all privileges on database dev to dev_api;
ALTER USER dev_api ...
0
votes
0
answers
83
views
MySQL GRANT OPTION Limitation
I'm trying to build an application which will be accessed by three types of people, they are Admins, Managers, and Students. I have created three users in MySQL DB and restricted their access to the ...
1
vote
1
answer
687
views
How to know if oracle GRANT command actually changed anything
Having run a grant command in an Oracle SQL script, is there any way to tell if it actually changed anything. Like an equivalent of SQL%ROWCOUNT or similar?
I am writing an ansible module which will ...
1
vote
2
answers
5k
views
Permission denied to create table even after using GRANT command
I'm connected to a Postgres 14 instance with postgres role. I have created a new database called airflow and a new user/role called airflow too, who is the owner of the db.
...
0
votes
1
answer
47
views
PLSQL Grant on Tables used on a package
I have two procedures one defines and uses a CURSOR with table from another schema and it gives me an error of insufficient privileges; the other one, creates a table with a dynamic SQL, referencing ...
1
vote
1
answer
198
views
Postgres: How Can a Role Both Have INSERT Permissions and Not?
I have a table called resources and a user/role called public_anonymous ... and as far as I can tell, the user doesn't have INSERT permissions on that table. Here's DBeaver showing as much:
And here'...
0
votes
0
answers
434
views
GRANT CREATE only on specific schema to specific role SQL Server
I'm looking to GRANT all sorts of CREATE statements on specific schemas in my DB for specific members of a role;
Here's my current setup, I have:
Schema A
Schema B
Role A
Role B
SQL Login A
SQL ...
1
vote
0
answers
422
views
Why creating a role in Oracle SQL with SELECT privileges doesn't work anymore?
I created a role and it worked. Then I dropped it, and when I try to recreate it it doesn't work anymore.
I have to create a role, grant select to that role and grant that role to a user named user2, ...
1
vote
0
answers
123
views
How to access granted media_projection thought root?
how can I use the root command to grant permission to "media projection" or to another: "screen capture/screenshot"? maybe it's some kind of "activity" you need to run?
I ...
0
votes
1
answer
390
views
how to grant select, different servers, same username/password different schema
I'm not a DB expert, my boss has retired and it's up to me now. He created a production database, and a test database on another server with same username/password and schema name test_SameAsOtherDB. ...