Skip to content

Access SecAuditLog in a callback #1458

@rauanmayemir

Description

@rauanmayemir

Summary

Similar to how we can intercept debuglogger and interruptions, it would be great to also be able to interact with auditlog.

Basic example

waf, err = coraza.NewWAF(
	coraza.NewWAFConfig().
		WithDirectives(directive).
		WithDebugLogger(customDebuglogLogger()).
		WithErrorCallback(errorCallback).
		WithAuditlogCallback(auditlogCallback).
		WithRootFS(coreruleset.FS),
)

Motivation

Workloads are running in stateless non-privileged pods with specialized logger infra (e.g elastic ecs formatter), so we can't send auditlog into file or stdout/stderr. We would prefer a callback that lets us re-use our existing logger infra.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions