hook processmasterinput