Add timeout to avoid DoS attack.
Add timeout to avoid DoS attack.