Automatic Generation of the C# Code for Security Protocols Verified with Casper/FDR
Chul-Wuk Jeon, Il-Gon Kim, Jin-Young Choi
Dept. of Computer Science and Engineering, Korea University, Seoul, 136-701 KOREA
{cwjeon, igkim, choi}@formal.korea.ac.kr
Abstract
Formal methods technique offer a means of verifying the correctness of the design process used to create the security protocol. Notwithstanding the successful verification of the design of security protocols, the implementation code for them may contain security flaws, due to the mistakes made by the programmers or bugs in the programming language itself. We propose an ACG-C# tool, which can be used to generate automatically C# implementation code for the security protocol verified with Casper and FDR. The ACG-C# approach has several different features, namely automatic code generation, secure code, and high confidence. We conduct a case study on the Yahalom security protocol, using ACG-C# to generate the C# implementation code.
1 Introduction
With the rapid development of communication networks, the use of security protocols to achieve security goals such as confidentiality, authentication, integrity and nonrepudiation is becoming more and more popular. However, many supposedly inviolable security protocols have been proposed in the literature and even exploited in practice, only to be found to be vulnerable later on. Therefore, various formal methods have been developed to verify the safety of security protocols. These include belief logics such as BAN[1] and various tools such as FDR, Murphi, NRL Analyzer, and Isabelle[2].
Notwithstanding the successful verification of the design of security protocols, the implementation code for them may contain security flaws, due to the mistakes made by the programmers or bugs in the programming language itself. In addition, the process of implementing a security protocol is a tedious and time-consuming task. For example, a flaw pertaining to a buffer overflow attack was found in the OpenSSH code of the SSH protocol[3]. This vulnerability did not concern the security protocol itself, but its imperfect implementation.
Accordingly, research into the generation of the program code automatically from a high-level specification of a security protocol is necessary, in order to reduce such vulnerabilities in the implementation phase. If the design of the security protocol is found to be correct, the use of automated translation guarantees that the behavior of the implementation code corresponds precisely to the formal specification.
In this paper, we propose an ACG-C# tool, which can be used to generate automatically the C# implementation code for security protocols from the high-level specification written in a variation of Casper notation. This ACG-C# tool compiles the specification to produce C# code that is a concrete implementation of the protocol.
The remainder of this paper is organized as follows. Section 2 provides a brief overview of Casper notation. Section 3 introduce the notation, the process of code generation, architecture, API of the ACG-C# tool and the advantages of our approach. Finally, section 4 concludes this paper.
Chul-Wuk Jeon, Il-Gon Kim, Jin-Young Choi
Dept. of Computer Science and Engineering, Korea University, Seoul, 136-701 KOREA
{cwjeon, igkim, choi}@formal.korea.ac.kr
Abstract
Formal methods technique offer a means of verifying the correctness of the design process used to create the security protocol. Notwithstanding the successful verification of the design of security protocols, the implementation code for them may contain security flaws, due to the mistakes made by the programmers or bugs in the programming language itself. We propose an ACG-C# tool, which can be used to generate automatically C# implementation code for the security protocol verified with Casper and FDR. The ACG-C# approach has several different features, namely automatic code generation, secure code, and high confidence. We conduct a case study on the Yahalom security protocol, using ACG-C# to generate the C# implementation code.
1 Introduction
With the rapid development of communication networks, the use of security protocols to achieve security goals such as confidentiality, authentication, integrity and nonrepudiation is becoming more and more popular. However, many supposedly inviolable security protocols have been proposed in the literature and even exploited in practice, only to be found to be vulnerable later on. Therefore, various formal methods have been developed to verify the safety of security protocols. These include belief logics such as BAN[1] and various tools such as FDR, Murphi, NRL Analyzer, and Isabelle[2].
Notwithstanding the successful verification of the design of security protocols, the implementation code for them may contain security flaws, due to the mistakes made by the programmers or bugs in the programming language itself. In addition, the process of implementing a security protocol is a tedious and time-consuming task. For example, a flaw pertaining to a buffer overflow attack was found in the OpenSSH code of the SSH protocol[3]. This vulnerability did not concern the security protocol itself, but its imperfect implementation.
Accordingly, research into the generation of the program code automatically from a high-level specification of a security protocol is necessary, in order to reduce such vulnerabilities in the implementation phase. If the design of the security protocol is found to be correct, the use of automated translation guarantees that the behavior of the implementation code corresponds precisely to the formal specification.
In this paper, we propose an ACG-C# tool, which can be used to generate automatically the C# implementation code for security protocols from the high-level specification written in a variation of Casper notation. This ACG-C# tool compiles the specification to produce C# code that is a concrete implementation of the protocol.
The remainder of this paper is organized as follows. Section 2 provides a brief overview of Casper notation. Section 3 introduce the notation, the process of code generation, architecture, API of the ACG-C# tool and the advantages of our approach. Finally, section 4 concludes this paper.