In the vehicle communications, vehicle-to-vehicle interconnection has extraordinary significance for improving the quality of transportation services and ensuring effective and safe information sharing between vehicles. However in the vehicular Ad hoc networks (VANETs), messages shared between vehicles can be easily spoofed and tampered. How to ensure the authenticity, integrity and non-repudiation of the message is an important issue for VANETs. In order to solve the above problems, a privacy-preserving VANETs sharing system based on attribute-based cryptography is proposed in this paper. In the proposed scheme, the attributes of the vehicles are divided into static attributes and dynamic attributes according to the characteristics of them. And sensitive attribute values that may leak user privacy are hidden to protect user privacy. To achieve the verifiability, integrity, non-repudiation and traceability of the message, a new group signature on the ciphertext is introduced. Additionally, for the calculation limitation of the vehicle terminal, only 6 bilinear pairing operations are needed in the data recovering phase of the scheme. Finally, security analysis and performance evaluations are given to show that the proposed scheme has higher security and efficiency than those in the literature.