第47章 Configuring session recording by using the CLI


Learn how to configure user terminal session recordings using the System Security Services Daemon (SSSD), and how to manage and play back these recordings using the tlog command-line utility.

47.1. Session recording overview and components

Session recording captures and saves a user’s terminal activity. This provides a detailed, unchangeable record of all commands, output, and error messages, which you can use for auditing, troubleshooting, and investigating a security incident.

SSSD enforces the recording policies you define, and the tlog utility handles the actual recording and playback.

Components of the session recording
  • tlog utility

    The tlog utility provides tools for recording and playing back terminal I/O. tlog-rec-session functions as an intermediary login shell and captures all data between the user’s terminal and shell. All tlog recordings are in JSON format. You can play back recorded sessions using tlog-play. Note that by default, terminal input recording is disabled for security reasons. For detailed configuration options, see the /etc/tlog/tlog-rec-session.conf file and the tlog-rec-session.conf(5) man page on your system.

  • SSSD

    SSSD provides a set of daemons that manage access to remote directories and authentication mechanisms. When you configure session recording, SSSD overlays the user’s default shell with the tlog-rec-session program.

Limitations of session recording
  • You can configure session recording for the root user, but the root user has the privileges to disable or bypass the recording process, which makes the session recording unreliable for auditing purposes.
  • Terminal sessions in a GNOME graphical session are not recorded. This is because all terminals within a graphical session share a single audit session ID, which prevents tlog from distinguishing between them and capturing recordings correctly.
  • A logging loop can occur when viewing the journal. When a recorded user views the system journal or /var/log/messages, it generates new logs, which are then recorded and displayed, causing a loop of flooded output.

    To prevent the logging loop, view the journal in real time and filter out the log entries which create the loop:

    journalctl -f | grep -v 'tlog-rec-session'

    You can also configure tlog to limit the output. For details, see tlog-rec-session.conf man pages.

  • You must configure session recording on the target host for remote execution. For example, if you want to record a user’s session when they use ssh to connect to a remote system, configure the recording on the remote system they connect to.
  • All recordings are lost on reboot if systemd-journald service uses its default configuration to store the journal in-memory.
Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

Red Hat ドキュメントについて

Red Hat をお使いのお客様が、信頼できるコンテンツが含まれている製品やサービスを活用することで、イノベーションを行い、目標を達成できるようにします。 最新の更新を見る.

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

Theme

© 2026 Red Hat
トップに戻る