向连接到 Wi-Fi 网络的所有设备发送通知 [英] Send notification to all the devices connected to a Wi-Fi network

查看:22
本文介绍了向连接到 Wi-Fi 网络的所有设备发送通知的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法向连接到特定 Wi-Fi 网络的设备发送通知?

Is there any way to send a notification to the devices which are connected to a particular Wi-Fi network?

比如说,我有一个名为我的 Wi-Fi"的 Wi-Fi 网络,它是不安全的,任何人都可以连接.公共网络.

Say, I have a Wi-Fi network named "My Wi-Fi", which is not secured, that is any one can connect. A public network.

可能有 N 个用户连接到我的 Wi-Fi".这些用户可以执行任何类型的交易,比如在线支付.

There may be N-number of users connected to "My Wi-Fi". These users can perform any kind of transaction, say online payment.

现在,如果我想关闭或关闭我的 Wi-Fi"路由器或接入点,这些交易可能会失败.

Now if I want to turn off or shut down "My Wi-Fi" router or access point, these transactions may fail.

因此,在关闭之前,我想向所有连接到我的 Wi-Fi"网络的用户发送文本通知.(用户的设备中没有任何类型的应用来推送通知.)

So before shutting down, I want to send a text notification to all the users connected to "My Wi-Fi" network. (User does not have any kind of app in their device, to push the notification.)

这可能吗?

推荐答案

没有向连接到 Wi-Fi 网络的所有设备发送(推送)消息的标准方法.如果有办法,很容易找到规范并指出如何完成.不幸的是,很难证明某些东西不存在.

There is no standard method of sending (pushing) a message to all devices attached to a Wi-Fi network. If there was a way, it would be easy to find the specification and point to how it is to be done. Unfortunately, it is difficult to prove the absence of something.

正如您清楚地意识到的那样,如果您控制的相应页面在浏览器中打开,或在他们的设备上运行的应用程序中打开,则有可能这样做.您可以开发一个框架,让用户必须登录并保持页面打开或应用运行,才能连接到您的 Wi-Fi.

As you clearly realized, it would be possible to do so if an appropriate page which you control was open in a browser, or application running, on their device. You could develop a framework where users have to sign on and keep a page open, or application running, in order to connect to your Wi-Fi.

鉴于您控制了路由器,您实际上可以编写代码来拦截通过路由器传输的数据包,并在发送到各种连接设备的页面的 HTTP 中插入这样的警告.这假设他们使用 HTTP 查看普通页面.当然,您也可以在其他协议中插入警告.根据您的司法管辖区,这可能是非法的,或者有其他法律问题.我认为这样做是个坏主意™.

Given that you control the router, it would be physically possible for you to write code which intercepted the packets being transmitted through the router and inserted such a warning within the HTTP of pages being sent to the various connected devices. This assumes that they are using HTTP to view normal pages. You could, of course, also insert a warning in other protocols. Depending on your jurisdiction this might be illegal, or have other legal issues. I would consider doing so to be a Bad Idea™.

这篇关于向连接到 Wi-Fi 网络的所有设备发送通知的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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