Secure transmission management method of in-vehicle video stream based on WebRTC
By building a layered security system and introducing zero-knowledge proof and blockchain technology, combined with hybrid encryption and deep reinforcement learning, security threats in in-vehicle video streaming transmission are resolved, full-link security protection and stable transmission are achieved, and the security and real-time performance of in-vehicle video streaming are improved.
Patent Information
- Application Number
- CN202510929448.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-07
- Publication Date
- 2025-09-12
- Estimated Expiration
- 2045-07-07
AI Technical Summary
Traditional in-vehicle video streaming transmission poses security threats and is difficult to ensure the security of V2V and V2I communications. It lacks real-time and security, information encryption is imperfect, and device management lacks real-time monitoring, which affects collaborative driving and remote driving assistance applications.
Build a layered security system, introduce zero-knowledge proof and blockchain technology, combine hybrid encryption and deep reinforcement learning, adopt anti-jitter and bit rate adaptive encrypted transmission solutions, monitor transmission indicators in real time and identify attacks, and manage the entire life cycle of equipment.
It achieves full-link security protection, improves the security and stability of in-vehicle video streams, dynamically responds to changes in security policies, ensures the secure transmission of video streams in complex scenarios, and reduces the risks of eavesdropping, tampering, and unauthorized access.
Smart Images

