注入 sctp 数据包
我一直在尝试在linux环境中注入sctp数据包但没有成功, 这就是我所做的,我在两点之间创建了关联(一个终端带有 sctp 服务器,另一个终端带有 sctp 客户端)。 然后我从客户端发送一个字符到服务器并且它已成功传递,然后我从wireshark复制数据包并放入我的源代码并增加TCN和流序列号并发送它,但我没有在sctp上收到它服务器。正如你在下面看到的,我的数据包是完全相同的,
我的数据包是这样的:
IP部分 0000 45 00 00 34 00 00 40 00 40 84 3c 44 7f 00 00 01 0010 7f 00 00 01
SCTP 部分
0000 0b 5e 0b 59 c2 e5 f8 00 00 00 00 00 00 03 00 13 0010 fe aa 43 3e 00 00 00 0c 00 00 00 00 64 0a 00 00
然后在我的数据包未能传递到 sctp 服务器后,我与 sctp 客户端发送只是为了将其与我的数据包进行比较,然后它到达了 sctp 服务器,
IP 部分
0000 45 02 00 34 00 00 40 00 40 84 3c 42 7f 00 00 01 0010 7f 00 00 01
SCTP 部分
0000 0b 5e 0b 59 c2 e5 f8 00 00 00 00 00 00 03 00 13 0010 fe aa 43 3e 00 00 00 0c 00 00 00 00 64 0a 00 00
问候, 开发包
I've been trying to inject sctp packets in linux environment with no success,
This is what I have done, I've created an association between two points(one terminal with sctp server and another terminal with sctp client).
Then I sent a char from client to the server and it's been delivered successfully, then I copied the packets from wireshark and put in my source code and incremented the TCN and stream sequence number and send it but i didn't receive it on the sctp server. as you can see below that my packets are exactly the same,
my packet is this:
IP Part
0000 45 00 00 34 00 00 40 00 40 84 3c 44 7f 00 00 01
0010 7f 00 00 01
SCTP Part
0000 0b 5e 0b 59 c2 e5 f8 00 00 00 00 00 00 03 00 13
0010 fe aa 43 3e 00 00 00 0c 00 00 00 00 64 0a 00 00
then after my packet failed to be delivered to the sctp server i sent with the sctp client just to compare it with my packet and it arrived to the sctp server,
IP Part
0000 45 02 00 34 00 00 40 00 40 84 3c 42 7f 00 00 01
0010 7f 00 00 01
SCTP Part
0000 0b 5e 0b 59 c2 e5 f8 00 00 00 00 00 00 03 00 13
0010 fe aa 43 3e 00 00 00 0c 00 00 00 00 64 0a 00 00
Regards,
devbag
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您的 SCTP 消息格式似乎错误,请参阅 RFC4960。
问候
0b 5e :src 端口
0b 59 :dst 端口
c2 e5 f8 00 :验证标签
00 00 00 00 :校验和 - 错误
00 :块类型(有效负载数据)
03 :块标志(开始和结束片段)
00 13 :块长度
00 10 fe aa:TSN
43 3e :STREAM
00 00 :STREAM 序列
00 0c 00 00 :PPID
00 00 64 0a 00 00 :用户数据
Your SCTP Message seems badly formatted see RFC4960.
Regards
0b 5e :src port
0b 59 :dst port
c2 e5 f8 00 :verification tag
00 00 00 00 : checksum - WRONG
00 : chunk type (payload data)
03 : chunk flags (beginning and end fragment)
00 13 : chunk length
00 10 fe aa : TSN
43 3e : STREAM
00 00 : STREAM Sequence
00 0c 00 00 : PPID
00 00 64 0a 00 00 : User Data