Cryptography and Network Security is a difficult subject to understand, mainly because of the complexity of security protocols and the mathematical rigour required to understand encryption algorithms. Realizing the need for an interactive visualization tool to facilitate the understanding of cryptographic concepts and protocols, several tools had been developed. However, these tools cannot be easily adapted to animate different protocols. The aim of this paper is to propose an interactive visualization tool, called the Cryptographic Protocol Animator (CPAnim). The tool enables a student to specify a protocol and gain knowledge about the impact of its behavior. The protocol is specified by using a scenario-based approach and it is demonstrated as a number of scenes displaying a complete scenario. The effectiveness of this tool was tested using an empirical evaluation method. The results show that this tool was effective in meeting its learning objectives.