pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
i have a problem of privilages
6+ messages / 4 participants
[nested] [flat]

* i have a problem of privilages
@ 2006-07-04 10:05 Penchalaiah P. <penchalaiahp@infics.com>
  2006-07-04 12:17 ` Re: i have a problem of privilages MJ Santhosh <mjsanthosh@gmail.com>
  0 siblings, 1 reply; 6+ messages in thread

From: Penchalaiah P. @ 2006-07-04 10:05 UTC (permalink / raw)
  To: pgsql-sql; +Cc: Richard Broersma Jr <rabroersma@yahoo.com>


Hi good afternoon to every one..



Now I am accessing remote database server in postgresql.. but I can see
all tables and functions in remote database server but I can
delete,update,alter and drop tables in remote database server from my
local machine.. to avoid these things wt I have to do...

Just they have to see my tables and structure.. and they cant do any
more operations on the tables.. to avoid this wt can I do please tell me
solution ...





Thanks  &  Regards

Penchal reddy | Software Engineer          

Infinite Computer Solutions | Exciting Times...Infinite Possibilities...


SEI-CMMI level 5 | ISO 9001:2000

IT SERVICES | BPO


Telecom | Finance | Healthcare | Manufacturing | Energy & Utilities |
Retail & Distribution | Government


Tel +91-80-5193-0000(Ext:503)| Fax  +91-80-51930009 | Cell No
+91-9980012376|www.infics.com         

Information transmitted by this e-mail is proprietary to Infinite
Computer Solutions and/ or its Customers and is intended for use only by
the individual or entity to which it is addressed, and may contain
information that is privileged, confidential or exempt from disclosure
under applicable law. If you are not the intended recipient or it
appears that this mail has been forwarded to you without proper
authority, you are notified that any use or dissemination of this
information in any manner is strictly prohibited. In such cases, please
notify us immediately at info.in@infics.com and delete this mail from
your records.





Information transmitted by this e-mail is proprietary to Infinite Computer Solutions and / or its Customers and is intended for use only by the individual or the entity to which it is addressed, and may contain information that is privileged, confidential or exempt from disclosure under applicable law. If you are not the intended recipient or it appears that this mail has been forwarded to you without proper authority, you are notified that any use or dissemination of this information in any manner is strictly prohibited. In such cases, please notify us immediately at info.in@infics.com and delete this email from your records.

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: i have a problem of privilages
  2006-07-04 10:05 i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
@ 2006-07-04 12:17 ` MJ Santhosh <mjsanthosh@gmail.com>
  0 siblings, 0 replies; 6+ messages in thread

From: MJ Santhosh @ 2006-07-04 12:17 UTC (permalink / raw)
  To: Penchalaiah P. <penchalaiahp@infics.com>; +Cc: pgsql-sql@postgresql.org, "Richard Broersma Jr" <rabroersma@yahoo.com>

  create a user with limited permmission and give the same to the remote
users.
May be that will solve your problem.



** REVOKE INSERT,UPDATE,DELETE ON welcome from PUBLIC;

On 7/4/06, Penchalaiah P. <penchalaiahp@infics.com> wrote:
>
>  Hi good afternoon to every one..
>
>
>
> Now I am accessing remote database server in postgresql.. but I can see
> all tables and functions in remote database server but I can
> delete,update,alter and drop tables in remote database server from my local
> machine.. to avoid these things wt I have to do…
>
> Just they have to see my tables and structure.. and they cant do any more
> operations on the tables.. to avoid this wt can I do please tell me solution
> …
>
>
>
>
>
> *Thanks  &  Regards*
>
> *Penchal reddy **|** Software Engineer           *
>
> *Infinite Computer Solutions **|** Exciting Times…Infinite
> Possibilities... *
>
> *SEI-CMMI level 5 **| **ISO 9001:2000*
>
> *IT SERVICES **|**BPO
> *
>
> *Telecom **|** **Finance **|** **Healthcare **| **Manufacturing **|** **Energy
> & Utilities **|** **Retail & Distribution **|** **Government
> *
>
> *Tel +91-80-5193-0000(Ext:503)**|** Fax  +91-80-51930009 **|** Cell No
> +91-9980012376**|**www.infics.com**          *
>
> *Information transmitted by this e-mail is proprietary to Infinite
> Computer Solutions and/ or its Customers and is intended for use only by the
> individual or entity to which it is addressed, and may contain information
> that is privileged, confidential or exempt from disclosure under applicable
> law. If you are not the intended recipient or it appears that this mail has
> been forwarded to you without proper authority, you are notified that any
> use or dissemination of this information in any manner is strictly
> prohibited. In such cases, please notify us immediately at** **
> info.in@infics.com **and delete this mail from your records.*
>
>
>  Information transmitted by this e-mail is proprietary to Infinite
> Computer Solutions and / or its Customers and is intended for use only by
> the individual or the entity to which it is addressed, and may contain
> information that is privileged, confidential or exempt from disclosure under
> applicable law. If you are not the intended recipient or it appears that
> this mail has been forwarded to you without proper authority, you are
> notified that any use or dissemination of this information in any manner is
> strictly prohibited. In such cases, please notify us immediately at
> info.in@infics.com and delete this email from your records.
>



