Wireless RFID as security key

In this subforum you can show projects you have made, or you are busy with. Please create your own topic.
Post Reply
bjen
Posts: 1
Joined: Sunday 25 October 2015 21:55
Target OS: Raspberry Pi
Domoticz version:
Contact:

Wireless RFID as security key

Post by bjen » Sunday 25 October 2015 22:56

Hi All!

Thought to share this and also in the hope to get some help on some points.
Image
I use Domoticz to control lights and more in and around my house. The second step is to setup security so I can phase out my current security system.
Since I hate the pinpad I am making my system with a RFID reader which I can place everywhere or make multiple of them.

Current challenges
Its a struggle to create a decent entry and leave delay. When a token is scanned I want a 30 seconds delay before the alarm is activated. When entering (opening a door) I want a 30 seconds delay that gives me the time to scan a token before the alarm sounds. Anyone knows how to achieve this based on the status of the SecPannel?! :?: (Due to maintainability i'm not willing to use lua scripts.)

How it works
I'm using a Particle Core as the controller. Its a small ARM Cortex M3 microcontroller with WiFi on-board. Completely configurable and flash-able trough web interface and connected to the cloud.
The Core has the following connected to it;
  • - RC522 RFID module
    - Quad Level-Shifter (3V to 5V)
    - 2x WS2811 addressable leds
LED 1 displays the process of RFID scanning and feeds back the status of the token (checked in or checked out). LED 2 displays the current status of Domoticz secure pannel status (Disarmed = green, Armed = red). Since the LEDs are working on 5V and the Core output is on 3V a level-shifter is needed for the data channel of the WS2811.

When a token is scanned the Core sends a webhook to the Particle cloud which on its turn creates a HTTP POST towards the Raspberry PI running Domoticz. On the Raspberry a web-server + PHP + MySQL forms the brains of the system.
The MySQL has several tables containing all known tokens, uses and cores. Also a table for logging and a table where token IDs are coupled to users.
The PHP scripts contain the logics which executes a particular action when a token is scanned. It for example sends a HTTP POST towards Domoticz to set the SecPannel.

When the system is armed and a intruder is detected by a PIR/Door or other sensor the GPIO switches a relay that sounds a alarm. Unless when someone enters trough a door and scans its token within 30 seconds.

Example
User1 = out
User2 = in

User1 comes home and scans its token. Now User1 + User2 are in.
User2 go's away and scans its token. Now User1 + User2 our out. The PHP logically will give a callback on the scan and lets LED1 flash RED because the token is checked out. It also sends a HTTP POST to Domotcz to set the SecPannel on Armed.

Current project status
  • - PHP code finisched
    - Core code finisched
    - Entry and leave delay. Not yet achieved. Seems to be difficult with Blockly
    - Web frontend to manage users, tokens, cores and view log. Not yet started
When finished I will publish everything if anyone is interested :)

jenbaker
Posts: 2
Joined: Wednesday 02 March 2016 9:21
Target OS: Windows
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by jenbaker » Wednesday 02 March 2016 9:30

is it possible to change RC522 RFID module into the RS232 or RS232 interface?

alfred_j_kwak
Posts: 253
Joined: Friday 20 September 2013 18:49
Target OS: Raspberry Pi
Domoticz version: 2.3530
Location: Finland
Contact:

Re: RE: Re: Wireless RFID as security key

Post by alfred_j_kwak » Wednesday 02 March 2016 11:23

jenbaker wrote:is it possible to change RC522 RFID module into the RS232 or RS232 interface?
The one RC522 module I have uses SPI bus.

Joshuapr
Posts: 5
Joined: Sunday 15 May 2016 6:28
Target OS: Windows
Domoticz version:
Location: Seychelles
Contact:

Wireless RFID as security key

Post by Joshuapr » Tuesday 17 May 2016 3:47

Hi all

I am working now to write wireless RFP Small & Medium officesand I need your help to provide the Security Requirements.

Thanks in advance

Mr_F

TheBod
Posts: 47
Joined: Friday 01 January 2016 21:46
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by TheBod » Friday 20 May 2016 14:26

bjen, any updates on this project?

lucalg
Posts: 16
Joined: Monday 31 August 2015 17:24
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by lucalg » Tuesday 18 April 2017 14:34

Good afternoon,
i have a similar need but, until now, with no solution. I want to allow some users to come inside a parkzone. They will have a rifd tag to be used to define if that user is allowed or not to come inside.

Problem is that we have 250 users so i'm on the big trouble to filter only allowed users.
Can you help this non-programmer?

