Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Encrypting history?
- X-seq: zsh-users 14690
- From: Lloyd Zusman <ljz@xxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Encrypting history?
- Date: Sat, 26 Dec 2009 17:55:26 -0500
- Cache-post-path: purity-of-essence.net!unknown@xxxxxxxx
- Cancel-lock: sha1:JH9KSUVHREnWF2pEqq2bhcxe8XQ=
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- Organization: Take a hippopotamus to lunch today.
- Sender: news <news@xxxxxxxxxxxxx>
I would like my command history to be stored in an encrypted file. I
have read a few messages in this list from 2007 which state that there
isn't a straightforward way to do this within zsh, itself, and the use
of an encrypted file system is suggested.
However, I think that there might indeed be a way to accomplish this.
Is it possible to do the following?
Make sure that SAVEHIST is set to 0.
Then, on login, prompt the user for a password. Remember this password
for the duration of the shell session. Then, use this password along
with a decryption program to read an encrypted history file called, for
example, ~/.ehistory. Put the decrypted contents of this file into the
current shell's history list via the repeated use of the "print -s"
command.
Finally, on logout, pipe the output of "fc -ln 1" through a program
which uses the same password entered at login time to encrypt the
history and write it to the ~/.ehistory file.
Can any of you see any reason for why this would not work?
Or alternatively, is there perhaps a better way to do this within zsh?
Thanks in advance.
--
Lloyd Zusman
ljz@xxxxxxxxxx
God bless you.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author