Linux: Cleaning up your login tracks

So you’ve logged into a Linux machine but you don’t want anyone to know you were there. Why? Who cares. Here are a couple of things to clean up your tracks.

Once you log in, you’ll notice that message that tells you the last time and location you logged in from. To get rid of that, we need to clear out /var/log/wtmp and /var/log/lastlog. We can do that easily with cat > /var/log/wtmp and cat > /var/log/lastlog

To clear out the command history, execute history -c

Hope that helps!

This entry was posted in Linux, Security. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">