The Logical Verification of Security Protocols