write iv into wallet