In the era of smart cities, Intelligent Transportation System (ITS) are necessary towards the success of smart cars in the modern societies. ITS rely on Vehicular Ad-hoc Networks (VANETs), which enable communication between cars to relay safety messages exchange. However, VANETs can be exposed to the issue of decentralization and high mobility of cars. Therefore, VANETs are vulnerable to a variety of attacks such as black-hole and grey-hole attacks. These attacks have a significantly dangerous influence on the availability of ITS, causing traffic disruption. In this paper, a blockchain-based model is proposed to provide a convenient and secure solution for ITS. Furthermore, it enables decentralized cooperation between cars and mutual trust is created using smart contracts. The experimental evaluation shows that the PDR rates of the proposed protocols achieve good results compared to previous routing protocols. However, the VCBC method gives a high rate of PDR than SCBC reaching 70% because of the high awareness of the sender car.