Fix performance problem in server anti-hack.