| 注册
请输入搜索内容

热门搜索

Java Linux MySQL PHP JavaScript Hibernate jQuery Nginx
ygp8
9年前发布

通过ICMP实现加密的P2P聊天:cryptochat

加密的(查看cryption.js,当前使用 crypto 模块的AES-256-CTR) P2P加密基于ICMP 使用 ping 请求。

$ sudo cryptochat <ip> <encryption_key>

If it doesn't work, it is probably because either your computer or your router is somehow blocking external ICMP requests.

Install

Make sure you have node0.10.x(tip: use n) and then install the package globally withsudo.

sudo npm install -g cryptochat

ICMP Echo request format

bits 0-7 bits 8-15 bits 16-31
type = 0 code = 0 header checksum
identifier sequence number
payload

The message data is attached as the ICMP payload.

Message

Messages are piped fromstdinand split into payload packages, which are encrypted separately and sent as ICMP Echo requests.

bits 0-15 bits 16-31
identifier =0x6363 message length
message

An "end" request is sent in order for the receiver to know when a message is completed. The end request has the following format:

bits 0-15 bits 16-31
0x6363 0x0010
0xffffffffffffffff

When the end request is received, the full message is decrypted and printed to the screen.

Contribute

As always, contributions are much appreciated.

项目主页:http://www.open-open.com/lib/view/home/1441426755831

 本文由用户 ygp8 自行上传分享,仅供网友学习交流。所有权归原作者,若您的权利被侵害,请联系管理员。
 转载本站原创文章,请注明出处,并保留原始链接、图片水印。
 本站是一个以用户分享为主的开源技术平台,欢迎各类分享!
 本文地址:https://www.open-open.com/lib/view/open1441426755831.html
安全相关 cryptochat