Self-propagating mal-packets have become an emergent threat against information confidentiality, integrity, and service availability in wireless sensor networks. While playing an important role for people to interact with surrounding environment, wireless sensor networks suffer from growing security concerns posed by mal-packets because of sensor networks’ low physical security, lack of resilience and robustness of underlying operating systems, and the ever-increasing complexity of deployed applications. In this paper, we study the propagation of mal-packets in 802.15.4 based wireless sensor networks. Based on our proposed mal-packet self-propagation models, we use TOSSIM, a simulator for wireless sensor networks, to study their propagation dynamics. We also present a study of the feasibility of mal-packet defense in sensor networks. Specifically, we apply random graph theory and percolation theory to investigate the immunization of highly-connected nodes, i.e., nodes with high degrees of connectivity. Our goal is to partition the network into as many separate pieces as possible, thus preventing or slowing down the mal-packet propagation. We study the percolation thresholds of different network densities and the effectiveness of immunization in terms of connection ratio, remaining link ratio, and distribution of component sizes. We also present an analysis of the distribution of component sizes.