
CVE-2026-21014을 시연하기 위해 캡처된 CAN 버스 프레임을 재생하여, 인증 및 신선도(freshness) 검사 누락이 허가되지 않은 자동차 ECU 동작을 가능하게 하는 방식을 보여줍니다.
# can_replay_sim.py - Simulates CAN bus replay
import time
can_messages = []
def send_can(msg_id, data):
print(f"CAN {msg_id:#x}: {data.hex()}")
can_messages.append((msg_id, data))
def receive_can():
return can_messages[-1] if can_messages else None
# Simulate car sending "door unlock" command
send_can(0x100, b'\x01\x00\x00\x00') # unlock
# Attacker replays captured frame
time.sleep(1)
captured = receive_can()
if captured:
print("Replaying captured frame...")
send_can(captured[0], captured[1])
자동차 제어기 영역 네트워크(CAN)는 메시지 인증이나 신선도(freshness) 검사를 구현하지 않습니다. OBD‑II 포트에 물리적으로 접근할 수 있는 공격자는 정상적인 프레임(예: 도어 잠금 해제)을 캡처한 후 이를 재생하여 허가되지 않은 동작을 수행할 수 있습니다.
시뮬레이션 실행:
python can_replay_sim.py
이 스크립트는 잠금 해제 명령의 캡처 및 재생을 출력합니다.