我怎样才能通过WiFi发送原始数据包没有网络? [英] how can I send raw packets over wifi without a network?

查看:252
本文介绍了我怎样才能通过WiFi发送原始数据包没有网络?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我要发送的2树莓派的通过wifi一些数据没有他们连接到网络。

I am trying to send some data between 2 raspberry pi's over wifi without them being connected to a network.

我希望它的工作方式类似于信标和探测请求工作,在广播,可发出的无线接口。

I want it to work similar to the way beacons and probe requests work, where a broadcast can be sent out the wireless interface.

我想发送将设备与所述分组的发送时间的主机名的数据。

the data I want to send will be the hostname of the device and the time the packet was sent.

我一直试图弄清楚这一点在过去的几天,但我不能让任何事情没有他们是在同一网络上工作。

I've been trying to figure this out for the last few days but I cannot get anything to work without them being on the same network.

时有人能指出我在正确的方向?
我不是太大惊小怪我用什么语言。我一直在努力Python和C收效甚微。

Is anybody able to point me in the right direction? I'm not too fussed about what language I use. I have been trying python and C with little success.

推荐答案

注:这是不是一个真正的答案,只是一些想法的研究,可以随意编辑或更正注释

有6种模式一个WiFi适配器可以在运营从维基百科

There are 6 modes a wifi adapter can operate in. From wikipedia:

法师(作为接入点),管理(客户端,也称为站),特设,网状,中继器和监控模式。

Master (acting as an access point), Managed (client, also known as station), Ad hoc, Mesh, Repeater, and Monitor mode.

但我相信不是所有的无线适配器都支持所有的模式,所以一定要确保你有合适的硬件。

But I believe not all wifi adapters support all modes, so make sure you have suitable hardware.

我建议即席或网将是最适合你的目的。与自组织模式的至少所述设备将需要预先配置使用相同的SSID和信道。这可能不适用于Mesh模式。

I would suggest adhoc or mesh would be the most suitable to your purpose. With adhoc mode at least the devices would need to be configured beforehand to use the same SSID and channel. This may not apply to mesh mode.

一个快速搜索产生的问候几个链接到一个网状网络使用树莓派:

A quick search yields a few links in regards to using Raspberry Pis in a mesh network:

  • http://hackaday.com/2012/11/14/mesh-networking-with-multiple-raspberry-pi-boards/
  • Wireless mesh networking on Raspberry Pi using batman-adv protocol
  • http://www.netlore.co.uk/airmesh/?page=about

我也想看看使用Dot11 *系列的数据包中的优秀的Python Scapy的库(不带SC的研究 APY混淆)。您应该能够工艺的定制数据包并发送它们接口是否在正确的模式。下面是一个创建假冒接入点的项目大概包含了好消息: https://github.com/rpp0/scapy -fakeap

I would also look at using the Dot11* family of packets in the excellent Python Scapy library (not to be confused with Scrapy). You should be able to craft custom packets and transmit them if the interface is in the right mode. Here's a project that creates fake access points that probably contains good info: https://github.com/rpp0/scapy-fakeap

这篇关于我怎样才能通过WiFi发送原始数据包没有网络?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