--

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: i have a problem of privilages
@ 2006-07-04 12:23 Penchalaiah P. <penchalaiahp@infics.com>
  2006-07-04 12:31 ` Re: i have a problem of privilages MJ Santhosh <mjsanthosh@gmail.com>
  0 siblings, 1 reply; 6+ messages in thread

From: Penchalaiah P. @ 2006-07-04 12:23 UTC (permalink / raw)
  To: MJ Santhosh <mjsanthosh@gmail.com>; +Cc: pgsql-sql


I have 290 tables .. to these tables one schema is there .. that name is
public....so I don't know how to create permission to these tables..
either I have to give permissions to individual table.. or I have to
give permissions to schema or schema name... if I give permission to
schema it has to applicable to all tables..



I created one user  with password... then finally I don't know how to
allocate permission to him.. please tell me very briefly step by step..
then I can understand...

Please tell me if any one knows about this........



________________________________

From: MJ Santhosh [mailto:mjsanthosh@gmail.com]
Sent: Tuesday, July 04, 2006 5:47 PM
To: Penchalaiah P.
Cc: pgsql-sql@postgresql.org; Richard Broersma Jr
Subject: Re: [SQL] i have a problem of privilages




  create a user with limited permmission and give the same to the remote
users.
May be that will solve your problem.



REVOKE INSERT,UPDATE,DELETE ON welcome from PUBLIC;

On 7/4/06, Penchalaiah P. <penchalaiahp@infics.com> wrote:

Hi good afternoon to every one..



Now I am accessing remote database server in postgresql.. but I can see
all tables and functions in remote database server but I can
delete,update,alter and drop tables in remote database server from my
local machine.. to avoid these things wt I have to do...

Just they have to see my tables and structure.. and they cant do any
more operations on the tables.. to avoid this wt can I do please tell me
solution ...





Thanks  &  Regards

Penchal reddy | Software Engineer          

Infinite Computer Solutions | Exciting Times...Infinite Possibilities...


SEI-CMMI level 5 | ISO 9001:2000

IT SERVICES | BPO


Telecom | Finance | Healthcare | Manufacturing | Energy & Utilities |
Retail & Distribution | Government


Tel +91-80-5193-0000(Ext:503) | Fax  +91-80-51930009 | Cell No
+91-9980012376 | www.infics.com <http://www.infics.com;           

Information transmitted by this e-mail is proprietary to Infinite
Computer Solutions and/ or its Customers and is intended for use only by
the individual or entity to which it is addressed, and may contain
information that is privileged, confidential or exempt from disclosure
under applicable law. If you are not the intended recipient or it
appears that this mail has been forwarded to you without proper
authority, you are notified that any use or dissemination of this
information in any manner is strictly prohibited. In such cases, please
notify us immediately at info.in@infics.com and delete this mail from
your records.



Information transmitted by this e-mail is proprietary to Infinite
Computer Solutions and / or its Customers and is intended for use only
by the individual or the entity to which it is addressed, and may
contain information that is privileged, confidential or exempt from
disclosure under applicable law. If you are not the intended recipient
or it appears that this mail has been forwarded to you without proper
authority, you are notified that any use or dissemination of this
information in any manner is strictly prohibited. In such cases, please
notify us immediately at info.in@infics.com and delete this email from
your records.




--



Information transmitted by this e-mail is proprietary to Infinite Computer Solutions and / or its Customers and is intended for use only by the individual or the entity to which it is addressed, and may contain information that is privileged, confidential or exempt from disclosure under applicable law. If you are not the intended recipient or it appears that this mail has been forwarded to you without proper authority, you are notified that any use or dissemination of this information in any manner is strictly prohibited. In such cases, please notify us immediately at info.in@infics.com and delete this email from your records.

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: i have a problem of privilages
  2006-07-04 12:23 Re: i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
@ 2006-07-04 12:31 ` MJ Santhosh <mjsanthosh@gmail.com>
  2006-07-04 14:51   ` Re: i have a problem of privilages Richard Broersma Jr <rabroersma@yahoo.com>
  2006-07-04 15:30   ` Re: i have a problem of privilages Andreas Kretschmer <akretschmer@spamfence.net>
  0 siblings, 2 replies; 6+ messages in thread

