Modified test_replay_attack.py, util_test_tools.py and test_util_test_tools.py.