Figure CN120434052B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of real-time communication technology, and in particular to a method for managing secure transmission of in-vehicle video streams based on WebRTC. Background Art
[0002] The core goal of WebRTC is to implement real-time audio and video communication in the browser without the need for plug-ins. Early technologies focused on audio and video encoding and decoding, network transmission, and security protocols, providing a basic framework for real-time communication. After being included in the standards by the World Wide Web Consortium and the Internet Engineering Task Force, it has gradually become the mainstream technology for real-time communication between browsers. With the development of intelligent in-vehicle systems, the demand for in-vehicle video streaming has shifted from traditional local storage (such as dash cams) to real-time remote transmission (such as remote monitoring and Internet of Vehicles interaction). Early solutions were mostly based on private protocols, but faced problems such as poor cross-platform compatibility and high deployment costs. Since 2015, the industry has begun to explore the application of WebRTC in in-vehicle scenarios, taking advantage of its native browser support and low-latency transmission characteristics to lower the threshold for interaction between in-vehicle video streams and the cloud or terminals.
[0003] Traditional vehicle-to-vehicle video transmission poses security threats, making it difficult to ensure the security of V2V and V2I communications, affecting applications such as collaborative driving; the real-time and security of remote driving assistance are also insufficient; in terms of real-time communication, the delay of in-vehicle video transmission based on WebRTC is large, making it difficult to meet real-time interactive needs such as in-vehicle video conferencing; in terms of information security, in-vehicle videos lack effective encryption during transmission, storage, and access, making them susceptible to theft and tampering, and identity authentication is also imperfect, posing a risk of illegal access; within the scope of the Internet of Things, there is a lack of real-time monitoring of in-vehicle equipment, making it difficult to detect transmission anomalies in a timely manner; there is a lack of full life cycle management of equipment, and it is impossible to scientifically maintain and upgrade equipment based on operating status; these problems restrict the safe, stable, and efficient transmission of in-vehicle video streams. Summary of the Invention
[0004] To achieve the above objectives, the present invention is implemented through the following technical solutions:
[0005] Step 1: Build a layered security system and establish a basic security framework; the layered security system includes the application layer, transport layer, network layer, and physical layer;
[0006] Step 2: Based on the basic security framework, zero-knowledge proof is introduced during the establishment of the WebRTC interactive connection. Access policies are dynamically updated through blockchain, and an authentication access control policy set is output. The authentication access control policy set includes device access, two-way identity authentication rules, and fine-grained access control policies based on blockchain.
[0007] Step 3: Based on the authentication access control policy set, hybrid encryption is used to ensure data security, verify the integrity of the hash tree, and output an improved encryption transmission scheme. The hash tree is verified and combined with LDPC and DRL to perform anti-jitter and code rate adaptation.
[0008] Step 4: Utilize an improved encrypted transmission solution to collect transmission indicators in real time to detect anomalies. Combine LSTM and the isolation forest algorithm to identify attacks, manage the entire device lifecycle, and output security monitoring and device management reports.
[0009] Furthermore, the application layer security is based on the ABAC model, which abstracts the influencing factors of the vehicle scene into an attribute set A to construct a function F(A). According to the business logic design, when F(A) is true, the video stream access right is granted;
[0010] The transport layer introduces a key exchange mechanism based on collision-resistant hash chains on the DTLS / SRTP protocol of WebRTC, and securely exchanges the transport layer keys of the in-vehicle video stream through calculation, encryption and decryption;
[0011] The network layer security, V2X network layer authentication encryption based on identity signcryption scheme;
[0012] The physical layer integrates TEE in the vehicle-mounted device to securely store device keys and verify operations;
[0013] The basic security framework is built, and the security mechanisms of each layer are coordinated through standardized interfaces. Application layer decisions drive transport layer encryption, network layer transmission, physical layer support, and state machine guarantees execution.
[0014] Furthermore, the device access process is as follows:
[0015] During the device access phase, the sender's dynamic token Tsender and the receiver's dynamic token Treceiver are used, combined with the communication key K pre-shared through the Diffie-Hellman key exchange protocol; the hash values of the three are calculated separately and strictly compared with the hash values pre-stored in the system;
[0016] When Tsender, Treceiver, and K all match the corresponding pre-stored values, the connection between the devices is deemed legal and the video stream transmission channel is allowed to be established.
[0017] Furthermore, the process of the two-way identity authentication rule is:
[0018] In the ICE process of WebRTC, the sender uses the homomorphic encryption algorithm to encrypt the identity identifier ID to obtain E(ID), and proves the legal identity to the receiver through the specific zero-knowledge proof protocol HomomorphicZKPprove(E(ID)). The receiver uses the homomorphic encryption feature to verify the proof process without decrypting it through HomomorphicZKPverify(E(ID)). The session is established only when HomomorphicZKPverify(HomomorphicZKPprove(E(ID)))=true.
[0019] Furthermore, the process of the fine-grained access control policy is:
[0020] The access policy is deployed on the blockchain in the form of a smart contract, with a policy version number V. When an update is required, the UpdatePolicy(V) operation is executed through the smart contract. Each device uses the blockchain consensus mechanism to synchronize the latest policy and dynamically adjust the policy based on different driving scenarios.
[0021] Furthermore, the process of hybrid encryption to ensure data security is as follows:
[0022] Video data is encrypted using the AES-256 symmetric encryption algorithm, and the symmetric key is encrypted using a lattice-based cryptographic system. The receiver first decrypts the symmetric key and then restores the video data. At the same time, a time-event dual-driven key update mechanism is introduced. When the key validity period Tvalid or the event count threshold Ethreshold is reached, a variant of the Diffie-Hellman key exchange protocol is used to update the key.
[0023] Furthermore, the process of verifying the integrity of the hash tree is as follows:
[0024] A hash tree-based integrity verification mechanism is introduced; the video data is divided into data blocks b1, b2, …, bn, the hash value hi = Hash (bi) of each data block is calculated, and the root hash value RootHash of the hash tree is constructed layer by layer; the sender transmits the RootHash along with the video data, and the receiver recalculates and constructs the hash tree after receiving it, and compares the consistency of the RootHash; if it is inconsistent, the tampered data block is immediately requested to be retransmitted; if it is consistent, the video data is deemed intact and transmission continues.
[0025] Furthermore, the process of outputting the improved encryption transmission scheme is:
[0026] Low-density parity-check code is used as the FEC coding scheme to encode the original data block D to generate a redundant data block R. The original data and redundant data are encrypted separately using the AESKsym symmetric encryption algorithm. The receiver uses the LDPCdecode algorithm to restore the original information using the encrypted original data and redundant data.
[0027] The model is built based on deep reinforcement learning, with network bandwidth, latency, and packet loss rate as state space parameters and different video encoding bit rates as action space. Based on the reward function R(s,a), the model learns the optimal bit rate selection strategy through extensive training.
[0028] Introduced in STUN / TURN server deployment, identity-based access control lists combined with TCP-TLS as a UDP backup transport mode.
[0029] Furthermore, the process of combining LSTM and isolation forest algorithm to identify attacks is as follows:
[0030] The system collects transmission indicators such as latency T, packet loss rate P, and encryption throughput Q to form a set of metrics. It uses LSTM to learn the characteristics and patterns of time series indicators to capture dynamic trends under normal transmission modes. It also introduces the isolation forest algorithm to identify anomalies that deviate from the normal pattern based on the distribution of indicator data. When an indicator exceeds the preset threshold and is determined to be an attack by the combined use of the two algorithms, an alarm is triggered.
[0031] Furthermore, the process of managing the entire life cycle of the device is as follows:
[0032] Based on historical data and normal indicator ranges, statistical analysis and trend prediction algorithms are used to determine the nature of anomalies, and the root cause is located by combining network topology and device status. Security risk assessments are conducted based on the analysis results, and risk levels are assigned according to the type and severity of the anomaly.
[0033] The WebRTC-based vehicle-mounted video stream secure transmission management method provided by the present invention has the following beneficial effects:
[0034] (1) The present invention adopts a layered design of application layer, transport layer, network layer and physical layer, and each layer adopts differentiated security mechanisms for collaborative protection. Compared with the traditional single encryption scheme, this layered architecture realizes full-link security protection from permission control to physical devices, significantly reducing the risk of vehicle video streams being eavesdropped, tampered with or unauthorized access, building a layered security system, and improving the full-link security of vehicle video streams.
[0035] (2) The present invention combines dynamic authentication with blockchain technology to enhance the reliability of device access and policy management. In the device access phase, an authentication method that integrates dynamic tokens and Diffie-Hellman key exchange is adopted to ensure the legitimacy of two-way identities through triple hash value comparison, effectively preventing replay attacks. In the session establishment phase, homomorphic encryption based on zero-knowledge proof is introduced to complete authentication without leaking sensitive identity information. At the same time, blockchain smart contracts are used to achieve distributed storage and dynamic updates of access policies, ensuring the immutability of policies and synchronization with the entire network. This solves the problems of device identity forgery and policy update delays in traditional vehicle-mounted communications, enabling vehicles to respond to security policy changes in real time in mobile scenarios, thereby improving the system's anti-attack capabilities and management efficiency.
[0036] (3) The present invention takes into account both data security and vehicle network adaptability through hybrid encryption and intelligent transmission optimization; the hybrid encryption scheme combines AES symmetric encryption and lattice cryptography to ensure encryption efficiency while avoiding key leakage; at the transmission optimization level, LDPC forward error correction code is used to resist network packet loss, and the bit rate is dynamically adjusted to adapt to network fluctuations based on DRL deep reinforcement learning, and ACL access control and TCP-TLS backup transmission are used to achieve NAT penetration and transmission continuity; hash tree integrity check is combined with LSTM+isolation forest algorithm to detect data tampering and abnormal attacks in real time, ensuring that video streams can still be transmitted safely and smoothly in complex scenarios such as tunnels and high-speed movement. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 Schematic diagram of the method of the present invention. DETAILED DESCRIPTION
[0038] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0039] Example:
[0040] See also Figure 1 , an embodiment of the present application provides a method for managing secure transmission of in-vehicle video streams based on WebRTC, the method comprising:
[0041] Step 1: Build a layered security system and establish a basic security framework; the layered security system includes the application layer, transport layer, network layer, and physical layer;
[0042] Application-layer security abstracts various factors affecting access rights in the vehicle scenario into an attribute set A. Function F(A) is constructed through Boolean logic, conditional statements, and weight calculations, enabling the system to automatically determine whether to grant access rights based on actual conditions.
[0043] Use a rule engine or scripting language to write F(A) logic; first convert each attribute ai into a variable that the system can recognize, and then write judgment conditions based on security policies; use attribute-based access control and the ABAC model to fully combine the dynamic attributes of the vehicle scene, such as the vehicle's real-time location, specific time, urgency, and other factors to accurately define access policies.
[0044] Assume that the attribute set is A={a1,a2,…,an}, where ai represents different attribute parameters, such as a1 represents vehicle location information, a2 represents time information, etc. The access policy function is F(A), which is designed based on specific business logic and security requirements. For example:
[0045] When the vehicle is in a specific area (a1) and during working hours (a2), the enterprise monitoring platform is allowed to access the in-vehicle video. In an emergency rescue scenario, if the vehicle is at the accident site (satisfying the location attribute) and the current time is the accident period (satisfying the time attribute), and the urgency attribute reaches the set threshold, F(A) will return a true value, and rescue-related equipment and personnel will be able to obtain access to the in-vehicle monitoring video stream.
[0046] Only when F(A) returns a true value is the user or device allowed to obtain access rights to the video stream.
[0047] Returning a true value: When all attribute parameters in attribute set A meet the business logic's predefined conditions, the access policy function F(A) outputs a logical true value (i.e., "allowed"). For example, in an enterprise surveillance scenario, when both the specific area (a1) and the working hours (a2) meet the predefined values, F(A) returns a true value, authorizing access. In an emergency rescue scenario, when the accident location, time, and urgency thresholds are simultaneously met, F(A) evaluates to true, granting access to the video stream.
[0048] Transport layer security, based on WebRTC's DTLS / SRTP protocols, introduces a novel key exchange mechanism based on collision-resistant hash chains. Leveraging the one-way nature and collision resistance of hash functions, this mechanism enhances the security of the key exchange process and protects against common computational attacks. Assume the sender possesses a private key vector s and generates the corresponding public key p through an iterative hash operation, Hashn(s). The receiver possesses a private key vector r and uses a similar process to generate a public key q. The original key K0 is first deeply processed using the hash-based key derivation function HKDF(K0) to further enhance its randomness and security. The sender then uses the receiver's public key q and the processed key information to obtain the encrypted key K using the hash chain encryption algorithm HashChainEncq(HKDF(K0)). After receiving K, the receiver uses its own private key r and the corresponding decryption algorithm HashChainDecr(K), combined with rigorous verification procedures, to successfully recover the key K0 that can be used to encrypt the video stream.
[0049] It should be noted that the security of this hash chain-based cryptographic system is based on the mathematical properties of the hash function. It is difficult for attackers to obtain the original key by reverse calculation or forging the hash value, thereby providing reliable security for the key exchange process and ensuring the safe and reliable transmission of the in-vehicle video stream at the transport layer.
[0050] Network-layer security leverages the unique characteristics of V2X communications to implement authentication and encryption using an identity-based signcryption scheme. The device identity is represented by ID, and the system master key is s. For the message M to be transmitted, a signcryption algorithm generates a ciphertext C = IBSs(ID, M). Upon receiving ciphertext C, the receiver uses the verification algorithm Verify(ID, C) to accurately confirm the message's origin and integrity.
[0051] For example, when a vehicle communicates with a roadside unit, the vehicle device uses its own identity ID and system master key s to signcrypt the sent video-related control information M. After the RSU receives the ciphertext, it uses a verification algorithm to determine whether the message comes from a legitimate vehicle device and has not been tampered with, thereby ensuring the security and reliability of network layer communication.
[0052] At the physical layer, a trusted execution environment (TEE) is integrated into key devices such as in-vehicle cameras, leveraging the secure storage and isolated execution environment provided by the TEE to fully protect device keys and sensitive data. The device key, known as Kdevice, is securely stored in a dedicated secure storage area within the TEE. Access to Kdevice is restricted to operations authenticated by the TEE.
[0053] For example, when an on-board camera performs video data encryption operations, it needs to obtain the device key Kdevice from the secure storage area of the TEE. This acquisition process must undergo TEE identity authentication and operation permission verification. Only legal encryption operations can use the key, effectively preventing key leakage and illegal use, and providing a solid security root of trust for the entire system from the physical layer and device level.
[0054] Basic security framework:
[0055] The security mechanisms at each layer work together through standardized interfaces. Specifically, the application layer makes decisions based on actual business needs and security policies. These decisions are accurately communicated to the transport layer, which then determines the encryption method used by the transport layer and the specific rules for key usage.
[0056] For example, if the application layer determines that the current remote driving scenario is a high-security one and requires stronger encryption, it will send corresponding instructions to the transport layer, which will then select a higher-level encryption algorithm and key management strategy based on the instructions. The encrypted data at the transport layer will be further encapsulated and transmitted through the network layer's security protocol. During the transmission process, the network layer will perform authentication and routing based on information such as the device's identity. Physical layer device security provides a trusted foundation for the upper layer, ensuring the security of device keys and sensitive data, and laying the foundation for the entire security architecture interaction process. The entire interaction process is precisely controlled by a state machine model, which defines the operation and transition rules of each security layer in different states to ensure that security policies can be executed correctly and in an orderly manner.
[0057] For example, when the system detects a change in the network environment, the state machine model will coordinate the security mechanisms at each layer to make corresponding adjustments based on preset rules, such as re-exchanging keys and adjusting encryption strength, to ensure the continuity and stability of secure video stream transmission.
[0058] Step 2: Based on the basic security framework, new identity authentication and access control technologies are introduced during the WebRTC interactive connection establishment process. The authentication access control policy set is output. The authentication access control policy set includes two-way identity authentication rules for device access and session establishment, as well as fine-grained access control policies based on blockchain.
[0059] Device access:
[0060] During the device access phase, an authentication method based on a fusion of dynamic tokens and symmetric encryption keys is used to ensure the security of the transmission link between the sender and receiver. Let the dynamic token generated by the sender be Tsender, and the dynamic token generated by the receiver be Treceiver. The communication key pre-shared by both parties via the Diffie-Hellman key exchange protocol is K. The hash values of the sender's dynamic token, Hash(Tsender), the receiver's dynamic token, and the key, Hash(K), are calculated and rigorously compared with pre-stored values in the system.
[0061] The conditions for passing the certification are:
[0062] Hash(Tsender)=Hashpre-stored(Tsender)∧Hash(Treceiver)=Hashpre-stored(Treceiver)∧Hash(K)=Hashpre-stored(K)Only when the dynamic token hash values of the sender and receiver devices, as well as the communication key hash values, match the pre-stored values, is the connection between devices deemed legal and the video stream transmission channel is allowed to be established.
[0063] For example, in an in-vehicle monitoring system, a transmitting camera device generates a dynamic token, Tsender, and a receiving server device generates Treceiver. Both parties use the Diffie-Hellman key exchange protocol to obtain the communication key, K, and perform a hash calculation. Only when all three hash values match can the camera transmit video data to the server. The Diffie-Hellman key exchange protocol secures key negotiation through asymmetric encryption, while the use of dynamic tokens prevents replay attacks, effectively improving connection security.
[0064] Two-way authentication rules:
[0065] Homomorphic encryption-based identity authentication is introduced in WebRTC's ICE (Interactive Connection Establishment) process. The sender uses a homomorphic encryption algorithm to encrypt its own identity ID, generating encrypted identity information E(ID). This encrypted identity information is then proven to the receiver through a specific zero-knowledge proof protocol, without leaking any original sensitive information. The receiver leverages the properties of homomorphic encryption to verify the proof without decrypting E(ID). Let the proof process be HomomorphicZKPprove(E(ID)) and HomomorphicZKPverify(E(ID)). A session is successfully established only when HomomorphicZKPverify(HomomorphicZKPprove(E(ID))) = true.
[0066] For example, when a vehicle establishes a communication session with a remote driving center, the vehicle, as the sender, first homomorphically encrypts its own identity ID to obtain E(ID). It then uses a zero-knowledge proof protocol to prove its legal identity to the remote driving center. The remote driving center leverages homomorphic encryption to directly verify the encrypted proof without decrypting E(ID). Only after verification can the two parties establish a secure communication session and perform operations such as video streaming. Homomorphic encryption allows computation and verification to be performed directly on ciphertext, protecting identity privacy while improving authentication efficiency and security.
[0067] Fine-grained access control:
[0068] Blockchain technology is used to implement distributed storage and dynamic updates of access policies to meet the complex and ever-changing access control requirements of vehicle scenarios. The access policy is deployed on the blockchain as a smart contract, with the policy version number set to V. When the policy needs to be updated, the smart contract executes the precise update operation UpdatePolicy(V). Each device synchronizes the latest policy through the blockchain's consensus mechanism to ensure consistent and tamper-proof access control. The specific process of deploying the access policy on the blockchain as a smart contract is as follows:
[0069] S201. Determine the access policy content:
[0070] For in-vehicle scenarios, clearly define access control rules for different situations. For example, which devices or organizations can access which in-vehicle data (such as video streams) in various driving scenarios, such as normal driving, emergency avoidance, and maintenance. For example, during normal driving, only authorized monitoring centers can access video streams from the vehicle's external cameras, while during emergencies, rescue agencies can also access specific video stream information. These specific rules are organized into a complete access policy.
[0071] S202. Write smart contract code:
[0072] Based on the determined access policy, write smart contract code using a programming language suitable for the blockchain platform (such as Solidity). This code should define the policy version number V and implement the UpdatePolicy(V) function to update the policy. This function should accurately execute policy updates based on actual needs, such as modifying access permissions in different scenarios.
[0073] S203. Deploy to the blockchain network:
[0074] Deploy the prepared smart contract code to the blockchain network. This requires submitting the smart contract code and related parameters (such as the initial policy version number) to the blockchain network using tools or interfaces provided by the blockchain nodes. Nodes in the blockchain network will verify and record the smart contract through a consensus mechanism (such as the proof-of-stake algorithm mentioned in the document) and add it to the blockchain's distributed ledger. The access policy is now deployed on the blockchain as a smart contract. To update the policy, call the UpdatePolicy(V) function in the smart contract, and all onboard devices will synchronize the latest policy through the consensus mechanism.
[0075] For example, access policies may vary in different driving scenarios, such as normal driving, emergency avoidance, and maintenance. When a scenario requires an access policy update, the system executes the update on the blockchain via a smart contract. Each onboard device then synchronizes the latest policy using a consensus algorithm (such as proof-of-stake), ensuring that all devices adhere to the latest, consistent access control policies. For example, during normal driving, only authorized monitoring centers can access the vehicle's external camera video streams. However, in emergency avoidance scenarios, rescue agencies and other relevant departments can also access specific video streams. These policy updates and synchronization are facilitated through blockchain technology. This enhances the security and uniqueness of identity authentication while providing a more reliable foundation for operations such as encrypted data transmission.
[0076] Output of the authentication access control policy set:
[0077] Based on the ABAC model, the application layer abstracts scene attributes (such as location and time) into functions F(A), which are dynamically updated with blockchain policies. For example, when F(A) is judged as "emergency rescue", the blockchain smart contract is triggered to update access rights.
[0078] The transport layer and network layer execute encryption protocols (such as hybrid encryption and hash tree verification) based on the policy set, and the physical layer TEE ensures the security of the policy execution environment, forming a layered and collaborative security system.
[0079] Step 3: Based on the authentication access control policy set, hybrid encryption is used to ensure data security, the hash tree integrity is verified, and an improved encryption transmission scheme is output. The hash tree integrity verification process combines LDPC and DRL to achieve jitter resistance and bit rate adaptation, and ACL and TCP-TLS ensure transmission continuity.
[0080] Hybrid encryption ensures data security:
[0081] A hybrid encryption scheme combines the advantages of symmetric and asymmetric encryption to achieve a balance between security and efficiency. Video data is encrypted using the high-strength AES-256 symmetric encryption algorithm. Let M be the plaintext video data and Ksym be the symmetric key. The encrypted ciphertext is CAES = AESKsym(M). The symmetric key is encrypted using the lattice-based cryptography introduced in transport layer security, namely Kenc = NTRUE(Ksym). The receiver first decrypts the symmetric key using Ksym = NTRud(Kenc) and then uses Ksym to restore the video data M = AESKsym-1(CAES). This hybrid encryption approach leverages the advantages of symmetric encryption algorithms in data encryption speed and key exchange security. For example, AES-256 is used for fast encryption of large amounts of in-vehicle video data, while the transmission of the symmetric key is securely protected using a lattice-based cryptography to ensure that the key cannot be eavesdropped or tampered with during transmission.
[0082] In key management, a time- and event-driven rekeying mechanism addresses key security risks during long-term communications. Assuming the key validity period is Tvalid and the event trigger threshold is Ethreshold, the rekeying process is automatically triggered when Tvalid is reached or the event count reaches Ethreshold. This rekeying process utilizes a variant of the Diffie-Hellman key exchange protocol to ensure the security of the new key. For example, during the continuous transmission of an in-vehicle video stream, the system automatically initiates a rekeying process after a period of time, Tvalid (e.g., one hour), or when a specific event occurs, such as a vehicle entering a high-security area or a certain number of network handoffs, that is, when the event count reaches Ethreshold. During the rekeying process, the sender and receiver negotiate a new secure key using a variant of the Diffie-Hellman key exchange protocol, without directly transmitting the key. This ensures the security of subsequent video stream encryption.
[0083] Hash tree integrity verification:
[0084] Integrity protection and tamper resistance: The SRTP protocol incorporates a hash tree-based integrity check mechanism to ensure the integrity of video data during transmission. Video data packets are divided into data blocks b1, b2, …, bn. A hash value hi = Hash(bi) is calculated for each data block, and a hash tree is constructed through layer-by-layer hashing. The root hash value is set as RootHash. The receiver verifies the consistency of RootHash to accurately detect data tampering. If tampering is detected, it immediately requests retransmission of the corresponding data block. For example, during in-vehicle video streaming, the sender divides the video data packet into multiple data blocks according to a specific rule, calculates the hash value of each data block, and constructs a hash tree. The root hash value RootHash is transmitted to the receiver along with the video data. After receiving the data, the receiver recalculates the hash value of the data block and constructs the hash tree, comparing it with the received root hash value. If the comparison is inconsistent, it indicates that the data has been tampered with during transmission. The receiver immediately requests the sender to retransmit the tampered data block, thus ensuring the integrity and accuracy of the video data.
[0085] Anti-network jitter and secure transmission strategy:
[0086] Forward error correction combined with encryption:
[0087] Low-density parity-check (FEC) codes are used as the FEC encoding scheme. Let the original data block be D. After encoding, a redundant data block R = LDPCencode(D) is generated. The original data and redundant data are encrypted using CD = AESKsym(D) and CR = AESKsym(R), respectively. The receiver recovers the original data using LDPCdecode(CD, CR), ensuring data security while significantly improving robustness against packet loss. For example, while a vehicle is in motion, network instability may lead to packet loss. Using LDPC encoding, the sender sends both the original video data block D and the redundant data block R, both of which are encrypted. Upon receiving the encrypted data, even if some packets are lost, the receiver can use the original and redundant data blocks to recover the complete original data using the LDPC decoding algorithm, ensuring normal playback of the video stream. At the same time, encryption ensures data security.
[0088] Dynamic Bitrate Adjustment: Deep reinforcement learning (DRL) is used to implement adaptive bitrate control to adapt to complex and changing network environments. A DRL model is constructed with a state space S containing key parameters such as network bandwidth, latency, and packet loss rate. The action space F represents different video encoding bitrates. The reward function R(s,a) is carefully designed based on video quality and transmission performance. Through extensive training, the model learns the optimal policy π(s), achieving dynamic bitrate optimization. For example, when a vehicle moves from an area with strong network signal to one with weak signal, network bandwidth may decrease, while latency and packet loss rate may increase. In this case, the DRL model selects an appropriate video encoding bitrate from the action space F (e.g., reducing the bitrate) based on the parameter changes in the state space S. The reward function R(s,a) is used to evaluate the performance of this selection. Positive rewards are awarded if the selected bitrate maintains acceptable video quality and good transmission performance (e.g., reduced latency and packet loss rate); negative rewards are awarded if the selected bitrate does not. Through continuous training and adjustment, the model gradually learns the optimal bitrate selection strategy for different network conditions, ensuring smooth video streaming in various network environments.
[0089] Secure NAT traversal and firewall traversal: Identity-based access control lists (ACLs) are introduced in STUN / TURN server deployments. Device identities are represented by IDs, and ACL rules are represented by Rule(ID). Only devices that meet Rule(ID) can use STUN / TURN services. Furthermore, TCP-TLS transmission mode is used as a backup to UDP. When UDP transmission is blocked, it automatically switches to TCP-TLS, ensuring the continuity of video streaming. For example, when an in-vehicle device communicates with an external server, the STUN / TURN server first checks whether the device's ID meets the ACL rule Rule(ID). If so, the device can use STUN / TURN services for NAT traversal and other operations. If a firewall or other device in the network blocks UDP transmission, the system automatically detects and switches to TCP-TLS transmission mode to continue video streaming, ensuring stable and continuous video data transmission to the receiving end without disrupting the normal operation of in-vehicle applications.
[0090] Step 4: Utilize an improved encrypted transmission solution to collect transmission metrics in real time and detect anomalies. Combined with the LSTM and Isolation Forest algorithms, identify attacks, manage the entire device lifecycle, and generate security monitoring and device management reports.
[0091] Real-time collection of transmission indicators to detect anomalies:
[0092] In STUN / TURN server deployment, identity-based access control lists are introduced. Device identities are represented by IDs, and ACL rules are represented by Rule(ID). STUN / TURN services are used on devices that meet Rule(ID). Furthermore, TCP-TLS transmission mode is used as a backup for UDP. If UDP transmission is blocked, TCP-TLS is automatically switched to ensure the continuity of video streaming.
[0093] For example, when an in-vehicle device communicates with an external server, the STUN / TURN server first checks the device's ID to see if it satisfies the ACL rule Rule(ID). If so, the device can use the STUN / TURN service for operations such as NAT penetration. If a firewall or other device in the network blocks UDP transmission, the system automatically detects and switches to TCP-TLS transmission mode to continue transmitting the video stream, ensuring that video data reaches the receiving end stably and continuously without affecting the normal operation of in-vehicle applications.
[0094] A real-time monitoring platform based on the Internet of Things (IoT) was constructed to comprehensively collect key metrics of video streaming transmission, including latency T, packet loss rate P, and encrypted throughput Q. The set of monitoring metrics is defined as Metrics = {T, P, Q, …}. Anomalies are detected using a carefully designed real-time data analysis algorithm, Analyze(Metrics). An LSTM network is used to construct a time series prediction model for transmission metrics, generating a residual sequence between predicted and actual values. This residual sequence is then fed into an isolation forest algorithm for outlier detection, generating an anomaly score. Based on a preset scoring threshold, the platform determines the presence of an attack and uses an attention mechanism to locate key anomaly metrics. Finally, a library of attack samples is used for feature matching, identifying the attack type and triggering a tiered response strategy.
[0095] For example, the latency threshold is set to Tthreshold, and the packet loss rate threshold is set to Pthreshold. When the system detects that the latency T exceeds Tthreshold or the packet loss rate P exceeds Pthreshold, the real-time data analysis algorithm Analyze(Metrics) detects the anomaly and triggers an alarm to notify the system administrator or maintenance personnel. The monitoring platform also records the time of the anomaly and related metric data for subsequent follow-up.
[0096] Specifically, in the secure transmission management of in-vehicle video streams based on WebRTC, the LSTM and Isolation Forest algorithms are combined to identify attacks. Transmission metrics are first collected to form a set. LSTM is used to learn the temporal characteristics of these metrics, and a prediction model is constructed to generate a residual sequence between the predicted and actual values. This residual sequence is then input into the Isolation Forest algorithm to detect anomalies and generate an anomaly score. Based on a preset scoring threshold, an attack is determined, and an attention mechanism is used to identify key anomaly indicators. Finally, a database of attack samples is used for feature matching, identifying the attack type and triggering a tiered response strategy. For example, while driving in a tunnel, if the system detects anomalies in latency and packet loss residuals, and the algorithm identifies an attack, it will switch transmission modes and issue an alert. This process works in conjunction with a layered security system, secured by a physical layer TEE. It can also leverage improved encryption transmission schemes and activate LDPC forward error correction codes. It is also integrated with device lifecycle management, with attack events used for device maintenance analysis, enabling real-time detection and intelligent response to in-vehicle video stream transmission attacks.
[0097] By building a real-time monitoring platform based on the Internet of Things, key indicators of video streaming transmission (such as latency T, packet loss rate P, encryption throughput Q, etc., which form a monitoring indicator set Metrics) are collected in real time, and the real-time data analysis algorithm Analyze(Metrics) is used to detect anomalies (when the indicator exceeds the preset threshold, such as T>Tthreshold or P>Pthreshold, an alarm is triggered).
[0098] In-depth analysis of abnormal situations:
[0099] After detecting an anomaly and triggering an alarm, the monitoring platform conducts further in-depth analysis of the abnormal data. Based on historical data and normal indicator ranges, complex statistical analysis and trend prediction algorithms are used to determine whether the anomaly is a sporadic fluctuation or a persistent problem. For example, by comparing indicator data from the same scenario over a period of time, if the latency is abnormally elevated, but similar brief fluctuations have occurred during the same period in the past and subsequently recovered, it may be considered sporadic network jitter. However, if the latency remains above the threshold and shows a trend of gradual deterioration, it warrants further attention.
[0100] Furthermore, by combining multi-dimensional information such as network topology and device operating status, the root cause of the anomaly can be located. For example, if multiple on-board devices in a certain area experience an abnormally high packet loss rate simultaneously, and the network nodes in that area are overloaded, it can be preliminarily determined that the cause is a network node problem.
[0101] Security Risk Assessment:
[0102] Based on the results of anomaly analysis, a quantitative assessment of the security risks of video streaming transmission is conducted. Different types of anomalies (such as transmission delays, packet loss, encryption failures, etc.) are assigned a corresponding risk level (low, medium, or high) based on their severity, duration, and potential impact (such as video freezes affecting driving monitoring and the risk of data leakage). For example, a brief, minor delay may be assessed as low risk, while sustained packet loss involving the loss of key video frames may be assessed as medium risk. Signs of encryption compromise may be assessed as high risk.
[0103] Device Management Recommendations: Based on anomaly analysis and risk assessment results, targeted recommendations are provided for device management. If the anomaly is caused by performance degradation due to aging hardware in an onboard device, a hardware upgrade or replacement is recommended. If the anomaly is due to improper network configuration, such as overly restrictive firewall policies, adjustments to network configuration parameters may be recommended. Furthermore, for devices or transmission links that present security risks, appropriate reinforcement measures are implemented, such as updating encryption algorithms and enhancing identity authentication strength.
[0104] Report Output: The above-mentioned anomaly analysis, risk assessment, and device management recommendations are compiled into a security monitoring and device management report in a standardized format. This report includes details of the anomaly (such as time and indicator changes), risk assessment results (such as risk level and scope of impact), and device management improvement measures and implementation recommendations. This report is available to system administrators, operations personnel, and other relevant personnel, allowing them to promptly understand the security status of video streaming transmission and take effective measures to ensure stable and secure system operation.
[0105] The above embodiments can be implemented in whole or in part by software, hardware, firmware, or any other combination thereof. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. Those skilled in the art will appreciate that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution.
[0106] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, and may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment as needed.
[0107] The above is only a specific implementation method of the present application, but the scope of protection of the present application is not limited thereto. Any technician familiar with this technical field can easily think of changes or replacements within the technical scope disclosed in this application, which should be covered by the scope of protection of the present application.
Claims
1. A WebRTC-based vehicle-mounted video stream secure transmission management method, characterized in that: include: Step 1: Build a layered security system and establish a basic security framework; The layered security system includes the application layer, transport layer, network layer, and physical layer. The application layer security, based on the ABAC model, abstracts the influencing factors of the vehicle scene into an attribute set A to construct a function F(A). Based on the business logic design, when F(A) is true, access to the video stream is granted. The transport layer introduces a key exchange mechanism based on collision-resistant hash chains on the DTLS / SRTP protocol of WebRTC, and securely exchanges the transport layer keys of the in-vehicle video stream through calculation, encryption and decryption; The network layer security, V2X network layer authentication encryption based on identity signcryption scheme; The physical layer integrates TEE in the vehicle-mounted device to securely store device keys and verify operations; The above-mentioned basic security framework is built, and the security mechanisms of each layer are coordinated through standardized interfaces. The application layer decision drives the transport layer encryption, network layer transmission, physical layer support, and the execution is guaranteed by the state machine; Step 2: Based on the basic security framework, zero-knowledge proof is introduced during the establishment of the WebRTC interactive connection. Access policies are dynamically updated through blockchain, and an authentication access control policy set is output. The authentication access control policy set includes device access, two-way identity authentication rules, and fine-grained access control policies based on blockchain. Step 3: Based on the authentication access control policy set, hybrid encryption is used to ensure data security, verify the integrity of the hash tree, and output an improved encryption transmission scheme. The hash tree is verified and combined with LDPC and DRL to perform anti-jitter and code rate adaptation. Step 4: Utilize an improved encrypted transmission solution to collect transmission indicators in real time to detect anomalies. Combine LSTM with the isolation forest algorithm to identify attacks, manage the entire life cycle of the device, and output security monitoring and device management reports. The process of managing the entire life cycle of the device is as follows: Based on historical data and normal indicator ranges, use statistical analysis and trend prediction algorithms to determine the nature of the anomaly, and locate the root cause by combining network topology and device status; conduct a security risk assessment based on the analysis results, and assign a risk level according to the type and severity of the anomaly.
2. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 1, characterized in that: The device access process is as follows: During the device access phase, the sender's dynamic token Tsender and the receiver's dynamic token Treceiver are used, combined with the communication key K pre-shared through the Diffie-Hellman key exchange protocol; the hash values of the three are calculated separately and strictly compared with the hash values pre-stored in the system; When Tsender, Treceiver, and K all match the corresponding pre-stored values, the connection between the devices is deemed legal and the video stream transmission channel is allowed to be established.
3. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 1, characterized in that: The process of the two-way identity authentication rule is: In the ICE process of WebRTC, the sender uses the homomorphic encryption algorithm to encrypt the identity identifier ID to obtain E(ID), and proves the legal identity to the receiver through the specific zero-knowledge proof protocol HomomorphicZKPprove(E(ID)). The receiver uses the homomorphic encryption feature to verify the proof process without decrypting it through HomomorphicZKPverify(E(ID)). The session is established only when HomomorphicZKPverify(HomomorphicZKPprove(E(ID)))=true.
4. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 1, characterized in that: The process of the fine-grained access control policy is as follows: The access policy is deployed on the blockchain in the form of a smart contract, with a policy version number V. When an update is required, the UpdatePolicy(V) operation is executed through the smart contract. Each device uses the blockchain consensus mechanism to synchronize the latest policy and dynamically adjust the policy based on different driving scenarios.
5. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 1, characterized in that: The process of hybrid encryption to ensure data security is as follows: Video data is encrypted using the AES-256 symmetric encryption algorithm, and the symmetric key is encrypted using a lattice-based cryptographic system. The receiver first decrypts the symmetric key and then restores the video data. At the same time, a time-event dual-driven key update mechanism is introduced. When the key validity period Tvalid or the event count threshold Ethreshold is reached, a variant of the Diffie-Hellman key exchange protocol is used to update the key.
6. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 5, characterized in that: The process of verifying the integrity of the hash tree is as follows: A hash tree-based integrity verification mechanism is introduced. The video data is divided into data blocks b1, b2, …, bn. The hash value hi = Hash(bi) of each data block is calculated. The root hash value RootHash is obtained by constructing a hash tree layer by layer. The sender transmits the RootHash along with the video data. After receiving the data, the receiver recalculates and constructs the hash tree and compares the RootHash for consistency. If there is any inconsistency, the receiver immediately requests the retransmission of the tampered data block. If they are consistent, the video data is deemed complete and transmission continues.
7. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 6, characterized in that: The process of outputting the improved encryption transmission scheme is as follows: Low-density parity check code is used as the FEC coding scheme to encode the original data block D to generate redundant data block R; The original data and redundant data are encrypted separately using the AESKsym symmetric encryption algorithm. The receiver uses the LDPCdecode algorithm to restore the original information using the encrypted original data and redundant data. A model is built based on deep reinforcement learning, with network bandwidth, latency, and packet loss rate as state space parameters and different video encoding bit rates as action space. Based on the reward function R(s,a), the model is trained to learn the optimal bit rate selection strategy. Introduced in STUN / TURN server deployment, identity-based access control lists combined with TCP-TLS as a UDP backup transport mode.
8. The WebRTC-based vehicle-mounted video stream secure transmission management method according to claim 1, characterized in that: The process of combining LSTM and isolation forest algorithm to identify attacks is as follows: Collect transmission metrics such as latency T, packet loss rate P, and encryption throughput Q to form a set of metrics. Use the LSTM network to build a time series prediction model for transmission metrics and obtain the residual sequence between the predicted value and the actual value. Input the residual sequence into the isolation forest algorithm for outlier detection and generate anomaly scores. Based on the preset scoring threshold, it determines whether there is an attack behavior and locates key abnormal indicators through the attention mechanism; it uses the attack sample library for feature matching, identifies the attack type and triggers a graded response strategy.
Citation Information
Patent Citations
Vehicle-mounted self-organizing network anonymous authentication method based on block chain and zero-knowledge proof
CN118433713A
Expressway free flow precise mileage charging method based on block chain and zero knowledge proof
CN118762408A