Would it be possible to support TOTP as a mastery password challenge? Not sure if Keepass 2 file format supports such thing.
I would think this could potentially make the Keepass file more resilient against attacks on partially compromised environments.