A wormhole attack is a type of attack on the network layer which reflects the issue of routing protocols. The classification is performed with several methods of machine learning consisting of K-Nearest Neighbor (KNN), Support Vector Machine (SVM), Decision Tree (DT), Linear Discrimination Analysis (LDA), Naive Bayes (NB), and Convolutional neural network (CNN). Moreover, for feature extraction, we used the properties of nodes, especially nodes speed in the MANET. We have collected 3997 distinct (normal 3781 and malicious 216) samples that comprise normal and malicious samples. Results of the classification show that the accuracy of KNN, SVM, DT, LDA, NB, and CNN methods are 97.1%, 98.2%, 98.9%, 95.2%, 94.7%, and 96.4%, respectively. Based on our findings, the DT method's accuracy is 98.9% and higher than other methods. In the next priority, SVM, KNN, CNN, LDA, and NB indicate high accuracy, respectively.