Thank you a lot,
Luca

Graph54
Posts: 5
Joined: Thursday 04 May 2017 16:05
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by Graph54 » Thursday 04 May 2017 16:44

HI everyone :)

Nice setup !

Instead of having a "separate" server do deal with the authentification, would it be possible to handle it directly with Domoticz using variables or anything else ?

Thank you

onlywomenstuff
Posts: 1
Joined: Thursday 13 July 2017 10:06
Target OS: -
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by onlywomenstuff » Tuesday 18 July 2017 13:17

is that okay if i use this concept in my last year of project..

Timeless
Posts: 59
Joined: Friday 10 June 2016 23:46
Target OS: Linux
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by Timeless » Tuesday 18 July 2017 13:48

Please keep in mind that these RFID tags are easily cloned. Example on youtube

If you really want to have secure RFID system please have a look at UHF RFID Gen2. There feature a password authentication which (for now) cannot be cloned without knowing the password beforehand. So only cloning the EPC is not enough for a UHF RFID Gen2 system. Unfortunately these tags and readers are more expensive than a simple 13.56Mhz RFID system.
"The greatest good you can do for another, is not to share your own riches, but to reveal to him, his own."
- Benjamin Disraeli -

Graph54
Posts: 5
Joined: Thursday 04 May 2017 16:05
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: Wireless RFID as security key

Post by Graph54 » Tuesday 19 September 2017 17:34

I do understand but for minor security projects is there a way to manage ID directly in domoticz ? I've actually coded a webapp which compare the ID to its database and triggers a relay if the ID is active but It could be great to handle it in domoticz :)

D'rMorris
Posts: 310
Joined: Thursday 01 May 2014 9:01
Target OS: Raspberry Pi
Domoticz version:
Location: Netherlands - Sittard
Contact:

Re: Wireless RFID as security key

Post by D'rMorris » Thursday 01 February 2018 14:52

I'm actually building a similar project at the moment and wanted to give my 2 cents, maybe it gives you some ideas.
I'm using a NodeMCU V3 with ESPeasy on it (it's actually the same board as you use, I got mine from AliExpress).
Attached to the NodeMCU is a PN532 RFID reader.

My setup will be identical to yours:
- Pi3 running Domoticz
- Pi3 running Mosquitto (MQTT broker)
- Pi3 running NodeRED
- NodeMCU running ESPeasy with a PN532 RFID reader

Instead of using a third party cloud system, I use NodeRED and Mosquitto installed on a Pi3 to handle communications. Partly because I do not want to send my data to a cloud / I do not want to be dependent on somebody else's cloud and partly because I like building my own solutions. I'm also going to feed my authorized tags into a SQLite DB and reading that during the tag scan in NodeRED. Not that it's necessary for 4 tags, but anyway :-).

Regarding you question regarding the entry and leave delays: does your Particle have a tab called rules? If so, you could use that to delay your message.
However: I would recommend to move to a locally managed broker instead of a cloud broker. A delay is really easy to setup in NodeRED, it has a node called "delay" that does exactly this.

Regarding adding the 150 tags: you could build something in NodeRED to put it in "learning" mode and then feeding all tags that you scan into a DB. After you scanned them all, disable "learning" mode and you have a DB table with all your scanned tags :-).

D'rMorris
Posts: 310
Joined: Thursday 01 May 2014 9:01
Target OS: Raspberry Pi
Domoticz version:
Location: Netherlands - Sittard
Contact:

Re: Wireless RFID as security key

Post by D'rMorris » Thursday 01 February 2018 14:57

lucalg wrote:
Tuesday 18 April 2017 14:34
Good afternoon,
i have a similar need but, until now, with no solution. I want to allow some users to come inside a parkzone. They will have a rifd tag to be used to define if that user is allowed or not to come inside.

Problem is that we have 250 users so i'm on the big trouble to filter only allowed users.
Can you help this non-programmer?

Thank you a lot,
Luca
Can you tell more about your whole setup? This to prevent that we start giving solutions that are not applicable in your situation. What happens when a tag is scanned? To what system is that tagID sent? If I had to build it, I would create a DB with a table that contains USERID, TAGID and PARKZONE. Parkzone can be either filled with YES or NO.
Then, I would have an IOT board (like a NodeMCU, Arduino or whatever) that scans the tag, sends the TAGID to NodeRED and in NodeRED use the TAGID to read the database table to see if that user is allowed in the parkzone. Depending on a yes or no, open a relay to open the gate :-).

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests