在Android上发现附近的智能手机设备 [英] Discover Nearby Smartphone Devices on Android

查看:147
本文介绍了在Android上发现附近的智能手机设备的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题陈述

我正在尝试为Android开发一个可以检测附近智能手机设备的应用程序.我需要发现智能手机设备,无论它们与WLAN或操作系统的连接如何.唯一的要求是启用其蓝牙或wifi设置.我正在尝试捕获这些设备的MAC地址以及RSSI.我要模仿的应用程序示例是 Meshlium .

已经考虑的方法

  1. Android经典蓝牙:

    • 我已按照指南查找了当前未与我的设备配对的设备.
    • 我尝试发现的智能手机需要处于发现"状态,模式才能找到.对于大多数现代手机而言,这意味着它们需要位于其蓝牙设置页面上.
  2. Android P2P(Wifi Direct):

    • 我再次遵循了指南,在附近找不到智能手机.
    • 类似于蓝牙,这两个设备(我的设备和我要查找的设备)都必须同时尝试发现wifi直接设备.
    • 此外,iOS似乎也不支持wifi直连.
  3. Google附近:

    • Nearby Connections仅适用于运行使用附近的Connections API的应用程序的设备.因此,只有具有当前运行广告或发现功能的应用程序的设备才可供检测.
  4. Wifi网络服务发现:

    • 这使我可以看到当前正在网络上发布服务的设备,而不是实际的设备本身.

设备规格

我正在使用的设备正在运行android 6.0.1版本和型号rk3368-box.该设备还具有root权限.

问题

我的android设备上是否有一种方法可以发现附近的智能手机,唯一的要求是启用了wifi或蓝牙功能?也许数据包嗅探到设备的探针请求?我已经研究了数据包嗅探,但是找不到适用于Android的可靠资源.另外,如果可能的话,我也希望能够在c#和Xamarin.Android中做到这一点.

更新

是否可以选择自定义ROM?我不打算为Play商店创建一个应用程序,而是为自定义硬件创建一个应用程序.也许当我在设备上启用wifi热点时,它会记录附近设备的探测请求并另存为文件以供以后导出?

解决方案

无法执行此操作.而且不应该-除非我与您一起工作(在这种情况下,可以使用上述多种方法),它会严重侵犯我的隐私权,以便您能够检测到我的设备.

Problem Statement

I am trying to make an application for Android that can detect nearby smartphone devices. I need to discover smartphone devices regardless of their connection to a WLAN or their operating system. The only requirement is that their bluetooth or wifi setting is enabled. I am trying to capture the MAC Address and maybe RSSI of these devices. An example of an application I am trying to emulate is Meshlium.

Methods Already Considered

  1. Android Classic Bluetooth:

    • I have followed the guide to discover devices that aren't currently paired with my device.
    • The smartphones I am trying to discover need to be in "discovery" mode in order to be found. For most modern phones that means they need to be on their bluetooth settings page.
  2. Android P2P (Wifi Direct):

    • I have followed the guide again and can't discover smartphones nearby.
    • Similar to bluetooth, both devices (mine and the device I am trying to find) need to be both trying to discover wifi direct devices.
    • Also it seems iOS doesn't support wifi direct anyways.
  3. Google Nearby:

    • Nearby Connections works only with devices running an application that is using the nearby connections api. So only devices with the app currently running the advertising or discovery feature will be available for detection.
  4. Wifi Network Service Discovery:

    • This lets me see devices that are currently advertising services on a network and not the actual devices themselves.

Device Specifications

The device I am using is running android version 6.0.1 and Model number rk3368-box. The device also has root permissions.

Question

Is there a way on my android device to discover the nearby smartphones with the only requirement being their wifi or bluetooth is enabled? Perhaps packet sniffing the probe requests of the devices? I have researched packet sniffing but can't find any solid resources for Android. Also I would love to be able to do so in c# and Xamarin.Android if possible.

Update

Is a custom ROM an option? I am not looking to make an application for the play store, but one for custom hardware. Perhaps when I enable the wifi hotspot on the device it logs the probe requests from the devices nearby and saves as a file to export later?

解决方案

There is no way to do this. And there shouldn't be- unless I'm working with you (in which case multiple of the above will work) its a massive invasion of my privacy for you to be able to detect my device.

这篇关于在Android上发现附近的智能手机设备的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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