MCPcopy Create free account
hub / github.com/coder/coder / AuditLogConverter

Function AuditLogConverter

coderd/rbac/regosql/configs.go:85–97  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

83}
84
85func AuditLogConverter() *sqltypes.VariableConverter {
86 matcher := sqltypes.NewVariableConverter().RegisterMatcher(
87 resourceIDMatcher(),
88 sqltypes.UUIDVarMatcher("audit_logs.organization_id", []string{"input", "object", "org_owner"}),
89 // Audit logs have no user owner, only owner by an organization.
90 sqltypes.AlwaysFalse(userOwnerMatcher()),
91 )
92 matcher.RegisterMatcher(
93 sqltypes.AlwaysFalse(groupACLMatcher(matcher)),
94 sqltypes.AlwaysFalse(userACLMatcher(matcher)),
95 )
96 return matcher
97}
98
99func ConnectionLogConverter() *sqltypes.VariableConverter {
100 matcher := sqltypes.NewVariableConverter().RegisterMatcher(

Callers 3

TestRegoQueriesFunction · 0.92

Calls 8

NewVariableConverterFunction · 0.92
UUIDVarMatcherFunction · 0.92
AlwaysFalseFunction · 0.92
resourceIDMatcherFunction · 0.85
userOwnerMatcherFunction · 0.85
groupACLMatcherFunction · 0.85
userACLMatcherFunction · 0.85
RegisterMatcherMethod · 0.80

Tested by 1

TestRegoQueriesFunction · 0.74