Content uploaded by Sura Mahmood Abdullah
Author content
All content in this area was uploaded by Sura Mahmood Abdullah on Jul 12, 2017
Content may be subject to copyright.
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
Design Secured Smart Door Lock Based on Jaro Winkler Algorithm
Sura Mahmood Abdullah
Department of Computer Science , University of Technology , Baghdad , Iraq
suramahmood84@yahoo.com
Abstract
The security nowadays considered as significant topic specifically in design smart home. This paper is dedicated
on an authentication problem in design smart door lock authentication using string matching technique based on
password string.
This work contains two main parts, Android application (remote control) and control circuit using Arduino
UNO, plus the communication medium based on Bluetooth technology which is used to send and receive
information and commands in this work.
The main purpose of design smart door lock, using Jaro Winkler algorithm is to compare the registered password
security with each entered password which may contain some wrong or swapped characters. The results show
more strength authentication for access in real-time.
Keywords: Jaro Winkler, authentication, Arduino UNO, Android
1. Introduction
The modern design of smart homes has attentive on
smart controls and convert conservative switches to
compact control system[1]. The smart home
technologies have focused on networking (wiring and
wireless systems), controlling (remote control, smart
phones, and web browsers), and smart devices (green,
energy consumption, security, environment, and
entertainment)[2,3,4,5]. An illustration of smart home
technologies is shown in figure (1).
Figure (1) Category of Smart Home Services
The remote controllers in smart homes have been
used in numerous services such as home appliances
control;decrease power consumption, communication
and security. This work focuses on implementation of
the security issue in smart door lock [2].
Smart door lock is considered as a smart
authentication access control based on authenticated
person to lock/unlock the door in smart home. One of
the most advantage of design smart door lock is to
control door open/close by an authentication person,
other advantage is can be accessed using smart phone
where the use normal key may be lost or stolen [6].
There are several experiments and approaches about
security issues in smart door lock, one of these
techniques is using GSM (Global System for digital
mobile telecommunication) technology to send SMS
(short message service) to door controller and receive
message to the holder; GSM not secured enough and
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
can operate the controller by other users [7], another
technique is using the Bluetooth to lock/unlock door
by send usual commands [8], other technique based
on motion sensor PIR (Passive Infrared Sensor) for
locking/unlocking the door; this method has using
authentication procedure [9], and the last technique
based on RFID (Radio Frequency Identification) as
accessed, RFID can be destruction when faced to
magnetic field [10].
In this paper, the password send to controller attached
to door lock actuator which collects the information
of authenticated user's smart phone and password
compared by Jaro Winkler algorithm. The connected
between smart phone and door controller based on
Bluetooth technology.
2. Jaro Winkler Algorithm
This algorithm has been applied in this work as a one
of the methods that is used for a string comparison
because it is most efficient and accurate in similarity
metrics [11]. The Jaro Winkler algorithm has been
used for matching two strings which contain spelling
mistakes and find approximation of common matched
characters. The result value of this algorithm is
always returned between 0 and 1, the strings are
identical when the result value is 1 only. The
definition of Jaro is explained in equation (1) [12].
Where s and t are the strings need to compare. And
Jaro Winkler string comparator is calculated in
equation (2).
Where a and b are the string need to be compared, P
is Winkler constant (P<0.25), and N is the number of
character similarity [13]. An example of comparison
two strings using Jaro Winkler algorithm has been
explained below in details.
To compare two strings s=MARTHA, and
t=MARHTA, by applying equation (1) to find Jaro
value:
M=6, is number of matching characters
SL=6, is the length of first string (s)
TL=6, is the length of second string (t)
MS=1, is the mismatch characters (2/2=1)
Now, applying equation (2) to find the Jaro Winkler
value as below:
P= 0.1, Jaro Winkler constant
MT=3, number of prefix match
In our work, these steps of algorithm has been applied
in Arduino language platform based on Java to
compare both registered password with password sent
from smart phone device via Bluetooth where try to
lock/unlock door actuator. In addition to that, a
threshold value has been set for authentication access
where score of W should not be less than 0.9.
3. Proposed Work
The proposed work has focused on design hardware
for smart door lock using Bluetooth technology and
Android OS (Operating System), besides the
implementation of Jaro Winkler algorithm for
authentication access. The phases of proposed design
have been illustrated in figure (2).
Figure (2) Proposal Work Phases
In this work, an application is designed using smart-
phone with Android platform as remote control. The
Android platform has including Bluetooth APIs
(application program interfaces) which provides to
access to the Bluetooth functionalities. To create
connection between remote control and electronic
controller circuit for door lock, need to initialize the
server and client socket on same channel. Then, the
server side is listening to the request of client side,
and the last one waiting for permission from server
for accepting pair. The remote control application
design is shown in figure (3).
Figure (3) Remote Control Application Designed in
Android Platform
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
The Bluetooth command in remote control
application used to display list of Bluetooth devices within the range of detection. The procedure of
Bluetooth API is shown in figure (4).
Figure (4) Bluetooth Pairing Step in Client Side
After the pairing step has done, the client has
collecting the information of the device and select
device ID. In the proposed work, device ID has
considered as the plain stream because it is unique
information and phone number is considered as the
key-stream. The flow code of retrieving device
information is shown in figure (5).
Figure (5) Procedure Send Password for both
Commands (lock and unlock)
As shown in figure (3) there are two commands
(On/Off) used to control door lock. Within each of
these commands, password string has been send via
Bluetooth to the circuit control. There has been used a
Bluetooth module (HC-06) connected to Arduino
UNO which doing pairing and receive data from
smart phone, after that, the Jaro Winkler algorithm
has been applied in ATMEGA328 controller to find
the matching score between password strings. During
experience work, the proposed work is evaluated with
proposed algorithm by using different password
strings as described in table (1).
Table (1) Jaro Winkler Comparison Different
Password Strings
Password
String
(1)
Password
String
(2)
Jaro
Winkler
Authentication
state
Ahmed123
Ahmde123
0.98
True
Ahmed123
Ahmdd132
0.91
True
Ahmed123
Ahdme12
0.93
True
Ahmed123
Aahdmed123
0.90
True
Ahmed123
Aahed133
0.85
False
Ahmed123
Qhmed123
0.92
True
The whole hardware elements in the proposed design
are illustrated as schematic circuit and real design in
figure (6).
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
Figure (6) Proposed Hardware Design (a) Schematic Circuit, (b) Real Design
The Arduino UNO contains a microcontroller
(ATMEGA328) which has USB (Universal Serial
Bus) connection, PWM (Pulse Width Modulation),
analogue, and digital feature. In the proposal work,
Bluetooth module (HC-06) is connected to serial pins
with microcontroller (TX and RX) and power with
3.3v as shown in figure (7).
Figure (7) Schematic Diagram of Bluetooth Module
Connection to Arduino UNO
There has been using actuator (12v) mounted on door
used to lock/unlock operation. The actuator has
driven by driver circuit designed by using transistor
as switching mode and relay (5v) connected to one of
digital pin of Arduino UNO as shown in figure (8).
Figure (8) Actuator Driver Circuit Design
There are two types of actuator which are switch on
and off depending on command sent by smart-phone.
Each state of actuator has represented as shown in
figure (9).
(a)
(b)
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
(a)
(b)
Figure (9) Actuator Types, (a) Normally Close, (b) Open
4. Conclusions
Smart home technology is involved with various
fields (security, power consumption, communication,
etc). Security issue is becoming more important and
developed day by day.
The suggestion in this paper is apply Jaro Winkler
string comparison algorithm for an authentication for
door access by lock/unlock the actuator mounted to
door. The proposed design has focused on developing
door lock using Android platform for design a remote
control, and Arduino UNO as control circuit to
receive password string sent by personal smartphone,
then compared this password string with string
already recorded in control circuit and take decision
to lock/unlock the actuator of door based on threshold
(>0.9).
References
1. Mustafijur Rahman, A. H. M. Zadildul Karim,
Sultanur Nyeem, Faisal Khan, and Golam Matin;
"Microcontroller Based Home Security and Load
Controlling Using GSM Technology"; I. J. Computer
Network and Information Security, 2015.
2. Rohit Kadam, Pranav Mahmauni, and Yash
Parikh; "Smart Home System"; International Journal
of Innovative research in Advanced Engineering
(IJIRAE), Vol. 2, Issue 1, 2015.
3. NazrulAnuarNayan, Ili A. M. Ikhsan, and
Yasuhiro Takahashi; "Using ZigBee Communication
Technology in a Smart Home Wireless Sensor
Network"; Proceedings of Second International
Conference on Modern Trends in Science,
Engineering and Technology, 2014.
4. Rajeev Piyare and Seong Ro Lee; "Smart Home
Control and Monitoring System Using Smart Phone";
ICCA 2013, ASTL Vol. 24, pp. 83 - 86, 2013.
5. Jayashri B. Angali and Arvind Shaligram;
"Design and Implementation of Security Systems for
Smart Home based on GSM Technology";
International Journal of Smart Home, Vol. 7, No. 6,
pp. 201-208, 2013.
6. Ravi Das; "Biometric Technology: Authentication,
Biocryptography, and cloud-based Architecture",
CRC press, 2014.
7. F. Shawki, M. El-Shahat. Dessouki, A. I.
Elbasiouny, A.N. Almazroui, and F. M. R. Albeladi,
"Microcontroller Based Smart Home with Security
using GSM Technology", IJRET: International
Journal of Research in Engineering and Technology,
Vol. 4, Issue 6, 2015.
8. Lia Kamelia, Alfin Noorhassan S.R, Mada
Sanjaya and W.S., Edi Mulyana, "Door-Automation
System Using Bluetooth-Based Android for Mobile
Phone", ARPN Journal of Engineering and Applied
Sciences, Vol. 9, No. 10, 2014
9. Ali Haktan Isilak, "Smart Home Applcations for
Disabled People by Using Wireless Sensor Network",
Yeditepe University, Faculty of Engineering and
Architecture, Department of Computer Engineer,
2010.
10. Phillip Robinson, "Smart Home: RFID Access
Control and Automated-Lighting System", Senior
Design Project, 2008.
11. Bc. Tomas jendek, "Intelligent Identity
Information Processing", Diploma thesis, Slovak
University of Technology in Bratislava, Faculty of
Informatics and Information Technologies, 2014.
12. Jerome Euzenat and Pavel Shvaiko, "Ontology
Matching", nd edition, Springer, 2013.
13. John R. Talburt, "Entity Resolution and
Information Quality", 1st edition, Elsevier Inc., 2010.
Tikrit Journal of Pure Science 21 (6) 2016
ISSN: 1813 – 1662 (Print)
E-ISSN: 2415 – 1726 (On Line)
.