IBM/ttyspy

Name: ttyspy

Owner: International Business Machines

Description: secure terminal logging

Created: 2017-06-20 02:10:29.0

Updated: 2018-03-24 17:37:45.0

Pushed: 2018-02-05 12:29:28.0

Homepage:

Size: 89

Language: C

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

ttyspy

Originally written by Dustin Lundquist to provide secure terminal sessions for SSH Bastion servers at Blue Box. It is primarily used inside Cuttle where it helps provide a secure SRE platform for operating distributed systems in the DataCenter or in the Cloud.

Terminal sessions may include cryptographic secrets, personally identifiable information, or other information which should not be disclosed.

The client ttyspy acts like the script(1) command, except rather than writing a local file it sends the terminal session to (presumably secure) terminal session archive server. To protect the contents of the terminal session and ensure the session is sent to the correct server, TLS with mutual certificate validation is used to authenticate both the client and server.

See the extended documentation for detailed information about the architecture and configuration.

Client

The client functions as script(1) with the typescript output file piped to curl(1). Originally it was going to be implemented by wrapping these two utilities using a named pipe between the two, but the non-deterministic order in which these utilities would open the pipe prevented this method.

Dependencies
Building
lient
reconf --install
nfigure

Server

The server is a simple Go webserver which authenticates client connections by the client's certificate and saves HTTP POSTs to /transcript path. The server expects a content-type of application/typescript, and X-Username, X-Hostname, X-Gecos headers to be present. Additionally if the X-Ssh-Client header is present it is preserved in the transcript file. Each transcript is saved into a directory structure by username, hostname, year, month and day. This allows archiving of old transcripts.

Building
rc/session_receiver
uild

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.