ttysnoop
The ttysnoop gadget watches the output from a tty or pts device.
Use Cases
This gadget captures the interactive shell activity within your Kubernetes pods, in containers and on the host.
Audit trail
This gadget helps you keep an audit trail of actions performed by
administrators in interactive shells on your Kubernetes clusters. This covers
commands executed using kubectl exec -ti or kubectl run -ti, which allow
direct interaction with pods. Implementing such an audit trail can be
particularly useful for clusters that should otherwise not be tampered with,
or where stricter control over administrator actions is desired.
For more use cases and how this tool can be applied, you can refer to Scribery.
Foundation for Intrusion Detection Systems
While it doesn't directly trigger alerts or manage keyword lists, the collected data can serve as a foundation for building your own intrusion detection systems. You can then integrate this data with other security tools to analyze what's typed or displayed in the pod, enabling you to detect potential intrusions based on your own defined keywords or regular expressions.