Add timeout to unlock dialog and json command