Software vulnerability detection Fuzzy testing techniques are commonly used in information physical fusion systems.But there are a large number of redundant test samples in Fuzzing technology, and the sample detection anomaly is less effective. Therefore, this paper proposes a Fuzzing sample optimization method for software vulnerability detection. Firstly, the samples that are not accepted by the software in the random sample are filtered out, and the improved dynamic programming algorithm is used to calculate the sample reduced set, and the number of initial samples is reduced. Then track the stain propagation path during the test, use the improved algorithm of Simhash and Hamming distance to solve the similarity of the sample propagation path, and further reduce the sample redundancy by deleting the samples with higher similarity. Finally, the genetic variation of the sample that triggers the abnormality is constructed. New test samples will increase the validity of the sample. It can be seen from the experimental results that compared with the method based on greedy algorithm and based on abnormal distribution orientation, the proposed method effectively reduces the test sample redundancy and improves the validity of the test sample.