AI Gateway is now available: identity-aware access to any AI provider, eliminate API keys, and tunnel to self-hosted models. Get started

Logs & Analytics

SSH Session Logs

SSH session logs record each SSH session to your resources and the commands run in it

SSH session logs record each SSH session opened to your SSH resources: who connected, to which resource and site, as which system user, and for how long. Each session also includes a transcript of the commands run during it.

SSH session logs are only available in Pangolin Cloud or self-hosted Enterprise Edition.

SSH session logs are only recorded for resources that use Pangolin SSH mode. In this mode the Pangolin Site handles the SSH session itself, so it can record the session and its commands. Sessions to resources in Standard SSH Server mode are passed through to your SSH server and aren't logged here. Use your SSH server's own logging for those.

What are SSH Session Logs?

SSH session logs cover both public SSH resources opened in the browser and private SSH resources reached with the Pangolin client. They are useful for:

  • Auditing who accessed which servers and when
  • Reviewing the commands run during a session for incident response or compliance
  • Tracing a session back to the Pangolin user and client that opened it
  • Seeing which system users people logged in as

The Pangolin Site sends session logs to Pangolin in batches, so expect a short delay before entries appear in the table.

Set SSH Session Log Retention in the org security settings. The default is 0 days, which leaves logging off.

Enable Retention

In your organization's security settings, set SSH Session Log Retention to how long Pangolin should keep SSH session and command logs. Logging starts only after the value is greater than zero. Older entries are deleted once they pass the retention period.

Viewing Sessions

Open Logs & Analytics > SSH Session Logs in your organization. Each row shows the session start time, connection type, resource, site, system user, Pangolin user, client, number of commands, and duration.

Expand a row to see the session details and the command transcript. Commands are listed in the order they ran, with a timestamp for each.

Command Accuracy

Pangolin records commands as they're typed. If a command was edited with shell history recall (for example, the up arrow) or tab completion, the recorded text may not exactly match what the shell ran. These commands are marked with a warning icon in the transcript. If a command was recalled from shell history and its text couldn't be captured, it appears as (recalled from shell history).

Individual commands longer than 4,096 characters are truncated. The dashboard shows a limited number of commands per session. Export the logs to see all of them.

Filters

Narrow the table by date range, then filter by:

  • Connection (SSH or Browser)
  • Resource
  • Site
  • System user
  • User
  • Client

SSH Session Log Fields

Each SSH session log entry contains the following fields:

FieldTypeDescription
sessionIdstringUnique identifier for the SSH session
startedAtnumberUnix timestamp (in seconds) when the session started
endedAtnumber | nullUnix timestamp (in seconds) when the session ended, if it has ended
transportstringHow the session connected: ssh (native SSH through the Pangolin client) or browser (browser terminal on a public resource)
resourceIdnumber | nullThe ID of the public resource, for browser sessions
siteResourceIdnumber | nullThe ID of the private resource, for native SSH sessions
siteIdnumberThe ID of the site that handled the session
clientIdnumber | nullThe Pangolin client that opened the session, for native SSH sessions
userIdstring | nullThe Pangolin user who opened the session, when it can be identified
usernamestringThe system user the session logged in as on the host
sourceAddrstringSource address of the session
destAddrstringDestination address of the session
authMethodstring | nullHow the session authenticated to the host
keyFingerprintstring | nullFingerprint of the key used, when key or certificate authentication was used
certKeyIdstring | nullKey ID of the SSH certificate, when a Pangolin-signed certificate was used
commandCountnumberNumber of commands recorded in the session

Each recorded command contains:

FieldTypeDescription
commandstringThe command text
channelstringshell for commands typed in an interactive shell, or exec for commands passed directly to SSH (for example, ssh host 'uptime')
timestampnumberUnix timestamp (in seconds) when the command ran
inexactbooleanWhether the command was edited with history recall or tab completion and may not exactly match what the shell ran

Log Retention

SSH session log retention is controlled by the organization setting. By default, SSH session logs are retained for 0 days (disabled).

Exporting

Logs can be exported into CSV format for external analysis and archival. Logs can be exported from the table view in the Pangolin dashboard or via the Pangolin API. When exporting, you can specify date ranges and filters to narrow down the logs you need. The export has one row per command, so it includes every recorded command for each session.

Was this page helpful?

⌘I

On this page