Host-based intrusion-prevention system