# Identifying a mobile device

**URL:** https://discourse.nodered.org/t/identifying-a-mobile-device/84537
**Category:** General
**Created:** [14 January 2024 18:26 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537 "2024-01-14T18:26:42Z")
**Posts on this page:** 15
**Page:** 2

<div class="post-metadata">

### Author: ![TadyTheFish](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@TadyTheFish](https://discourse.nodered.org/u/TadyTheFish)
#### Post date: [15 January 2024 22:10 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/21 "2024-01-15T22:10:06Z")

</div>

Hot damn it works 😂😂😂 so it was this simple. I also made my ip static on my wifi and i turned off MAC adress randomization... lets test this...  
Thank you so much man​:grin:😁😁

---

<div class="post-metadata">

### Author: ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)
#### Post date: [15 January 2024 22:15 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/22 "2024-01-15T22:15:55Z")

</div>

Yup!

For a **HTTP IN** Node with **/let-me-in** say

it will be [http://x.x.x.x:1880/let-me-in](http://x.x.x.x:1880/let-me-in)  
Just name the shortcut (not comment 😆 ) give it a nice icon etc etc, add to Home Screen

---

<div class="post-metadata">

### Author: ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)
#### Post date: [15 January 2024 22:25 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/23 "2024-01-15T22:25:57Z")

</div>

![IMG_1077](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/1/e/1e29b0ec55b661a4234eb70f6627c8c78a733422.jpeg)

---

<div class="post-metadata">

### Author: ![TadyTheFish](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@TadyTheFish](https://discourse.nodered.org/u/TadyTheFish)
#### Post date: [15 January 2024 22:29 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/24 "2024-01-15T22:29:51Z")

</div>

Already did... tested and it is working. Even tested it with VPN 👌😁 Thank you again

 ![IMG_1041](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/0/00801ef21e04cdef94c8c59afa0037a726821df7.jpeg)  
 ![Screenshot 2024-01-15 223744](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/f/b/fb86a97755f58d8c3b6d57100652ed6226a0b4c5.png)

---

<div class="post-metadata">

### Author: ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)
#### Post date: [16 January 2024 08:31 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/25 "2024-01-16T08:31:28Z")

</div>

@TadyTheFish

I wouldn't use the index of the header, there is no guarantee of its order.  
instead, just query the header property directly.

```auto
msg.req.headers["MyHeader"] === "xx:xx:xx:xx:xx:xx"

```

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/9/e9a7296c662ed0d103b27616f23d224e89a16f9e.png)

---

<div class="post-metadata">

### Author: ![TadyTheFish](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@TadyTheFish](https://discourse.nodered.org/u/TadyTheFish)
#### Post date: [16 January 2024 11:07 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/26 "2024-01-16T11:07:25Z")

</div>

Good point👌 thank you

---

<div class="post-metadata">

### Author: ![cameo69](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cameo69/32/66593_2.png) [@cameo69](https://discourse.nodered.org/u/cameo69)
#### Post date: [16 January 2024 20:26 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/27 "2024-01-16T20:26:09Z")

</div>

Doesn‘t this mean that anybody who knows the MAC address of allowed devices can open the door by using the same MAC address?

---

<div class="post-metadata">

### Author: ![GogoVega](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gogovega/32/71313_2.png) [@GogoVega](https://discourse.nodered.org/u/GogoVega)
#### Post date: [16 January 2024 20:34 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/28 "2024-01-16T20:34:47Z")

</div>

The Shorcut is used on the local network. But that's a good question, Apple uses a different MAC address per network. Maybe the hardware address of the image does not change.

---

<div class="post-metadata">

### Author: ![marcus-j-davies](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/marcus-j-davies/32/103435_2.png) [@marcus-j-davies](https://discourse.nodered.org/u/marcus-j-davies)
#### Post date: [16 January 2024 20:47 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/29 "2024-01-16T20:47:42Z")

</div>

> [@cameo69](#):
>
> Doesn‘t this mean that anybody who knows the MAC address of allowed devices can open the door by using the same MAC address?

Yes, but nothing stopping you improving it. like adding a secret key in the headers.  
its just "a way" to identify an allowed device.

> [@GogoVega](#):
>
> Apple uses a different MAC address per network. Maybe the hardware address of the image does not change.

"Private Wi-Fi address" will use a MAC _per_ network as you said.  
so if you disable that - then the same MAC is used for all networks - prop not recommended to disabling it for this use case.

---

<div class="post-metadata">

### Author: ![TadyTheFish](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@TadyTheFish](https://discourse.nodered.org/u/TadyTheFish)
#### Post date: [16 January 2024 20:55 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/30 "2024-01-16T20:55:37Z")

</div>

Yeah it is very possible to hack but like I said for an average thief, kicking down the door woul be way wasier than hacking my wifi and then monitoring traffic and waiting for me to open the door. If you would know anything about camera doorbells you can notice that almost all use a contact for opening the lock is on the outside unit. So it is just a matter of ripping the camera off the wall and shorting two wires...so this is just for my conveniance 😁

---

<div class="post-metadata">

### Author: ![cameo69](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cameo69/32/66593_2.png) [@cameo69](https://discourse.nodered.org/u/cameo69)
#### Post date: [16 January 2024 21:04 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/31 "2024-01-16T21:04:12Z")

</div>

Well, I guess, as long as you know the flaws and limitations, it is OK.

---

<div class="post-metadata">

### Author: ![BarryMas](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/barrymas/32/38363_2.png) [@BarryMas](https://discourse.nodered.org/u/BarryMas)
#### Post date: [22 January 2024 08:46 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/32 "2024-01-22T08:46:01Z")

</div>

I used this library on a esp01 to determine if my mobile is in the neigbourhood of my wifi network:  
[GitHub - skickar/FriendDetector: ESP8266 friend detector](https://github.com/skickar/FriendDetector).  
I used the serial output of the esp01 to give a sign when my mobile was detected.

I stopped experimenting with the library about a year ago because I had other projects to finish but it seemed promising.

---

<div class="post-metadata">

### Author: ![TadyTheFish](https://avatars.discourse-cdn.com/v4/letter/t/839c29/32.png) [@TadyTheFish](https://discourse.nodered.org/u/TadyTheFish)
#### Post date: [22 January 2024 09:05 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/33 "2024-01-22T09:05:58Z")

</div>

I think I saw this sometime but I think iOS or other mobile devices by default change the MAC because of tracking. Thank you for sharing this

---

<div class="post-metadata">

### Author: ![BarryMas](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/barrymas/32/38363_2.png) [@BarryMas](https://discourse.nodered.org/u/BarryMas)
#### Post date: [22 January 2024 11:51 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/34 "2024-01-22T11:51:40Z")

</div>

True for the newer iPhones but you can switch off spoofing per network i.e. your network:

> **[How to find and change the MAC address on your iPhone (or iPad)](https://www.digitalcitizen.life/mac-address-iphone/)**
>
> Do you own an iPhone or an iPad and wondering what’s your MAC address and how to change it? Would you like to spoof your MAC address or, the opposite, disable MAC address randomization on your Apple mobile device? If you answered yes to any of these...

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [5 February 2024 11:51 UTC](https://discourse.nodered.org/t/identifying-a-mobile-device/84537/35 "2024-02-05T11:51:45Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.

[Previous page](https://discourse.nodered.org/t/identifying-a-mobile-device/84537.md?page=1)
