4

I use Keepass only for unimportant sites and it's set up to autostart with Windows. Entering password every time is quite annoying.

Of course I can use something like recorded macro. But is there any more usable approach?

janot
  • 1,031
  • 2
  • 11
  • 20
  • 1
    Since that totally defeats the purpose of using a password manager, KeePass [will never implement such a feature](https://www.keepassx.org/forum/viewtopic.php?f=1&t=1633). – Vinayak Aug 17 '14 at 08:24
  • @Vinayak, and that's why I'm never going to use KeePass. – user626528 Jan 25 '18 at 01:48

2 Answers2

4

Create shortcut with following command line options:

KeePass.exe "C:\My Documents\MyDatabase.kdb" -pw:password

"C:\My Documents\MyDatabase.kdb" - The database file location is passed as argument. Only one database file is allowed. If the path contains a space, it must be enclosed in quotes (").

-pw:password - Passwords can be passed using the -pw: option. In order to pass 'abc' as password, you would add the following argument to the command line: -pw:abc. Note that there must be no space between the ':' and the password. If your password contains a space, you must enclose it in quotes. For example: -pw:"my secret password".

The -minimize command line argument makes KeePass start up minimized.

source

crazypotato
  • 680
  • 4
  • 11
0

I first create a new entry with my Keepass password with the URL

cmd://"cmd.exe" /k echo Register-ScheduledTask -Action (New-ScheduledTaskAction -Execute '{APPDIR}\Keepass.exe' -Argument '"{DB_NAME}" -pw-enc:{PASSWORD_ENC}' -WorkingDirectory '{DB_DIR}') -Trigger (New-ScheduledTaskTrigger -AtLogon) -TaskName 'KeePass'

That way when I press CtrlU (which opens up the URL it pops up with the command line I need in to execute in PowerShell

Keepass Entry Screen

The Task Scheduler is used instead of shell:startup as there's a limit to the number of characters that may be placed in a Windows Shortcut where PowerShell does not impose any hard limit.

Archimedes Trajano
  • 1,505
  • 1
  • 15
  • 21