Home page logo
/

basics logo Security Basics mailing list archives

Re: bash_history to track users
From: Sebastian Hans <hanss () in tum de>
Date: Sat, 15 Nov 2003 15:31:35 +0100

Thiago Lima  wrote:

But not too different. The user must still have write access. 
Otherwise, how would the shell write to it? If the shell can 
write to it, so can the user. Anyway, what if the user has 
more than one instance running? .bash_history only has the 
history of one instance. Or tcsh? Or any other shell for that matter?

you could use a special partition that you only store those 'bash logs'
and set it to just allow appends. Files can't be deleted or edited.

Fill up the partition:

$ dd if=/dev/zero bs=1M count=1048576 >>/path/to/bash_history

(Increase count if the partition is greater than 1024G).

Seb
-- 
/~\ The ASCII                          Sebastian Hans
\ / Ribbon Campaign                    hanss () in tum de
 X  Against HTML                         0x5AED1E6D
/ \ Email!           014C 4A54 FED4 C0B5 3E87  427B 6910 AB0A 5AED 1E6D

Attachment: _bin
Description:


  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]
AlienVault