问题遇到的现象和发生背景
from scapy.all import后找不到SOMEIP类
用代码块功能插入代码,请勿粘贴截图
from scapy.all import *
sip = SOMEIP
sip.iface_ver = 1
sip.proto_ver = 1
sip.msg_type = "REQUEST"
sip.retcode = "E_OK"
sip.msg_id.srv_id = 0x0105
sip.msg_id.method_id = 0x0201
运行结果及报错内容
sip = SOMEIP
NameError: name 'SOMEIP' is not defined
我的解答思路和尝试过的方法
通过from scapy.contrib.automotive.someip import SOMEIP
from scapy.contrib.automotive.someip import SOMEIP
运行代码后仍然报错
raise AttributeError(attr)
AttributeError: msg_id
我想要达到的结果
能够调用SOMEIP下的msg_id等属性