ifosch / keepass-mode Goto Github PK
View Code? Open in Web Editor NEWEmacs mode to open KeePass DB
Home Page: https://github.com/ifosch/keepass-mode
License: GNU General Public License v3.0
Emacs mode to open KeePass DB
Home Page: https://github.com/ifosch/keepass-mode
License: GNU General Public License v3.0
After installing the latest version of keepassxc (for me, that is 2.7.0-1ppa3~focal1), this package is no longer able ot list all the entries in the database.
hello,
I installed keepass-mode
on windows 10 (native emacs 28.0.50 through mingw64) along keepassxc
2.6.4
When I open a keepass file I get the message :
'egrep' n'est pas reconnu en tant que commande interne
ou externe, un programme exécutable ou un fichier de commandes.
It is in french, it says that the egrep
command is not recognized as a internal or external command.
This is strange because I do have egrep
installed with mingw64.
I suspect the trouble is here in the code :
(defun keepass-mode-command (group command)
"Generate KeePass COMMAND to run, on GROUP."
(format "echo %s | \
keepassxc-cli %s %s %s 2>&1 | \
egrep -v '[Insert|Enter] password to unlock %s'"
(shell-quote-argument keepass-mode-password)
command
keepass-mode-db
group
keepass-mode-db))
It seems that a pipe is used between keepass-cli
and egrep
command.
I may be wrong but this relies on a linux shell which is not available when using native emacs on windows 10.
Would it be possible to make keepass-mode
more portable towards windows 10 ? I am ready to test any commits if helpful to you
Regards
kdbx
can be opened, groups are displayed.
But upon pressing enter
we stay on the same page. No entries are seen.
I'm on emacs version 28.0.50, that probably is a big factor.
When trying to open a group that contains keys or subgroups with special characters in their names (e.g. '&', 'ü', 'ß'), keepass-mode shows the error message "Cannot display group xxx".
This error message disappears when the special characters are removed, keepass-mode can then open the group.
Using keepass-mode-20210110.630 from MELPA.
Thank you very much for the otherwise excellent tool!
Hello,
I have been recently thinking about using Keepass within Emacs via auth-source (like what has been done for pass here: https://github.com/DamienCassou/auth-password-store). I wasn't able to find packages implementing it.
Is adding support for auth-source in your package something that you would consider ?
I think it would greatly complement it by allowing to use the entries in Emacs directly.
Thanks in advance for your answer !
Hitting c
results in this error:
menu-bar-update-yank-menu: Wrong type argument: stringp, nil
(format "echo %s | \
keepassxc-cli %s %s %s 2>&1 | \
egrep -v '[Insert|Enter] password to unlock %s'"
(shell-quote-argument keepass-mode-password)
It's pretty easy to read command line arguments on Linux so this method of passing the password leaks the keyring password to anything running on the host in question.
As a test I did this:
(shell-command-to-string "echo foo | ps aux")
user 356548 0.0 0.0 6968 3184 ? Ss 10:41 0:00 /bin/bash -c echo foo | ps aux
user 356550 0.0 0.0 10084 3288 ? R 10:41 0:00 ps aux
I don't know how to solve this in emacs lisp but ideally the password should be pushed to keepassxc-cli's standard in directly from emacs over a pipe.
(Environment variables also show up in /proc and so aren't the best method of IPC either.)
Hi,
first of all, thanks for your efforts! I think usability would be greatly improved if one could search the database to find a specific entry. As my brain is not compatible with (e)lisp I'm afraid I cannot contribute though...
Cheers,
Thomas
I'm on evil-mode (Spacemacs), so using this is rather awkward in terms of keybindings. Before I realized it I thought it's bug #9.
To improve UX I added this in my personal config to turn on evil-state for the buffer.
(add-hook 'keepass-mode-hook (lambda ()
(evil-evilified-state)))
I raise it here to see if it resonate with others. If there's enough of you with this problem we can consider building in evil-friendly behavior.
When keybindings grow we need a way to bring up functions that are available.
The suggestion is to have the same UX as magit.
On pressing c
for keepass-mode-copy-password
on a key entry, I get 'PROTECTED' in my kill ring, instead of the actual password.
Keepass-mode version(melpa): 20200216.723
Emacs version:
GNU Emacs 28.0.50 (build 1, x86_64-apple-darwin19.5.0, NS appkit-1894.50 Version 10.15.5 (Build 19F101)) of 2020-07-24
More keybindings:
b
to copy user nameu
to copy URLThese keys are mapped similar in GUI client. They are frequently used (at least I do). Without a keybindings I have go into the entries and copy them with a lot of keystrokes.
Meantime as keybindings grow, there should be a better way to display instructions. I propose these be displayed either on top or bottom of the buffer.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.