SOFTHSM-70: Improved DB handling