In the automotive industry, various electronic control systems have been developed and applied to automobiles for safety, comfort and convenience. Due to the different types of data and reliability requirements for communication between these systems, the number of wire harnesses is also increasing. In order to meet the need of ‘reducing the number of harnesses’ and ‘high-speed data communication via a plurality of LAN', CAN communication protocol has been developed and become the most widely used in-vehicle network technology. However, CAN is a low-level protocol that does not have any built-in security features. In the context of vehicle’s acceleration development of intelligent and networked, in-vehicle network attack has become the source of automotive information security problems. CAN-bus network’s security analysis has gradually become the focus of the industry. In this paper, an anomaly detector based on Recurrent Neural Networks is proposed to detect CAN-bus attacks. Using Recurrent Neural Network, CAN data can be slightly processed directly into the network, without the need for other technologies. In addition, because they are only trained on normal data, they do not even need to know the specifics of the CAN protocol. Through the analysis of the attacks in the real world, three kinds of CAN bus simulation attacks with realistic physical meaning are proposed, and the detection effects of the anomaly detectors are respectively tested. In the past, related studies all separately examined the data sequences of independent ID. In this paper, data dependencies among IDs are used to obtain better overall performance by detecting all IDs at the same time.