This study aims to perform a thorough systematic review investigating and synthesizing existing research on defense strategies and methodologies in adversarial attacks using machine learning (ML) and deep learning methods. A methodology was conducted to guarantee a thorough literature analysis of the studies using sources such as ScienceDirect, Scopus, IEEE Xplore, and Web of Science. A question was shaped to retrieve articles published from 2019 to April 2024, which ultimately produced a total of 704 papers. A rigorous screening, deduplication, and matching of the inclusion and exclusion criteria were followed, and hence 42 studies were included in the quantitative synthesis. The considered papers were categorized into a coherent and systematic classification including three categories: security enhancement techniques, adversarial attack strategies and defense mechanisms, and innovative security mechanisms and solutions. In this article, we have presented a systematic and comprehensive analysis of earlier studies and opened the door to potential future studies by discussing in depth four challenges and motivations of adversarial attacks, while three recommendations have been discussed. A systematic science mapping analysis was also performed to reorganize and summarize the results of studies to address the issues of trustworthiness. Moreover, this research covers a large variety of network and cybersecurity applications of defense in adversarial attack subjects, including intrusion detection systems, anomaly detection, ML-based defenses, and cryptographic techniques. The relevant conclusions well demonstrate what have achieved in defense mechanisms against adversarial attacks. In addition, the analysis revealed a few emerging tendencies and deficiencies in the area to be remedied through better and more dependable mitigation methods against advanced persistent threats. The findings of this review have crucial implications for the community of researchers, practitioners, and policy makers in network and cybersecurity using artificial intelligence applications.