From: MJ Santhosh @ 2006-07-04 12:31 UTC (permalink / raw)
  To: Penchalaiah P. <penchalaiahp@infics.com>; +Cc: pgsql-sql

 I am not an expert in postgres, may this work for you.

REVOKE INSERT,UPDATE,DELETE ON ALL from PUBLIC;


it will take the INSERT,UPDATE,DELETE permmission from all users for all
objects in the database.

If you want to give permission for a specific user on all objects

GRANT ALL on ALL to <user_name>;

Please make a backup before doing this , good for always
I am not sure is this is want you want.



On 7/4/06, Penchalaiah P. <penchalaiahp@infics.com> wrote:
>
>  I have 290 tables .. to these tables one schema is there .. that name is
> public….so I don't know how to create permission to these tables.. either I
> have to give permissions to individual table.. or I have to give permissions
> to schema or schema name… if I give permission to schema it has to
> applicable to all tables..
>
>
>
> I created one user  with password… then finally I don't know how to
> allocate permission to him.. please tell me very briefly step by step.. then
> I can understand…
>
> Please tell me if any one knows about this……..
>
>
>  ------------------------------
>
> *From:* MJ Santhosh [mailto:mjsanthosh@gmail.com]
> *Sent:* Tuesday, July 04, 2006 5:47 PM
> *To:* Penchalaiah P.
> *Cc:* pgsql-sql@postgresql.org; Richard Broersma Jr
> *Subject:* Re: [SQL] i have a problem of privilages
>
>
>
>
>   create a user with limited permmission and give the same to the remote
> users.
> May be that will solve your problem.
>
>
>
> *REVOKE INSERT,UPDATE,DELETE ON welcome from PUBLIC; *
>
> On 7/4/06, *Penchalaiah P.* <penchalaiahp@infics.com> wrote:
>
> Hi good afternoon to every one..
>
>
>
> Now I am accessing remote database server in postgresql.. but I can see
> all tables and functions in remote database server but I can
> delete,update,alter and drop tables in remote database server from my local
> machine.. to avoid these things wt I have to do…
>
> Just they have to see my tables and structure.. and they cant do any more
> operations on the tables.. to avoid this wt can I do please tell me solution
> …
>
>
>
>
>
> *Thanks  &  Regards *
>
> *Penchal reddy **|** Software Engineer           *
>
> *Infinite Computer Solutions **|** Exciting Times…Infinite
> Possibilities... *
>
> *SEI-CMMI level 5 **| **ISO 9001:2000*
>
> *IT SERVICES **|**BPO
> *
>
> *Telecom **|** **Finance **|** **Healthcare **| **Manufacturing **|** **Energy
> & Utilities **|** **Retail & Distribution **|** **Government
> *
>
> *Tel +91-80-5193-0000(Ext:503)** **|** Fax  +91-80-51930009 **|** **Cell
> No  +91-9980012376** |** www.infics.com**           *
>
> *Information transmitted by this e-mail is proprietary to Infinite
> Computer Solutions and/ or its Customers and is intended for use only by the
> individual or entity to which it is addressed, and may contain information
> that is privileged, confidential or exempt from disclosure under applicable
> law. If you are not the intended recipient or it appears that this mail has
> been forwarded to you without proper authority, you are notified that any
> use or dissemination of this information in any manner is strictly
> prohibited. In such cases, please notify us immediately at** **
> info.in@infics.com **and delete this mail from your records. *
>
>
>
> Information transmitted by this e-mail is proprietary to Infinite Computer
> Solutions and / or its Customers and is intended for use only by the
> individual or the entity to which it is addressed, and may contain
> information that is privileged, confidential or exempt from disclosure under
> applicable law. If you are not the intended recipient or it appears that
> this mail has been forwarded to you without proper authority, you are
> notified that any use or dissemination of this information in any manner is
> strictly prohibited. In such cases, please notify us immediately at
> info.in@infics.com and delete this email from your records.
>
>
>
>
> --
>  Information transmitted by this e-mail is proprietary to Infinite
> Computer Solutions and / or its Customers and is intended for use only by
> the individual or the entity to which it is addressed, and may contain
> information that is privileged, confidential or exempt from disclosure under
> applicable law. If you are not the intended recipient or it appears that
> this mail has been forwarded to you without proper authority, you are
> notified that any use or dissemination of this information in any manner is
> strictly prohibited. In such cases, please notify us immediately at
> info.in@infics.com and delete this email from your records.
>


_________________________________________________________
it is your attitude, and not the aptitude, that determines your altitude.
_________________________________________________________

