agora inbox for pgsql-sql@postgresql.org
help / color / mirror / Atom feedFrom: John R Pierce <pierce@hogranch.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: Roles and security
Date: Sat, 25 Nov 2017 15:15:03 -0800
Message-ID: <f5ab66e4-da3b-c5fe-7d3f-76096ef34071@hogranch.com> (raw)
In-Reply-To: <CAG1ps1xNAQVEWp6vs0bKtAxkK+Ut1V+GLPHHuEQM9j_uhyWbcQ@mail.gmail.com>
References: <CAG1ps1zxvGoDAahyVqs44drEyUsB-6BkSHQ=-w9MOwEAHm=YGg@mail.gmail.com>
<CAG1ps1y=Gv4O1WpbXE7C=Y5snAY-cXafBdtX1opSAuEqkxoeSA@mail.gmail.com>
<CAG1ps1xw-kEqXEvf9D2zdB7fu3GuH66+wp122ZN+mMdW-eZcvw@mail.gmail.com>
<CAG1ps1wyzEyBu_snQf4Y9_VXtvsFZNH1=s9PCGPHzw2fxHY0GA@mail.gmail.com>
<CAG1ps1x+D5BBwQRKi6irMWU0qS0Yn-W70qVX0HniD6=hnZ-vqQ@mail.gmail.com>
<CAG1ps1xZ1vhd9oM+xTi+M6WfQtHA25sAdkRsrypvKh_QGxQyXQ@mail.gmail.com>
<CAG1ps1w0fZ9ykNjJhp90HqNP3NC9fotoLY_T8SXgU4qdt5MhsA@mail.gmail.com>
<CAG1ps1wihb0XsLVK1DNa7qTJrzazqoNudR7ncx5Go2s-zWbYhg@mail.gmail.com>
<CAG1ps1y_e9r0hjNF2RGBin1C5tQZrocvpPRbnpfNNw13QL5Tgw@mail.gmail.com>
<CAG1ps1y4bqk-iZ6GvcEorDTH5jhs5XjNbY4d8fxST_S7683YFg@mail.gmail.com>
<CAG1ps1yxTD84QLBw38LPh2nmj+Kn4j7F0T=-EN7tnEzuU1c6vQ@mail.gmail.com>
<CAG1ps1w2J2aiK5v6dotLhEnt4OH_-1rnsmDHqZnzsVwb941wLg@mail.gmail.com>
<CAG1ps1wEfeZMYB3BROVS+wY_r7r2esvnnzMsGGt0sc8OTB6CZA@mail.gmail.com>
<CAG1ps1xNAQVEWp6vs0bKtAxkK+Ut1V+GLPHHuEQM9j_uhyWbcQ@mail.gmail.com>
On 11/25/2017 12:03 PM, nikhil raj wrote:
> check the roles of user I want to give user roles only select,
> insert, update, execute and create database to all users Permission
>
those permissions can be assigned on a table by table basis, except
create database, thats a special permission. if you own a database
(the creator owns it by default) then you can drop it, if you don't, you
can't.
>
> The users should not have these permission
> drop database , delete table permission
generally the owners of objects can grant/revoke permissions on said
objects.
>
>
> **(Example --like in MS SQL we have like DB_roles-- ddladmin,data
> writer,data reader ,etc like these do we have in postgres).***
you could create roles like these, make users members of these roles,a
nd grant permissions to the roles.
for more information, see
https://www.postgresql.org/docs/current/static/user-manag.html
https://www.postgresql.org/docs/current/static/sql-grant.html
https://www.postgresql.org/docs/current/static/sql-revoke.html
https://www.postgresql.org/docs/current/static/sql-alterdefaultprivileges.html
--
john r pierce, recycling bits in santa cruz
view thread (3+ messages) latest in thread
Message-ID: <f5ab66e4-da3b-c5fe-7d3f-76096ef34071@hogranch.com>
Permalink: ../f5ab66e4-da3b-c5fe-7d3f-76096ef34071@hogranch.com/
Also on: postgresql.org/message-id/f5ab66e4-da3b-c5fe-7d3f-76096ef34071@hogranch.com
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: pierce@hogranch.com, pgsql-general@lists.postgresql.org
Subject: Re: Roles and security
In-Reply-To: <f5ab66e4-da3b-c5fe-7d3f-76096ef34071@hogranch.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox