PostgreSQL Source Code  git master
test_oat_hooks.c File Reference
#include "postgres.h"
#include "access/parallel.h"
#include "catalog/dependency.h"
#include "catalog/objectaccess.h"
#include "catalog/pg_proc.h"
#include "executor/executor.h"
#include "fmgr.h"
#include "miscadmin.h"
#include "tcop/utility.h"
Include dependency graph for test_oat_hooks.c:

Go to the source code of this file.

Functions

static void REGRESS_object_access_hook_str (ObjectAccessType access, Oid classId, const char *objName, int subId, void *arg)
 
static void REGRESS_object_access_hook (ObjectAccessType access, Oid classId, Oid objectId, int subId, void *arg)
 
static bool REGRESS_exec_check_perms (List *rangeTabls, List *rteperminfos, bool do_abort)
 
static void REGRESS_utility_command (PlannedStmt *pstmt, const char *queryString, bool readOnlyTree, ProcessUtilityContext context, ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest, QueryCompletion *qc)
 
static char * accesstype_to_string (ObjectAccessType access, int subId)
 
static char * accesstype_arg_to_string (ObjectAccessType access, void *arg)
 
void _PG_init (void)
 
static void emit_audit_message (const char *type, const char *hook, char *action, char *objName)
 
static void audit_attempt (const char *hook, char *action, char *objName)
 
static void audit_success (const char *hook, char *action, char *objName)
 
static void audit_failure (const char *hook, char *action, char *objName)
 

Variables

 PG_MODULE_MAGIC
 
static bool REGRESS_deny_set_variable = false
 
static bool REGRESS_deny_alter_system = false
 
static bool REGRESS_deny_object_access = false
 
static bool REGRESS_deny_exec_perms = false
 
static bool REGRESS_deny_utility_commands = false
 
static bool REGRESS_audit = false
 
static bool REGRESS_userset_variable1 = false
 
static bool REGRESS_userset_variable2 = false
 
static bool REGRESS_suset_variable1 = false
 
static bool REGRESS_suset_variable2 = false
 
static object_access_hook_type next_object_access_hook = NULL
 
static object_access_hook_type_str next_object_access_hook_str = NULL
 
static ExecutorCheckPerms_hook_type next_exec_check_perms_hook = NULL
 
static ProcessUtility_hook_type next_ProcessUtility_hook = NULL
 

Function Documentation

◆ _PG_init()

void _PG_init ( void  )

Definition at line 75 of file test_oat_hooks.c.

76 {
77  /*
78  * test_oat_hooks.deny_set_variable = (on|off)
79  */
80  DefineCustomBoolVariable("test_oat_hooks.deny_set_variable",
81  "Deny non-superuser set permissions",
82  NULL,
84  false,
85  PGC_SUSET,
87  NULL,
88  NULL,
89  NULL);
90 
91  /*
92  * test_oat_hooks.deny_alter_system = (on|off)
93  */
94  DefineCustomBoolVariable("test_oat_hooks.deny_alter_system",
95  "Deny non-superuser alter system set permissions",
96  NULL,
98  false,
99  PGC_SUSET,
101  NULL,
102  NULL,
103  NULL);
104 
105  /*
106  * test_oat_hooks.deny_object_access = (on|off)
107  */
108  DefineCustomBoolVariable("test_oat_hooks.deny_object_access",
109  "Deny non-superuser object access permissions",
110  NULL,
112  false,
113  PGC_SUSET,
115  NULL,
116  NULL,
117  NULL);
118 
119  /*
120  * test_oat_hooks.deny_exec_perms = (on|off)
121  */
122  DefineCustomBoolVariable("test_oat_hooks.deny_exec_perms",
123  "Deny non-superuser exec permissions",
124  NULL,
126  false,
127  PGC_SUSET,
129  NULL,
130  NULL,
131  NULL);
132 
133  /*
134  * test_oat_hooks.deny_utility_commands = (on|off)
135  */
136  DefineCustomBoolVariable("test_oat_hooks.deny_utility_commands",
137  "Deny non-superuser utility commands",
138  NULL,
140  false,
141  PGC_SUSET,
143  NULL,
144  NULL,
145  NULL);
146 
147  /*
148  * test_oat_hooks.audit = (on|off)
149  */
150  DefineCustomBoolVariable("test_oat_hooks.audit",
151  "Turn on/off debug audit messages",
152  NULL,
153  &REGRESS_audit,
154  false,
155  PGC_SUSET,
157  NULL,
158  NULL,
159  NULL);
160 
161  /*
162  * test_oat_hooks.user_var{1,2} = (on|off)
163  */
164  DefineCustomBoolVariable("test_oat_hooks.user_var1",
165  "Dummy parameter settable by public",
166  NULL,
168  false,
169  PGC_USERSET,
171  NULL,
172  NULL,
173  NULL);
174 
175  DefineCustomBoolVariable("test_oat_hooks.user_var2",
176  "Dummy parameter settable by public",
177  NULL,
179  false,
180  PGC_USERSET,
182  NULL,
183  NULL,
184  NULL);
185 
186  /*
187  * test_oat_hooks.super_var{1,2} = (on|off)
188  */
189  DefineCustomBoolVariable("test_oat_hooks.super_var1",
190  "Dummy parameter settable by superuser",
191  NULL,
193  false,
194  PGC_SUSET,
196  NULL,
197  NULL,
198  NULL);
199 
200  DefineCustomBoolVariable("test_oat_hooks.super_var2",
201  "Dummy parameter settable by superuser",
202  NULL,
204  false,
205  PGC_SUSET,
207  NULL,
208  NULL,
209  NULL);
210 
211  MarkGUCPrefixReserved("test_oat_hooks");
212 
213  /* Object access hook */
216 
217  /* Object access hook str */
220 
221  /* DML permission check */
224 
225  /* ProcessUtility hook */
228 }
ExecutorCheckPerms_hook_type ExecutorCheckPerms_hook
Definition: execMain.c:71
void DefineCustomBoolVariable(const char *name, const char *short_desc, const char *long_desc, bool *valueAddr, bool bootValue, GucContext context, int flags, GucBoolCheckHook check_hook, GucBoolAssignHook assign_hook, GucShowHook show_hook)
Definition: guc.c:5075
void MarkGUCPrefixReserved(const char *className)
Definition: guc.c:5222
@ PGC_SUSET
Definition: guc.h:74
@ PGC_USERSET
Definition: guc.h:75
#define GUC_NOT_IN_SAMPLE
Definition: guc.h:217
object_access_hook_type object_access_hook
Definition: objectaccess.c:22
object_access_hook_type_str object_access_hook_str
Definition: objectaccess.c:23
static bool REGRESS_suset_variable1
static bool REGRESS_deny_exec_perms
static bool REGRESS_deny_object_access
static void REGRESS_utility_command(PlannedStmt *pstmt, const char *queryString, bool readOnlyTree, ProcessUtilityContext context, ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest, QueryCompletion *qc)
static ExecutorCheckPerms_hook_type next_exec_check_perms_hook
static ProcessUtility_hook_type next_ProcessUtility_hook
static bool REGRESS_deny_set_variable
static bool REGRESS_userset_variable2
static bool REGRESS_deny_alter_system
static void REGRESS_object_access_hook(ObjectAccessType access, Oid classId, Oid objectId, int subId, void *arg)
static bool REGRESS_exec_check_perms(List *rangeTabls, List *rteperminfos, bool do_abort)
static bool REGRESS_userset_variable1
static bool REGRESS_deny_utility_commands
static object_access_hook_type next_object_access_hook
static object_access_hook_type_str next_object_access_hook_str
static bool REGRESS_suset_variable2
static void REGRESS_object_access_hook_str(ObjectAccessType access, Oid classId, const char *objName, int subId, void *arg)
static bool REGRESS_audit
ProcessUtility_hook_type ProcessUtility_hook
Definition: utility.c:70

References DefineCustomBoolVariable(), ExecutorCheckPerms_hook, GUC_NOT_IN_SAMPLE, MarkGUCPrefixReserved(), next_exec_check_perms_hook, next_object_access_hook, next_object_access_hook_str, next_ProcessUtility_hook, object_access_hook, object_access_hook_str, PGC_SUSET, PGC_USERSET, ProcessUtility_hook, REGRESS_audit, REGRESS_deny_alter_system, REGRESS_deny_exec_perms, REGRESS_deny_object_access, REGRESS_deny_set_variable, REGRESS_deny_utility_commands, REGRESS_exec_check_perms(), REGRESS_object_access_hook(), REGRESS_object_access_hook_str(), REGRESS_suset_variable1, REGRESS_suset_variable2, REGRESS_userset_variable1, REGRESS_userset_variable2, and REGRESS_utility_command().