^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: i have a problem of privilages
  2006-07-04 12:23 Re: i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
  2006-07-04 12:31 ` Re: i have a problem of privilages MJ Santhosh <mjsanthosh@gmail.com>
@ 2006-07-04 14:51   ` Richard Broersma Jr <rabroersma@yahoo.com>
  1 sibling, 0 replies; 6+ messages in thread

From: Richard Broersma Jr @ 2006-07-04 14:51 UTC (permalink / raw)
  To: MJ Santhosh <mjsanthosh@gmail.com>; Penchalaiah P. <penchalaiahp@infics.com>; +Cc: pgsql-sql

>  I am not an expert in postgres, may this work for you.
> REVOKE INSERT,UPDATE,DELETE ON ALL from PUBLIC;
> it will take the INSERT,UPDATE,DELETE permmission from all users for all
> objects in the database.
> If you want to give permission for a specific user on all objects
> GRANT ALL on ALL to <user_name>;
> Please make a backup before doing this , good for always
> I am not sure is this is want you want.
> 
> On 7/4/06, Penchalaiah P. <penchalaiahp@infics.com> wrote:
> >
> >  I have 290 tables .. to these tables one schema is there .. that name is
> > public….so I don't know how to create permission to these tables.. either I
> > have to give permissions to individual table.. or I have to give permissions
> > to schema or schema name… if I give permission to schema it has to
> > applicable to all tables..
> > I created one user  with password… then finally I don't know how to
> > allocate permission to him.. please tell me very briefly step by step.. then
> > I can understand…
> > Please tell me if any one knows about this……..

One way to limit which users can access specific database is with the pg_hba.conf file.
You really should spend some time to read it.
http://www.postgresql.org/docs/8.1/interactive/client-authentication.html#AUTH-PG-HBA-CONF

In PostgreSQL 8.1 the concept of "Roles" were added.  A "Role" can be given specific privileges to
the database.  Once this step is complete, database uses can be assigned to this role.  This will
essentially inherit all role privileges to these users.  There is also an important document that
should be read in order to understand it.
http://www.postgresql.org/docs/8.1/interactive/user-manag.html

The SQL syntax for assigning privileges is found here:
http://www.postgresql.org/docs/8.1/interactive/ddl-priv.html

Also finding these topic is very easy also. Simple scan over the table of contents of the manual:
http://www.postgresql.org/docs/8.1/interactive/index.html

And of-course depending on what version of PostgreSQL you have:
http://www.postgresql.org/docs/manuals/

Regards,

Richard Broersma Jr.



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* Re: i have a problem of privilages
  2006-07-04 12:23 Re: i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
  2006-07-04 12:31 ` Re: i have a problem of privilages MJ Santhosh <mjsanthosh@gmail.com>
@ 2006-07-04 15:30   ` Andreas Kretschmer <akretschmer@spamfence.net>
  1 sibling, 0 replies; 6+ messages in thread

From: Andreas Kretschmer @ 2006-07-04 15:30 UTC (permalink / raw)
  To: pgsql-sql

MJ Santhosh <mjsanthosh@gmail.com> schrieb:

>  I am not an expert in postgres, may this work for you.
> 
> REVOKE INSERT,UPDATE,DELETE ON ALL from PUBLIC;

IIRC, you cant REVOKE ... ON ALL, you need a table-name instead ALL.

But, you can create a script for all tables:
http://people.planetpostgresql.org/greg/index.php?/archives/38-Scripting-with-psql.html

> On 7/4/06, PPeenncchhaallaaiiaahh PP.. <_p_e_n_c_h_a_l_a_i_a_h_p_@_i_n_f_i_c_s_._c_o_m> wrote:

Please, no silly HTML, and no silly TOFU (german: Text Oben Fullquote
Unten), it means the very silly habit to write the answer above the
question. This is hard to read.

(sorry for my bad english, i know, it's hard to read too)


Andreas
-- 
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect.                              (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly."    (unknow)
Kaufbach, Saxony, Germany, Europe.              N 51.05082°, E 13.56889°



^ permalink  raw  reply  [nested|flat] 6+ messages in thread


end of thread, other threads:[~2006-07-04 15:30 UTC | newest]

Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-07-04 10:05 i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
2006-07-04 12:17 ` MJ Santhosh <mjsanthosh@gmail.com>
2006-07-04 12:23 Re: i have a problem of privilages Penchalaiah P. <penchalaiahp@infics.com>
2006-07-04 12:31 ` MJ Santhosh <mjsanthosh@gmail.com>
2006-07-04 14:51   ` Richard Broersma Jr <rabroersma@yahoo.com>
2006-07-04 15:30   ` Andreas Kretschmer <akretschmer@spamfence.net>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox