Fix unlocking when working over ssh