Control flow analysis method of PLC program

Ye ZHANG,Yuliang LU
DOI: https://doi.org/10.11772/j.issn.1001-9081.2017.12.3581
2018-01-01
Abstract:Programmable Logic Controller (PLC) is one of the most important components of industrial control system,which controls varieties of physical equipments and production processes.The faults of PLC control program caused by malicious tempering of attacker and programming errors of internal personnel will seriously threaten equipment safety and personal safety in industrial field.In order to solve this problem,a control flow analysis method of PLC program was proposed.Firstly,the lexical and syntactic structure of source code were analyzed by using flex and bison.Then,the intermediate representation without instruction side effects was generated and optimized by analyzing the Abstract Syntax Tree (AST).Finally,the basic blocks were divided on the basis of intermediate representation,and the control flow graph of the program was constructed by taking basic block as the basic unit.The experimental results show that,the proposed method can restore the control flow structure of PLC program in the form of statement table,and provide the basis for program understanding and security analysis.
What problem does this paper attempt to address?