only set up tmp ctx if using password