9

I'm using KeePass (on Windows 7) for storing passwords. The application is running on my laptop almost 100% of the time, but I'm using it rarely.

The problem is, that activating the window after long time takes huge amount of time, I'd say that OS realized the application is no longer used and swapped it.

I don't want OS to swap my KeePass (because of the loading lag, and also because of security - I don't like the idea of password keeping program's memory to be stored anywhere on HDD).

Is there any possibility how to tell OS not to swap some program? Or, is this achievable by some programming?

Sathyajith Bhat
  • 61,504
  • 38
  • 179
  • 264
nothrow
  • 255
  • 1
  • 3
  • 11
  • 4
    KeePass does not store unencrypted passwords in memory. So any swapping should not pose a security risk. http://keepass.info/help/base/security.html#secmemprot – Oliver Salzburg Nov 29 '12 at 18:22
  • 1
    And, one sure way to disable paging (Windows does not perform swapping) is to disable the paging file altogether. :) – Oliver Salzburg Nov 29 '12 at 18:24
  • 3
    Also from the page @OliverSalzburg linked to: "KeePass ≥ 1.15 and 2.x use the Windows DPAPI for in-memory encrypting the sensitive data. With DPAPI, the key for in-memory encryption is stored in a **secure, non-swappable memory area** managed by Windows." So even the key is never saved to disk with that option enabled (which it is by default). – Karan Nov 29 '12 at 18:25
  • Thanks guys, I thought so, but I was not so sure. However, loading lag is still bugging me, the computer doesn't have enough memory to keep everything in it :( – nothrow Nov 29 '12 at 20:18
  • make sure Superfetch service is running. The fixes the issue you have. – magicandre1981 Dec 06 '12 at 21:25
  • Keepass archives can be configured upon creation to require a very large number of transformations upon entry of a password before the data is decrypted. If your keepass workspace is locking and requiring re-entry of the password when you restore it, the delay you are experiencing might simply be an intentionally-long decryption process. Have you tried using a different keepass file (Security tab under Datbase Settings when creating a new workspace defines the decryption delay)? – Fopedush Dec 06 '12 at 23:00
  • @Fopedush, no, the delay is caused by OS. It is clearly visible, that it takes ~20-30 seconds before the dialog for entering password even shows (I've got slow laptop). Also, in Resource Monitor there is peak in I/O operations during this lag. – nothrow Dec 07 '12 at 13:42
  • For what it’s worth, I for one understand exactly what you mean Yossarian. Obviously the other people either have not experienced it, or have not noticed it. I too would love to find a way to prevent a program (a specific instance of `cmd.exe` in my case) from being swapped so that I can switch to it instantly, even when the system is bogged down with swapping and CPU load. Unfortunately, I can’t imagine such a mechanism would exist since it could easily be abused by malware. `:-(` – Synetech Nov 25 '15 at 17:09

1 Answers1

1

There are plenty of people who will tell you that it's a bad idea to disable swap/pagefile.

If you decide it is something you wish to do, however, you can:

  • Right-click Computer
    • Click Properties
  • Click Advanced System Settings
    • Click Advanced tab
  • Click Performance
    • Click Advanced tab
    • Click Virtual Memory - Change

Here, you can make changes to where and how much pagefile you are using. I'm pretty sure everybody will agree that moving your pagefile off of your SSD and putting it onto a HDD would be a good idea, but completely disabling it could cause problems.

earthmeLon
  • 331
  • 3
  • 13
  • 1
    This isn't something I want to do, as I want disabling swapping just for one process. I'd say that disabling pagefile at all is bad idea too :-) – nothrow Dec 04 '12 at 13:48
  • Sorry, I'm being told by multiple sources that it's an all or nothing type situation. Sorry I couldn't be of further help. – earthmeLon Dec 04 '12 at 16:32