The invention belongs to the technical field of
network communication protocol security detection, and discloses a power near-field
network communication protocol security detection method and
system, and the method comprises the steps: constructing a state transition rule set based on an extracted power near-field
network communication protocol state set, event set and action set, and generating a protocol standard finite-state
machine; generating a state path sequence set based on a protocol standard finite-state
machine; recording a protocol state according to messages sent and received in an actual protocol interaction process, and obtaining a state change path in real time; comparing the difference between the state path sequence set and the state change path, scoring, and carrying out safety alarm according to the
score; according to the invention,
score and
weight adjustment is carried out based on a consistency feature neural network and depth deterministic strategy gradient
reinforcement learning; and deep path traversal and analysis are carried out on the standard finite-state
machine to generate a high-coverage-rate state change path sequence set, so that the automatic comparison efficiency in the execution process is remarkably improved.