add reset master key function.