Fortress machine
Fortress Machine Login
Available via Google Authenticator
Here's a nice article: http://www.osyunwei.com/archives/9045.html
Command audits
This article provides 2 records in the following ways:
The first focus on session recording, can be played, can record vim inside the editing situation.
The second is a record that focuses on the command line.
A. use Termrecord to record and replay terminal sessions on Ubuntu (mostly user-recorded)
Termrecord is an open source tool written in the Python language that can record terminal sessions as a standalone HTML file. Because an HTML-formatted output file is a standalone file, anyone can use a cross-platform web browser to place the recorded terminal session back and forth.
1. Install PIP
sudo apt-get install Python-pip
2, installation Termrecord
sudo pip install Termrecord
3. recording Terminal session with Termrecord
Termrecord-o/path/filename_html# stop Recording, type Exit to exit.
4 . Open the HTML output in a Web browser.
Can be placed in/etc/profile:
if [[$UID-ge 499]]; Then mkdir-p ~/.audit/data exec/usr/bin/termrecord-o ~/.audit/data/${user}-${uid}-${audit_time}.htmlfi
B, a command record on the line.
Export prompt_command= "histtimeformat=\"%y%m%d%h%m%s \ "; auditdate=\$ (date-d today + "%y%m%d%h%m%s"); execdate=\$ (History 1 | awk ' {print \$2} '), if [\ $AUDITDATE-eq \ $EXECDATE];then builtin history 1 >>/var/log/audit . Log fi &>/dev/null "
This article is from the "Cheat One World de blog" blog, please be sure to keep this source http://qiyishi.blog.51cto.com/5731577/1901844
The implementation principle of Linux fortress machine