ellama icon indicating copy to clipboard operation
ellama copied to clipboard

Provider API key saved in session files in the clear

Open oatmealm opened this issue 1 year ago • 3 comments

I've noticed the session key is saved in the clear with the session data... might need to be taken care of? Not a priority as far as I'm concerned and these files are not supposed to be shared I guess... I also think I would make users aware of ellama-sessions-directory ... it's a wonderful feature and I changed it, so these records are in my org directory and are searchable...

oatmealm avatar Apr 02 '24 06:04 oatmealm

I should think about it.

Probable solution: add ability to save session files in separate directory (like autosave files).

Another probable solution: encrypt/decrypt keys during save/load. But it will make things complicated. Not sure if I want to do it.

s-kostyaev avatar Apr 02 '24 07:04 s-kostyaev

Emacs has builtin gpg-support. I wonder if it would "just work" if ellama supported saving with extension .gpg? I recall there was a gitlab package for Emacs that used that approach for storing credentials.

eras avatar Apr 07 '24 07:04 eras

Emacs has builtin gpg-support. I wonder if it would "just work" if ellama supported saving with extension .gpg? I recall there was a gitlab package for Emacs that used that approach for storing credentials.

In interactive mode at least, simply opening a file with the extension .gpg seems to activate encryption/decryption (in Doom Emacs AFAIK).

oatmealm avatar Apr 07 '24 11:04 oatmealm