◆ accesstype_arg_to_string()

static char * accesstype_arg_to_string ( ObjectAccessType  access,
void *  arg 
)
static

Definition at line 458 of file test_oat_hooks.c.

459 {
460  if (arg == NULL)
461  return pstrdup("extra info null");
462 
463  switch (access)
464  {
465  case OAT_POST_CREATE:
466  {
468 
469  return pstrdup(pc_arg->is_internal ? "internal" : "explicit");
470  }
471  break;
472  case OAT_DROP:
473  {
474  ObjectAccessDrop *drop_arg = (ObjectAccessDrop *) arg;
475 
476  return psprintf("%s%s%s%s%s%s",
477  ((drop_arg->dropflags & PERFORM_DELETION_INTERNAL)
478  ? "internal action," : ""),
480  ? "concurrent drop," : ""),
481  ((drop_arg->dropflags & PERFORM_DELETION_QUIETLY)
482  ? "suppress notices," : ""),
484  ? "keep original object," : ""),
486  ? "keep extensions," : ""),
488  ? "normal concurrent drop," : ""));
489  }
490  break;
491  case OAT_POST_ALTER:
492  {
494 
495  return psprintf("%s %s auxiliary object",
496  (pa_arg->is_internal ? "internal" : "explicit"),
497  (OidIsValid(pa_arg->auxiliary_id) ? "with" : "without"));
498  }
499  break;
501  {
503 
504  return psprintf("%s, %s",
505  (ns_arg->ereport_on_violation ? "report on violation" : "no report on violation"),
506  (ns_arg->result ? "allowed" : "denied"));
507  }
508  break;
509  case OAT_TRUNCATE:
511  /* hook takes no arg. */
512  return pstrdup("unexpected extra info pointer received");
513  default:
514  return pstrdup("cannot parse extra info for unrecognized access type");
515  }
516 
517  return pstrdup("unknown");
518 }
#define OidIsValid(objectId)
Definition: c.h:775
#define PERFORM_DELETION_CONCURRENTLY
Definition: dependency.h:86
#define PERFORM_DELETION_SKIP_EXTENSIONS
Definition: dependency.h:89
#define PERFORM_DELETION_CONCURRENT_LOCK
Definition: dependency.h:90
#define PERFORM_DELETION_QUIETLY
Definition: dependency.h:87
#define PERFORM_DELETION_SKIP_ORIGINAL
Definition: dependency.h:88
#define PERFORM_DELETION_INTERNAL
Definition: dependency.h:85
char * pstrdup(const char *in)
Definition: mcxt.c:1695
@ OAT_NAMESPACE_SEARCH
Definition: objectaccess.h:53
@ OAT_FUNCTION_EXECUTE
Definition: objectaccess.h:54
@ OAT_DROP
Definition: objectaccess.h:51
@ OAT_TRUNCATE
Definition: objectaccess.h:55
@ OAT_POST_ALTER
Definition: objectaccess.h:52
@ OAT_POST_CREATE
Definition: objectaccess.h:50
void * arg
short access
Definition: preproc-type.c:36
char * psprintf(const char *fmt,...)
Definition: psprintf.c:46

References arg, ObjectAccessPostAlter::auxiliary_id, ObjectAccessDrop::dropflags, ObjectAccessNamespaceSearch::ereport_on_violation, ObjectAccessPostCreate::is_internal, ObjectAccessPostAlter::is_internal, OAT_DROP, OAT_FUNCTION_EXECUTE, OAT_NAMESPACE_SEARCH, OAT_POST_ALTER, OAT_POST_CREATE, OAT_TRUNCATE, OidIsValid, PERFORM_DELETION_CONCURRENT_LOCK, PERFORM_DELETION_CONCURRENTLY, PERFORM_DELETION_INTERNAL, PERFORM_DELETION_QUIETLY, PERFORM_DELETION_SKIP_EXTENSIONS, PERFORM_DELETION_SKIP_ORIGINAL, psprintf(), pstrdup(), and ObjectAccessNamespaceSearch::result.

Referenced by REGRESS_object_access_hook().

◆ accesstype_to_string()

static char * accesstype_to_string ( ObjectAccessType  access,
int  subId 
)
static

Definition at line 419 of file test_oat_hooks.c.

420 {
421  const char *type;
422 
423  switch (access)
424  {
425  case OAT_POST_CREATE:
426  type = "create";
427  break;
428  case OAT_DROP:
429  type = "drop";
430  break;
431  case OAT_POST_ALTER:
432  type = "alter";
433  break;
435  type = "namespace search";
436  break;
438  type = "execute";
439  break;
440  case OAT_TRUNCATE:
441  type = "truncate";
442  break;
443  default:
444  type = "UNRECOGNIZED ObjectAccessType";
445  }
446 
447  if ((subId & ACL_SET) && (subId & ACL_ALTER_SYSTEM))
448  return psprintf("%s (subId=0x%x, all privileges)", type, subId);
449  if (subId & ACL_SET)
450  return psprintf("%s (subId=0x%x, set)", type, subId);
451  if (subId & ACL_ALTER_SYSTEM)
452  return psprintf("%s (subId=0x%x, alter system)", type, subId);
453 
454  return psprintf("%s (subId=0x%x)", type, subId);
455 }
#define ACL_SET
Definition: parsenodes.h:88
#define ACL_ALTER_SYSTEM
Definition: parsenodes.h:89
const char * type

References ACL_ALTER_SYSTEM, ACL_SET, OAT_DROP, OAT_FUNCTION_EXECUTE, OAT_NAMESPACE_SEARCH, OAT_POST_ALTER, OAT_POST_CREATE, OAT_TRUNCATE, psprintf(), and type.

Referenced by REGRESS_object_access_hook(), and REGRESS_object_access_hook_str().

◆ audit_attempt()

static void audit_attempt ( const char *  hook,
char *  action,
char *  objName 
)
static

Definition at line 259 of file test_oat_hooks.c.

260 {
261  emit_audit_message("attempting", hook, action, objName);
262 }
static void emit_audit_message(const char *type, const char *hook, char *action, char *objName)

References generate_unaccent_rules::action, and emit_audit_message().

Referenced by REGRESS_exec_check_perms(), REGRESS_object_access_hook(), REGRESS_object_access_hook_str(), and REGRESS_utility_command().

◆ audit_failure()

static void audit_failure ( const char *  hook,
char *  action,
char *  objName 
)
static

Definition at line 271 of file test_oat_hooks.c.

272 {
273  emit_audit_message("denied", hook, action, objName);
274 }

References generate_unaccent_rules::action, and emit_audit_message().

Referenced by REGRESS_exec_check_perms().

◆ audit_success()

static void audit_success ( const char *  hook,
char *  action,
char *  objName 
)
static

◆ emit_audit_message()

static void emit_audit_message ( const char *  type,
const char *  hook,
char *  action,
char *  objName 
)
static

Definition at line 231 of file test_oat_hooks.c.

232 {
233  /*
234  * Ensure that audit messages are not duplicated by only emitting them
235  * from a leader process, not a worker process. This makes the test
236  * results deterministic even if run with debug_parallel_query = regress.
237  */
239  {
240  const char *who = superuser_arg(GetUserId()) ? "superuser" : "non-superuser";
241 
242  if (objName)
243  ereport(NOTICE,
244  (errcode(ERRCODE_INTERNAL_ERROR),
245  errmsg("in %s: %s %s %s [%s]", hook, who, type, action, objName)));
246  else
247  ereport(NOTICE,
248  (errcode(ERRCODE_INTERNAL_ERROR),
249  errmsg("in %s: %s %s %s", hook, who, type, action)));
250  }
251 
252  if (action)
253  pfree(action);
254  if (objName)
255  pfree(objName);
256 }
int errcode(int sqlerrcode)
Definition: elog.c:859
int errmsg(const char *fmt,...)
Definition: elog.c:1072
#define NOTICE
Definition: elog.h:35
#define ereport(elevel,...)
Definition: elog.h:149
#define IsParallelWorker()
Definition: parallel.h:60
void pfree(void *pointer)
Definition: mcxt.c:1520
Oid GetUserId(void)
Definition: miscinit.c:514
bool superuser_arg(Oid roleid)
Definition: superuser.c:56

References generate_unaccent_rules::action, ereport, errcode(), errmsg(), GetUserId(), IsParallelWorker, NOTICE, pfree(), REGRESS_audit, superuser_arg(), and type.

Referenced by audit_attempt(), audit_failure(), and audit_success().

◆ REGRESS_exec_check_perms()

static bool REGRESS_exec_check_perms ( List rangeTabls,
List rteperminfos,
bool  do_abort 
)
static

Definition at line 348 of file test_oat_hooks.c.

349 {
350  bool am_super = superuser_arg(GetUserId());
351  bool allow = true;
352 
353  audit_attempt("executor check perms", pstrdup("execute"), NULL);
354 
355  /* Perform our check */
356  allow = !REGRESS_deny_exec_perms || am_super;
357  if (do_abort && !allow)
358  ereport(ERROR,
359  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
360  errmsg("permission denied: %s", "execute")));
361 
362  /* Forward to next hook in the chain */
364  !(*next_exec_check_perms_hook) (rangeTabls, rteperminfos, do_abort))
365  allow = false;
366 
367  if (allow)
368  audit_success("executor check perms",
369  pstrdup("execute"),
370  NULL);
371  else
372  audit_failure("executor check perms",
373  pstrdup("execute"),
374  NULL);
375 
376  return allow;
377 }
#define ERROR
Definition: elog.h:39
static void audit_attempt(const char *hook, char *action, char *objName)
static void audit_failure(const char *hook, char *action, char *objName)
static void audit_success(const char *hook, char *action, char *objName)

References audit_attempt(), audit_failure(), audit_success(), ereport, errcode(), errmsg(), ERROR, GetUserId(), next_exec_check_perms_hook, pstrdup(), REGRESS_deny_exec_perms, and superuser_arg().

Referenced by _PG_init().

◆ REGRESS_object_access_hook()

static void REGRESS_object_access_hook ( ObjectAccessType  access,
Oid  classId,
Oid  objectId,
int  subId,
void *  arg 
)
static

Definition at line 325 of file test_oat_hooks.c.

326 {
327  audit_attempt("object access",
330 
332  ereport(ERROR,
333  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
334  errmsg("permission denied: %s [%s]",
337 
338  /* Forward to next hook in the chain */
340  (*next_object_access_hook) (access, classId, objectId, subId, arg);
341 
342  audit_success("object access",
345 }
static char * accesstype_arg_to_string(ObjectAccessType access, void *arg)
static char * accesstype_to_string(ObjectAccessType access, int subId)

References accesstype_arg_to_string(), accesstype_to_string(), arg, audit_attempt(), audit_success(), ereport, errcode(), errmsg(), ERROR, GetUserId(), next_object_access_hook, REGRESS_deny_object_access, and superuser_arg().

Referenced by _PG_init().

◆ REGRESS_object_access_hook_str()

static void REGRESS_object_access_hook_str ( ObjectAccessType  access,
Oid  classId,
const char *  objName,
int  subId,
void *  arg 
)
static

Definition at line 277 of file test_oat_hooks.c.

278 {
279  audit_attempt("object_access_hook_str",
281  pstrdup(objName));
282 
284  {
285  (*next_object_access_hook_str) (access, classId, objName, subId, arg);
286  }
287 
288  switch (access)
289  {
290  case OAT_POST_ALTER:
291  if ((subId & ACL_SET) && (subId & ACL_ALTER_SYSTEM))
292  {
294  ereport(ERROR,
295  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
296  errmsg("permission denied: all privileges %s", objName)));
297  }
298  else if (subId & ACL_SET)
299  {
301  ereport(ERROR,
302  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
303  errmsg("permission denied: set %s", objName)));
304  }
305  else if (subId & ACL_ALTER_SYSTEM)
306  {
308  ereport(ERROR,
309  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
310  errmsg("permission denied: alter system set %s", objName)));
311  }
312  else
313  elog(ERROR, "Unknown ParameterAclRelationId subId: %d", subId);
314  break;
315  default:
316  break;
317  }
318 
319  audit_success("object_access_hook_str",
321  pstrdup(objName));
322 }
#define elog(elevel,...)
Definition: elog.h:224

References accesstype_to_string(), ACL_ALTER_SYSTEM, ACL_SET, arg, audit_attempt(), audit_success(), elog, ereport, errcode(), errmsg(), ERROR, GetUserId(), next_object_access_hook_str, OAT_POST_ALTER, pstrdup(), REGRESS_deny_alter_system, REGRESS_deny_set_variable, and superuser_arg().

Referenced by _PG_init().

◆ REGRESS_utility_command()

static void REGRESS_utility_command ( PlannedStmt pstmt,
const char *  queryString,
bool  readOnlyTree,
ProcessUtilityContext  context,
ParamListInfo  params,
QueryEnvironment queryEnv,
DestReceiver dest,
QueryCompletion qc 
)
static

Definition at line 380 of file test_oat_hooks.c.

388 {
389  Node *parsetree = pstmt->utilityStmt;
390  const char *action = GetCommandTagName(CreateCommandTag(parsetree));
391 
392  audit_attempt("process utility",
393  pstrdup(action),
394  NULL);
395 
396  /* Check permissions */
398  ereport(ERROR,
399  (errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
400  errmsg("permission denied: %s", action)));
401 
402  /* Forward to next hook in the chain */
404  (*next_ProcessUtility_hook) (pstmt, queryString, readOnlyTree,
405  context, params, queryEnv,
406  dest, qc);
407  else
408  standard_ProcessUtility(pstmt, queryString, readOnlyTree,
409  context, params, queryEnv,
410  dest, qc);
411 
412  /* We're done */
413  audit_success("process utility",
414  pstrdup(action),
415  NULL);
416 }
const char * GetCommandTagName(CommandTag commandTag)
Definition: cmdtag.c:47
tree context
Definition: radixtree.h:1829
Definition: nodes.h:129
Node * utilityStmt
Definition: plannodes.h:95
void standard_ProcessUtility(PlannedStmt *pstmt, const char *queryString, bool readOnlyTree, ProcessUtilityContext context, ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest, QueryCompletion *qc)
Definition: utility.c:540
CommandTag CreateCommandTag(Node *parsetree)
Definition: utility.c:2359

References generate_unaccent_rules::action, audit_attempt(), audit_success(), context, CreateCommandTag(), generate_unaccent_rules::dest, ereport, errcode(), errmsg(), ERROR, GetCommandTagName(), GetUserId(), next_ProcessUtility_hook, pstrdup(), REGRESS_deny_utility_commands, standard_ProcessUtility(), superuser_arg(), and PlannedStmt::utilityStmt.

Referenced by _PG_init().

Variable Documentation

◆ next_exec_check_perms_hook

ExecutorCheckPerms_hook_type next_exec_check_perms_hook = NULL
static

Definition at line 49 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_exec_check_perms().

◆ next_object_access_hook

object_access_hook_type next_object_access_hook = NULL
static

Definition at line 47 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_object_access_hook().

◆ next_object_access_hook_str

object_access_hook_type_str next_object_access_hook_str = NULL
static

Definition at line 48 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_object_access_hook_str().

◆ next_ProcessUtility_hook

ProcessUtility_hook_type next_ProcessUtility_hook = NULL
static

Definition at line 50 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_utility_command().

◆ PG_MODULE_MAGIC

PG_MODULE_MAGIC

Definition at line 25 of file test_oat_hooks.c.

◆ REGRESS_audit

bool REGRESS_audit = false
static

Definition at line 35 of file test_oat_hooks.c.

Referenced by _PG_init(), and emit_audit_message().

◆ REGRESS_deny_alter_system

bool REGRESS_deny_alter_system = false
static

Definition at line 31 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_object_access_hook_str().

◆ REGRESS_deny_exec_perms

bool REGRESS_deny_exec_perms = false
static

Definition at line 33 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_exec_check_perms().

◆ REGRESS_deny_object_access

bool REGRESS_deny_object_access = false
static

Definition at line 32 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_object_access_hook().

◆ REGRESS_deny_set_variable

bool REGRESS_deny_set_variable = false
static

Definition at line 30 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_object_access_hook_str().

◆ REGRESS_deny_utility_commands

bool REGRESS_deny_utility_commands = false
static

Definition at line 34 of file test_oat_hooks.c.

Referenced by _PG_init(), and REGRESS_utility_command().

◆ REGRESS_suset_variable1

bool REGRESS_suset_variable1 = false
static

Definition at line 43 of file test_oat_hooks.c.

Referenced by _PG_init().

◆ REGRESS_suset_variable2

bool REGRESS_suset_variable2 = false
static

Definition at line 44 of file test_oat_hooks.c.

Referenced by _PG_init().

◆ REGRESS_userset_variable1

bool REGRESS_userset_variable1 = false
static

Definition at line 41 of file test_oat_hooks.c.

Referenced by _PG_init().

◆ REGRESS_userset_variable2

bool REGRESS_userset_variable2 = false
static

Definition at line 42 of file test_oat_hooks.c.

Referenced by _PG_init().