Protected custom configuration option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I am looking for a way to define custom configuration option that will
only be accessible to roles with the "pg_read_all_settings" privilege.

I see such variables defined with the GUC_SUPERUSER_ONLY flag within
src/backend/utils/misc/guc.c:

{"ssl_ecdh_curve", PGC_SIGHUP, CONN_AUTH_SSL,
  gettext_noop("Sets the curve to use for ECDH."),
  NULL,
  GUC_SUPERUSER_ONLY
},
&SSLECDHCurve,

Is it possible to have a custom setting defined with this flag and
how? Only through an extension written in C, maybe?

What I need is something like:

kouber=> show redis.pass;
ERROR:  must be superuser or a member of pg_read_all_settings to
examine "redis.pass"

Cheers,
--
Kouber




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux