The present invention discloses a custom feature rule method based on function signatures, which includes statistically analyzing security vulnerabilities of a language to design
programming security feature rules; defining corresponding state transition processes according to the
programming security feature rules, and recording function signatures that cause state transitions to obtain a set of function signatures; designing multiple
finite state automata according to the state transition processes, the set of function signatures, and preset rule meanings; obtaining a set of function signatures for starting each
automaton, monitoring the functions called by variables, and starting the automata according to the functions called by variables and the set of function signatures for starting each
automaton; after the automata are started, tracking the access and propagation paths of variables, using the signatures of the functions called by variables and their references as input strings for the corresponding automata, and obtaining the converted state in combination with the current state and state transition functions of the automata until the automata end or an error occurs. Without mastering the core technology of
static analysis, the feature rule set can be extended.