LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 06-06-2003, 05:30 AM   #1
iceman47
Senior Member
 
Registered: Oct 2002
Location: Belgium
Distribution: Debian, Free/OpenBSD
Posts: 1,123

Rep: Reputation: 47
.bash_history question


I recently noticed that the history is written to .bash_history after you logout , is this normal in terms of security?
I can imagine that it's handy to stop crackers from erasing their history at the time they're logged in, but it's annying at times if I want to erase my root passwd when I forgot to enter 'su' . Happens a lot to me at night lol.
 
Old 06-06-2003, 10:53 AM   #2
iceman47
Senior Member
 
Registered: Oct 2002
Location: Belgium
Distribution: Debian, Free/OpenBSD
Posts: 1,123

Original Poster
Rep: Reputation: 47
To make my confusion even bigger, ~/.bash_history isn't even listed in the bash manpage.

edit: I see now, sorry.
My bad, should've though further than this

Last edited by iceman47; 06-06-2003 at 11:00 AM.
 
Old 06-06-2003, 11:15 AM   #3
Neomaster
Member
 
Registered: May 2003
Location: Digital world
Posts: 113

Rep: Reputation: 15
try this ln -s /dev/null ~ ./bash_history i not to sure if this work on red hat 8.0
 
Old 06-06-2003, 11:25 AM   #4
iceman47
Senior Member
 
Registered: Oct 2002
Location: Belgium
Distribution: Debian, Free/OpenBSD
Posts: 1,123

Original Poster
Rep: Reputation: 47
I wasn't looking to turn it off, nor bypass it.
I was just curious if that was some other program's doing as I never noticed that before.
History is actually very usefull imo.
 
Old 06-06-2003, 04:29 PM   #5
0x4B
Member
 
Registered: May 2003
Location: Nashville TN, USA
Distribution: Debian (I'm unstable)
Posts: 117

Rep: Reputation: 15
if you look in the builtins section of bash manual (or the bash-builtins manual) there are a few options for history. history -d <offset> delete the history position at offset. you can also force a history file write out (or read)

the history is writen at logout because you could have multiple shells open at the same time and they would confuse a file quite a bit if they all accessed it together. plus, its more efficient.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
.bash_history question stakhous Linux - Newbie 1 05-24-2005 06:24 PM
.bash_history t3gah Linux - Software 2 05-05-2005 03:45 AM
bash_history linj Linux - Software 6 08-08-2003 10:13 AM
.bash_history gone togeno Linux - Security 3 06-30-2003 07:10 AM
Question about ".bash_history" yuzuohong Linux - General 2 09-17-2002 06:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 02:02 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration