LOGBOOK

HELP

Quiz Entry - updated: 2026.11.26

What do Cowrie's logs record, and how do you watch what an attacker did in a session?

cowrie.json records events (connections, login attempts with username and password, commands, downloads) as JSON lines; the full interactive session is stored as a binary TTY log that the playlog tool replays like a recording.

Cowrie keeps two kinds of records:

  1. Event log (log/cowrie.json): one JSON object per event, with source IP, session ID, every login attempt with the username and password tried, success or failure, client version, commands entered and file download URLs. It is easy to ship into Elasticsearch or a SIEM. tail -f shows it live during the lab.
  2. TTY logs (tty/<session-id>): a binary recording of each terminal session, keystroke by keystroke, with timing, including typing mistakes and pauses. They are replayed with:
    python3 ~/cowrie/bin/playlog ~/cowrie/tty/<file>
    
    It is like watching over the attacker's shoulder.

The lab's simulated attacker runs id (what privileges do I have?), ifconfig (which network am I in?), tries to send /etc/passwd away with ftp, and leaves a message file. This is the typical opening sequence of real intrusions: orient, check privileges, exfiltrate, persist. The most valuable thing to capture is what attackers try to download next (malware, backdoors, rootkits), because the source host and the files become new indicators to block.

Go deeper:

From Quiz: ISLAB / Network Security Monitoring | Updated: Nov 26, 2026