Re: deleting login history after logging out

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Paul Howarth wrote:
> Oliver Leitner wrote:
> 
>> Ankush Grover wrote:
>>
>>> Please tell me how to delete the user's bash history file after he or
>>> she logs out.
>>> I tried this /etc/skel/bash_logout
>>>
>>> rm -f $HOME/bash_history
>>>
>>> But it is not working.
>>>
>>> Can anyone tell me how to do this .I want to do it for every user.
>>
>>
>>
>> Dear Ankush
>>
>> the easiest way would be a cronjob, that does a history -c every 5
>> minutes or so.
>>
>> on a wider approach you might wanna try to make your own daemon, that
>> does the job.
>>
>> i hope that helps you further
> 
> 
> Wouldn't a better method be to prevent the creation of the history file
> in the first place?
> 
> One way to do this might be:
> 
> # echo "unset HISTFILE" > /etc/profile.d/nohistfile.sh
> # chmod 755 /etc/profile.d/nohistfile.sh
> 
> I haven't tried this but it *should* work.
> 
> Paul.
> 

hello paul

indeed, if he doesnt need the history file at all, that would be the
best way.

ive seen that commands being used with some backdoors btw...;)

Greetings
Oliver Leitner
Technical Staff
http://www.shells.at
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iD8DBQFCv9y0xHPquN24yVsRAhPWAKC4fEp75fxlakSM268txCcjJC9ZOACgyQok
PNFRJboUpnGnGRIACzSjDJo=
=Dub+
-----END PGP SIGNATURE-----


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux