Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 51

PROJECT SEMESTER REPORT

HIVE
By:
Raja Singla
Roll no: IT-1047-2K12
Under the Guidance of
Mr. Yash Buch (Corporate Engineer)
(SRI Noida)

Submitted to the
DEPARTMENT OF COMPUTER ENGINEERING &
TECHNOLOGY

YMCA University of Science and Technology


Faridabad
In Partial Fulfillment of the Requirements
for the
Degree of

Bachelor of Information Technology


At YMCAUST, Faridabad
Jan-June 2016

ACKNOWLEDGEMENT

I take this opportunity to express our sincere thanks and deep gratitude to all those people
who extended their wholehearted co-operation and have helped me in completing this
project successfully.
First of all, I would like to thank Mr. Yash Buch (Corporate Engineer), Mr. Sanjeev
Bhatt" (Chief Engineer) for their precious time and support whenever needed. They
have been a driving force behind the successful completion of the project.
I would also like to express my deep gratitude towards SRI, Noida for considering me a
part of their organization and provide such a great Platform to learn and enhance my
skills.
A very special thanks goes to all the faculties of YMCA University under whom guidance
I have been able to excel in my career and reach to such a prestigious organization.

Raja Singla
(IT-1047-2K12)
YMCAUST

Content

1.

COMPANY PROFILE............................................................................................................1
1.1

History..............................................................................................................................3

1.2

Samsung Research and Development Institute (SRI) Noida............................................4

1.3

Journey..............................................................................................................................5

1.4

Samsung Global................................................................................................................5

1.5

Samsung Electronics History............................................................................................6

1.6

Samsung Electronics Today..............................................................................................7

1.7

Milestones and Awards.....................................................................................................8

1.8

Management Philosophy..................................................................................................8

1.9

Samsungs Vision 2020.....................................................................................................9

1.10 Vision of SRI, Noida includes, following three strategies:..............................................9


1.11 Samsungs Values...........................................................................................................10
1.12 TECHNOLOGY.............................................................................................................10
1.13 Key Technologies features of SRI Noida R&D..............................................................11
1.14 Future Trend and New Technologies..............................................................................11
1.15 Mobile.............................................................................................................................15
1.16 Other digital appliances..................................................................................................16
1.17 Samsung Apps................................................................................................................16
1.18 Samsung Excellence Centers..........................................................................................17
2.

Project Introduction...............................................................................................................18
2.1

2.1.1

Authentication.........................................................................................................18

2.1.2

Request for OTP......................................................................................................18

2.2

3.

OTP Fetch.......................................................................................................................18

Call Notes.......................................................................................................................19

2.2.1

Application Interface...............................................................................................19

2.2.2

Background Service................................................................................................19

2.3

Encryptor........................................................................................................................19

2.4

Resolution Finder............................................................................................................20

Background...........................................................................................................................20

3.1

Project Components........................................................................................................20

3.1.1

User Suite................................................................................................................20

3.1.2

Developer Suite.......................................................................................................23

The developer suite has following two applications.............................................................23

4.

5.

3.3

Project Completion Plan.................................................................................................23

3.4

Motivation.......................................................................................................................24

Platform and Techniques.......................................................................................................24


4.1

Android...........................................................................................................................24

4.2

Bluetooth.........................................................................................................................26

4.3

Google Cloud Messaging: Overview..............................................................................28

4.4

Threading........................................................................................................................29

4.5

MD5/SHA1/SHA2..........................................................................................................31

Project Design.......................................................................................................................32
5.1

OTP Fetch DFD..............................................................................................................32

5.2

Call Notes DFD..............................................................................................................33

6.

Implementation......................................................................................................................36

7.

Testing...................................................................................................................................37

8.

7.1

OTP Fetch Test Cases.....................................................................................................37

7.2

Call Notes Test Cases.....................................................................................................38

7.3

Res Finder and Encryptor Test Cases.............................................................................39

Results...................................................................................................................................39
8.1

LEARNING....................................................................................................................39

8.2

Snapshots........................................................................................................................40

9. LIMITATIONS AND CHALLENGES.....................................................................................42


10. FUTURE WORK....................................................................................................................42

1. COMPANY PROFILE

About Samsung

Solutions

Services

Products

Samsung Excellence Centers

About Samsung
Our Platform moves the world!

A digital leader a responsible global citizen a multi-faceted family of companies. An ethical


business. Samsung(www.samsung.com) is all of these and more.
At Samsung Group and Samsung Electronics, our products, our people, and our approach to
business are held to only the highest standards so that we can more effectively contribute to a
better world.
For over 72 years, Samsung has been dedicated to making a better world through diverse
business that today span advanced technology, semiconductors, skyscraper and plant
construction, petrochemicals, fashion, medicine, finance, hotels, and more. Our flagship
company, Samsung Electronics, leads the global market in the high-tech electronics
manufacturing and digital media.
Through innovative, reliable products and services; talented people; a responsible approach to
business and global citizenship; and collaboration with our partners and customers, Samsung is
taking the world in imaginative new directions.

The companys thrust on Product Innovation and R&D has given the company a competitive
edge in the marketplace.
The Samsung Group is a multinational conglomerate corporation headquartered in Samsung
Town, Seoul, South Korea. The Samsung Group comprises numerous international affiliated
businesses, most of them united under the Samsung brand including Samsung Electronics, the
worlds largest technology company by sales. Samsung Heavy Industries, the worlds second
largest shipbuilder, Samsung Engineering was ranked 35th, Samsung C&T 72nd in a 2009 ranking
of 225 global construction firms compiled by Engineering News Record, a US construction
journal. Samsung Life Insurance was ranked 14th in a 2009 ranking of Fortune Global 500
Industries.

1.1 History
In 1938,Lee Byung-chull (19101987) of a large landowning family in the Uiryeong county
came to the nearby Daegu city and founded Samsung Sanghoe, a small trading company with
forty employees located in Su-dong (now Ingyo-dong). It dealt in groceries produced in and
around the city and produced noodles itself. The company prospered and Lee moved its head
office to Seoul in 1947. Lee sought to establish Samsung as an industry leader in a wide range of
enterprises, moving into businesses such as insurance, securities, and retail. Lee placed great
importance on industrialization, and focused his economic development strategy on a handful of
large domestic conglomerates, protecting them from competition and assisting them
financially.In the late 1960s, Samsung Group entered into the electronics industry. It formed
several electronics-related divisions, such as Samsung Electronics Devices Co., Samsung
Electro-Mechanics

Co.,

Samsung

Corning

Co.,

and

Samsung

Semiconductor

&

Telecommunications Co. Its first product was a black-and-white television set. Samsung
Electronics overtook Sony as one of the world's most popular consumer electronics brands in
2004 and 2005.

1.2 Samsung Research and Development Institute (SRI) Noida


Founded in 2007, SRI-India was conceptualized with a vision to provide a competitive R&D
platform in wireless technology. Headquartered in Noida, aligning with Samsungs vision, Noida
Lab is one of the fastest-growing companies in the mobile software sector. SRI-Noida is focused
on embedded and PC software development for Samsung Electronics, in a variety of areas
related to Mobile phones. SRI-Noida is a Division of Samsung India Electronics Pvt. Ltd.
(SIEL).

1.3 Journey
Samsung has established Software Engineering Lab in 2007 in India with a firm belief towards
success and realistic goals. Noida Lab has transformed itself into one of the most competitive
and proficient R&D centers of Samsung worldwide. It is focused on embedded and PC software
development for Samsung Electronics, in a variety of areas related to Mobile phones.
Noida Lab started its operations with Regional Adaption and Multimedia testing while focusing
to bring great innovations and latest technologies in the era of wireless communications. SRINoida is engaged in development of latest mobile software for all range of handsets. SRI-Noida
also focuses on Quality which includes automation testing, protocol testing, white box testing
and GCF certifications.

1.4 Samsung Global


Samsung has been moving continuously with a growing brand value in the world through
advanced technologies like petrochemicals, fashion, medicines, semiconductors, skyscraper and
plant construction, finance, hotels and many more for more than 70 years. Samsung is the place
where innovation and quality is always the first priority. Samsung has achieved many milestones
through a strong commitment towards quality, commitment for its values and vision and with
professional and empathetic approach with its partners, clients and its employees.
Globally, Samsung has been ranked among the top 30 largest employers in the world with
245000 employees. Samsungs scale is similar to the entire Singaporean economy with
approximate revenue of$174.2bn. Continuously standing as the largest driver of the Korean
economy, Samsung holds 18% of Korean GDP and 20% of Korea export.

Former Chairman Mr. BC Lee, 50 years (1938-1987), founded Samsung, 1938 making it the
Engine of Korean Economy. The Achiever Chairman Mr. KH Lee has been continuously making
Samsung best in Class Company since 1988 till today.
Samsung global has more than 429 offices/facilities 68 countries, including 30 Manufacturing
Subsidiaries, 51 Sales Subsidiaries, one Manufacturing and Sales Subsidiaries, 2 Distribution
centers, 6 design centers, 77 Branch offices and others.
With a strong commitment towards R&D, Samsung has invested $5.3bn in 2005 gradually
increasing to$6.2bn in 2009.

1.5 Samsung Electronics History

1994
6Mb DRAM developeded

1988

Samsung Semiconductor &


Telecommunications
merged with
1Gb DRAM developed
CDMA
1974
Samsung
Electronics
Co.
cellular services commercialized
Wafer fabrication started

1996

1.6 Samsung Electronics Today

Ranked 10th globally and 1st in Asiaamong corporations on the C

1.7 Milestones and Awards


Brand Value Ranked 19th in the World in 2009.
Selected as the fastest growing Winner Brand for two consecutive years(2002-2003).
It has been the fastest growing global brand since 2002.
Samsung is the 2Nd Top Patent Winner (2009,US), holding more than 3611 patent till
date.
Launched Worlds Slimmest LED TV(Jan, 2009).
Worlds First HSUPA Phone (Apr, 2008).
Worlds First 30nm 64 GB NANAD(2007).
Worlds First Blu-ray Player(Jun, 2006).
Worlds First HSPDA Phone(May, 2006).
Worlds Largest TV (Sep, 2005).
Established Noida Lab in 2007.

Leading

1.8 Management Philosophy


We at SRI Noida are focused to deliver high quality product using the combination of talent and
technology. We believe that the utilization of transparent, collective and customer focused
approach of work can develop more value to our work.
In order to construct the organizational values and strengths, we at SRI, Noida, believe in
maintaining the great work place for experienced as well as new talents. We firmly believe in
making our product, first Choice for the customers.

1.9 Samsungs Vision 2020

Inspire the world, Create the Future


Samsung has mapped out a specific plan of reaching $400 billion in revenue and becoming one of
the worlds top five brands by 2020. To this end, Samsung has also established three strategic
approaches in its management: Creativity, Partnership, and Talent.
At SRI Noida, we aim to emerge as a center of excellence for research, development, testing and
solutions in wireless communication. Our target is to expand strong technological base in the
South West Asia region for carrying out research work, nurturing the local talent and exploring
the market.
By following these efforts, SRI Noida hopes to contribute to a better world and a richer
experience for all.

1.10 Vision of SRI, Noida includes, following three strategies:

Technology: The first foremost objective of SRI Noida is to make optimum use of best
technology for the research and development.

Innovation: We believe in constant and continuous improvisation of techniques, methods


and processes to obtain the innovative product.

Creative Solutions: To make the product more customer-centric, we follow new ideas
and provide creative solutions for additional features.

1.11 Samsungs Values


We believe that living by strong values is the key to good business. At Samsung, a rigorous code
of conduct and these core values are at the heart of every decision we make.

People: Quite simply, a company is its people. At Samsung, were dedicated to


giving our people a wealth of opportunities to reach their full potential.

Excellence: Everything we do at Samsung is driven by an unyielding passion for


excellence and an unfaltering commitment to develop the best products and services on
the market.

Integrity: Operating inan ethical way is the foundation of ourbusiness. Everything we do


is guided by a moral compass that ensures fairness, respect for all stakeholders and
complete transparency.

Co-prosperity: A business cannot be successful unless it creates prosperity and


opportunity for others. Samsung is dedicated to being a socially and environmentally
responsible corporate citizen in every community where we operate around the globe.

1.12 TECHNOLOGY
Wireless
SRI Noida is involved in development and testing of extensive range of mobiles software by the
combination of exceptional talent and superior technology.
The focus of SRI center is to produce best quality mobile phone software in both CDMA and
GSM technologies. The center has talented and development activities are carried out in ideal
manner to stabilize every model in terms of quality, features and enhancement. The dedicated
team works in coordination with other centers across the world to produce high quality mobiles
considering various factors such as market research, target customers, competing products etc.

1.13 Key Technologies features of SRI Noida R&D


Mobile platforms (BREW, APOXI, Windows Mobile, J2ME), device driver and different
OS
MMI customization
Mobile features and application development
Java TCK and J2ME application development
Protocols and Standards such as E-mail, MMS, Sync, ML, XML, GCF etc.

1.14 Future Trend and New Technologies


SRI Noida is continuously strengthening its skills sets on the future technologies such as 3G and
4G. The center is constantly engaged in BADA application development which is going to be the
platform for the future smart phones, containing hundreds of applications. These versatile have

proved a success in the world market with affordable price, magnificent features and variety
applications.

olution

Apart from research and development, SRI Noida is also occupied in the creations of new ideas
and providing solutions by analyzing the customers view point and prospective. For India
region, the center is involved in following solutions:

Mobile Prayer

Indian Calendar

Mobile Tracker

Dictionary

IMEI Tracker

At SRI Noida, the company aims to emerge as a center of excellence for research, development,
testing and solutions in wireless communication. Its target is to expand strong technological base
in South West Asia region for carrying out research work, nurturing the local talent and
exploring the market.

Services
Corporate competitiveness, in the era of global competition, begins from understanding its
customers- knowing who they are, what they want, and how they are changing. In this regards,
Samsung is fully committed to understanding its customers across all functions from
development and production to marketing and after-sales services, as well as to changing its
thinking and working processes to serve them better with innovative products and services.
Samsung Electronics is focusing ongoing innovation activities in the overseas markets to
strengthen its edge in service. Excellence in after sales service is an important goal in the
overseas markets. To offer swift and convenient service, 14,000 service centers are available
overseas as of 2009. In regions where there are relatively frequent requests, it has 400 directlyrun service centers. Samsung is also expanding its service network in Central Asia and Africa.
Samsung Electronics is devising service schemes tailored to each product and regional
characteristics to offer greater customer satisfaction. To this end, we conduct global customer
satisfaction surveys every year. The outcome of the survey is used in drawing up improvement
actions to raise customer satisfaction levels.
Optimal supply of parts is essential in providing speedy after service. For this purpose, it has
developed the demand forecast method for specific parts to improve supply capability and
inventory status. Under the program, the company is able to carry out diverse improvement
actions for prompt after service including maintaining sufficient inventory of materials that are
expected to have most usage in repair work.
At Samsung Electronics, all the new products under development must pass the demanding CS
certificate program in order to go into production. The program is designed to identify and
address potential problems when applying new functions and designs at the development stage to
ensure highest quality. Items for mandatory certification are identified at the development stage.
The product can proceed to the next stage only after completing the quality assessment at each
phase. The executive council conducts the final quality check.

Samsung Electronics is committed to delivering safe and quality products to its customers. It
tests all elements that can compromise product safety by considering a specific products use in
real life settings. All Samsung Electronics products sold are subjected to a battery of tests in
normal and abnormal conditions. To conduct the tests, Samsung Electronics operates an
internationally accredited laboratory certified by 27 accreditation bodies in Korea and 12 other
countries that ensures internationally-accepted quality assurance standards in the areas of testing
environment, facility, workforce and quality system, and that each accreditation body recognizes
the companys testing ability. It is also a testament to Samsung Electronics proven capabilities
in inspecting product safety to the satisfaction of customers. In 2009, Samsung was certified as a
CTIA Authorized Test Lab (CATL) by the Cellular Telecommunication & Internet Association,
the international wireless association based in the U.S.

Products
The product range of Samsung varies from one to vivid digital equipment that ranks in the top
range of items available in the market. The range includes Mobile phones, Televisions,
Audio/Video devices, Cameras and Camcorders, Home appliances, PCs, Peripherals, Printers
and Samsung Apps. Samsung apps, a proprietary to Samsung, are a special section of
applications meant basically for enhancing the features and usability of Samsung products.

1.15 Mobile
From the conventional and Smartphones, to the touch-screen, bars, sliders and feature-rich
devices with full QWERTY keyboard, Samsung has a wide range of products in the fields of
mobile handsets. The range of mobile devices vary from Tablet Smartphones, Smartphones,
Dual sim phones, Touch phones, Qwerty messaging phones, Multimedia phones, CDMA phones
to essential phones.
Among tablet Smartphones, Galaxy Tabs are the basic class of devices introduced in the market.
While Smartphones include the Samsung Galaxy and Wave models, dual sim phones like duos
and star duos and several other models are available in the market. Touch phones supported by
Touch wiz Lite technology are also available in models like Nexus, Corby, Galaxy, Star, Wave
etc. QWERTY messaging phones like Corby and Omnia series are the phones that provide
QWERTY keyboard support. Among multimedia phones Hero, Metro, Corby, Guru and almost
all the models have the multimedia support feature. Some Galaxy, Corby and MPower models
do support the CDMA features also. Guru series and a few other models are available that are
available with minimal but basic mobile features at cheapest possible prices. Mobile phone
accessories like headphones, Bluetooth headphones etc. are also available.

1.16 Other digital appliances


Among other digital media, Samsung televisions with full HD (high definition), Bluetooth
enabled, LED televisions are also available apart from the general models available. Other
Audio/Video support devices like Blu-ray players, DVD players, Home theatres, Multimedia
players, Projectors etc. are also available that incorporates the latest digital media technologies.
The camera and camcorder devices and home appliances product range like refrigerators,
washing machines, air-conditioners, microwave ovens, smart-ovens etc. are also leading their
respective markets.
Samsung PCs, Laptops, Notebooks, peripherals like optical disk drives, external hard disks,
printers etc are also there, which are the classic examples of use of latest technologies and
innovations that Samsung warmly welcomes all the time.

1.17 Samsung Apps


Developing an application for a connected device has become a highly desirable project for
determined individuals and big businesses alike. With Samsungs hardware an application
developer can push the boundaries of imagination while engaging with an audience of millions.
Convergence is the norm, with applications built for multiple platforms and multiple devices at
any one time. Software as a service via the internet has challenged traditional distribution
methods and the world is waiting for the dust to settle on the key devices launched in 2010.
Cloud computing has enabled millions of users to seamlessly live out their digital lives and there
are more exciting developments to come. Helping us see through these turbulent times and get
our ideas from the drawing board to the customer is Samsung Apps has tried to do.
Samsung Apps is a marketplace designed to provide a variety of mobile applications specially
developed and carefully selected for Samsung. Samsung Apps allows simply and easily
downloading an abundance of applications to the phone. Featuring a wealth of games, news,

reference, social networking, navigation and more applications, Samsung Apps makes the
Smartphone smarter.

1.18 Samsung Excellence Centers

429 offices in 68 countries

30 Manufacturing Subsidiaries

51 Sales Subsidiaries

1 Manufacturing and Sales Subsidiaries

2 Distribution Centers

18 R&D Centers

6 Design Centers

77 Branch Offices

2. Project Introduction
Hive is a collection of android applications aimed at targeted solutions to some of the most
basic problems a user faces. I have briefly described the need and underlying requirement
of the products. Different applications serve different purpose and are discussed in detail as
follows:-

2.1 OTP Fetch


This is one of the key applications of Hive. It is an android application aimedat
solving the basic user problem of asking for One Time Passwords when the OTP is
delivered to a different person. Since One Time Passwords are deemed to be
confidential to a certain level both the users need to be paired manually before using
the message transferring capabilities. This prevents any un-authorized use of the
application and enhancing security of user personal information.
The goal is simple to fetch OTP from another device to the requesting device. Hive
achieves this goal by using the capabilities of the android platform and Google
Cloud Messaging. This is achieved by a two-step process.

2.1.1

Authentication- In the present age where we are surrounded by digital


devices,protecting ones personal information is a necessary and difficult task. The
authentication process involves a secure Bluetooth channel so that the devices in the
nearby vicinity can be paired up securely. Connection is established using an
encrypted Bluetooth RFCOMM channel. Once a connection is established the
devices use the applications UUID to identify each other and share each others
credentials and save them for future use.

2.1.2

Request for OTP - After the successful completion of the authentication


processthe user can then proceed to fetch OTP. All the authenticated users are shown

on the applications main screen where he/she can choose which user to get the OTP
from. The delivery of messages uses GCM.

2.2 Call Notes


Many times we feel the need to write something down while on a
call. This application provides the functionality to create or edit notes while
the user is on a call. The notes are in the form of floating notification.
It has two main components.

2.2.1 Application Interface


This interface enables the user to choose the contact to he/she wants enable the
call notes on. Once enabled whenever a call is made or received the call note
would be displayed on the device.

2.2.2 Background Service


This service runs continuously in the background and performs a
number of functions. The functions are listed below:

Listen to Call broadcasts The service has Broadcast managers defined for both
incoming and outgoing calls made to or by the device. Whenever a call is made
or received these broadcast managers define the next action.

Show pop-up notification If you have used facebook messenger you must have
observed the popup notification. This is based on the same concept. A popup
window opens after a call is made/received and on this popup you can
view/edit/save the call note.

2.3 Encryptor

This application is a developer purpose package. It takes a file as its inputand outputs
MD5 ,SHA1, SHA256 digest of the file. It can be used by the developer while
pushing out application packages so as that the end user can verify if the incoming file
is authentic or not.

2.4 Resolution Finder


This is also a developer purpose package. At Samsung we have aRange of devices for
which applications need to be developed rapidly. Since most of the devices are of
different Resolution and screen densities developer needs to create the formats
accordingly. This application simply needs to be installed in a particular device and it
outputs the Resolution, Screen Density and its mode (Landscape or Portrait).

3. Background
On the beginning of the internship we were told that Samsung focusses on OJT ( On the
job training). Since Samsung is a dynamic organization and products are released every
week my mentor asked me to aim at trivial problems any user or developer faces in the
current android scenario which can be addressed and may even be implemented by
Samsung in its future products. All the applications in the Hive package are targeted
towards this goal.

3.1 Project Components


Hive has two suites. The user suite and the developer suite. Both have been developed
according to industry standards and coding schemes.

3.1.1 User Suite


The user suite has two applications.

OTP Fetch
Call Notes

Each application has two main components.

Providing Functionality across devices


Securing User Data

o Functionality
1. OTP Fetch
For OTP Fetch all the authenticated users are shown on the applications main
screen where he/she can choose which user to get the OTP from.
The delivery of messages uses GCM.
The requesting user selects the user from the list from which to fetch the OTP.
Unique GCM IDs of the authenticated devices are stored in the SQLite database.
A message, in the JSON format, is sent to the target device using GCM service
over the mobile internet/ WiFi /Ethernet. The receiving device identifies the
sender and sends the OTP back using the same GCM service it in real-time.
Usecase:
The aim of Hive is to target the problem of asking for One Time Passwords in a
scenario where the OTP initiator is different from the OTP receiver.
Ex. A father asks his son to perform some transaction which requires an OTP
sent to the fathers mobile (registered) for successful completion of the
transaction. There may be the case that father is in an urgent meeting and cant
take any phone calls or messages. In such a scenario Hive assists the son to get
the OTP without any hassles.

2. Call Notes

In call notes you can select a user from your contacts and add a note with a title
and body . This interface enables the user to choose the contact to he/she wants
enable the call notes on. Once enabled whenever a call is made or received the
call note would be displayed on the device.
Call notes make use of Androids Sticky service in which even if the application
is not running, a service keeps running in the background listening for incoming
and outgoing calls.
Usecase:
If your are the kind of person who needs to call someone multiple times because
you keep forgetting something each time, this app is for you.With Call Notes, you
can keep track of things or points you wish to discuss with a person. Whenever
you call that person, the respective note will popup on screen. You can also make
changes to the note while in-call or you can create/edit notes after the call.
o

Security

1.OTP Fetch
In any application securing user data is one of the major concerns. Since OTPs
are semi confidential information for the users eyes only, security has been
topmost concern.

Authentication
In the present age where we are surrounded by digital devices, protecting ones
personal information is a necessary and difficult task.
The authentication process involves a secure Bluetooth channel so that the
devices in the nearby vicinity can be paired up securely. Connection is
established using an encrypted Bluetooth RFCOMM channel. Once a
connection is established the devices use the applications UUID to identify
each other and share each others credentials and save them for future use.

Storage
Hive makes use of Android Keystore System. User GCM IDs are stored in the
database after Symmetric Encryption and the keys are stored in the Android
Keystore.

For security purposes the One Time Passwords that a user pulls from
another user are not stored.

3.1.2 Developer Suite

The developer suite has following two applications

Encryptor
Resolution Finder

3.2 Work Overview


Under the project Hive, the following tasks were assigned to me:

1.Building OTP Fetch and Call Notes as a part of user based applications
2.Building Developer suite applications Encryptor and Resolution Finder.
3.

Testing

both

suites

comprehensively

to

match

industry

standards.

3.3 Project Completion Plan


The Phases involved in the completion of the project are :
Concept analysisand Requirements Analysis and POC: This phase involved
learningand discovering various new technologies used in the project. I had to
understand the basic concepts of Java and Android.. This phase also involved
analysing the requirements of the project, discussing details and gathering
information in collaboration with the mentor.

Systems design and Structure: This phase involved designing the actual system
andconverting the requirements into suitable modules. Database for each applications
was designed and UI was decided upon
Implementation:This phase witness the actual development of the project and
turningthe project into actual program. Work on android application was done
according to the requirements and UI elements.
Testing: Thisphase will engage in testing and debugging. All the issues are recorded.
The issues are then resolved and tested again.

3.4 Motivation
Below are the listed motivation for doing this project
The motivation for doing this project was primarily an interest in undertaking a
challenging project in an interesting area of real life problem.
The opportunity to learn about new areas of computing not covered in lectures was
appealing. Opportunity to learn new technologies, tools and languages.
The opportunity to work with teams.

4. Platform and Techniques


4.1 Android
Android is a mobile operating system (OS) currently developed by Google, based on
the Linux kernel and designed primarily for touchscreen mobile devices such as
smartphones and tablets. Android's user interface is mainly based on direct
manipulation, using touch gestures that loosely correspond to real-world actions, such
as swiping, tapping and pinching, to manipulate on-screen objects, along with a virtual
keyboard for text input. In addition to touchscreen devices, Google has further

developed Android TV for televisions, Android Auto for cars, and Android Wear for
wrist watches, each with a specialized user interface. Variants of Android are also used
on notebooks, game consoles, digital cameras, and other electronics.
Android applications run in a sandbox, an isolated area of the system that does not
have access to the rest of the system's resources, unless access permissions are
explicitly granted by the user when the application is installed. Before installing an
application, Play Store displays all required permissions: a game may need to enable
vibration or save data to an SD card, for example, but should not need to read SMS
messages or access the phonebook. After reviewing these permissions, the user can
choose to accept or refuse them, installing the application only if they accept The
sandboxing and permissions system lessens the impact of vulnerabilities and bugs in
applications, but developer confusion and limited documentation has resulted in
applications routinely requesting unnecessary permissions, reducing its effectiveness.
Google has now pushed an update to Android Verify Apps feature, which will now run
in background to detect malicious processes and crack them down.
In Android 6.0 Marshmallow, the permissions system was changed to allow the user
to control an application's permissions individually, to block applications if desired
from having access to the device's contacts, calendar, phone, sensors, SMS, location,
microphone and camera. Full permission control is only possible with root access to

the device.

Figure 1AndroidOS Architecture

4.2 Bluetooth
The Android platform includes support for the Bluetooth network stack, which allows
a device to wirelessly exchange data with other Bluetooth devices. The application
framework provides access to the Bluetooth functionality through the Android
Bluetooth APIs. These APIs let applications wirelessly connect to other Bluetooth
devices, enabling point-to-point and multipoint wireless features.
Using the Bluetooth APIs, an Android application can perform the following:
Scan for other Bluetooth devices
Query the local Bluetooth adapter for paired Bluetooth devices
Establish RFCOMM channels
Connect to other devices through service discovery
Transfer data to and from other devices
Manage multiple connections
All of the Bluetooth APIs are available in the android.bluetooth package. Some of the
classes and interfaces are required to create Bluetooth connections:
BluetoothAdapter
Represents the local Bluetooth adapter (Bluetooth radio). The BluetoothAdapter is the
entry-point for all Bluetooth interaction. Using this, you can discover other Bluetooth
devices, query a list of bonded (paired) devices, instantiate a BluetoothDevice using a
known MAC address, and create a BluetoothServerSocket to listen for
communications from other devices.
BluetoothDevice
Represents a remote Bluetooth device. Use this to request a connection with a remote
device through a BluetoothSocket or query information about the device such as its
name, address, class, and bonding state.

BluetoothSocket
Represents the interface for a Bluetooth socket (similar to a TCP Socket). This is the
connection point that allows an application to exchange data with another Bluetooth
device via InputStream and OutputStream.
BluetoothServerSocket
Represents an open server socket that listens for incoming requests (similar to a TCP
ServerSocket). In order to connect two Android devices, one device must open a server
socket with this class. When a remote Bluetooth device makes a connection request to
the this device, the BluetoothServerSocket will return a connected BluetoothSocket
when the connection is accepted.

4.3 Google Cloud Messaging: Overview


Google Cloud Messaging (GCM) is a service that enables developers to send
messages between servers and client apps. This includes downstream messages from
servers to client apps, and upstream messages from client apps to servers.
For example, a lightweight downstream message could inform a client app that there
is new data to be fetched from the server, as in the case of a "new email" notification.
For use cases such as instant messaging, a GCM message can transfer up to 4kb of
payload to the client app. The GCM service handles all aspects of queueing of
messages and delivery to and from the target client app.
Architectural Overview
A GCM implementation includes a Google connection server, an app server in your
environment that interacts with the connection server via HTTP or XMPP protocol,
and a client app.

Figure 2 GCM Architecture

Here's how these components interact:

Google GCM Connection Servers accept downstream messages from your app
server and send them to a client app. The XMPP connection server can also
accept messages sent upstream from the client app and forward them to your

app server. For more information, see About GCM Connection Server.
On your App Server, you implement the HTTP and/or XMPP protocol to
communicate with the GCM connection server(s). App servers send
downstream messages to a GCM connection server; the connection server
enqueues and stores the message, and then sends it to the client app. If you
implement XMPP, your app server can receive messages sent from the client

app.
The Client App is a GCM-enabled client app. To receive and send GCM
messages, this app must register with GCM and get a unique identifier called a
registration token. For more information on how to implement the client app,
see the documentation for your platform.

4.4 Threading
In computer science, a thread of execution is the smallest sequence of programmed
instructions that can be managed independently by a scheduler, which is typically a
part of the operating system.The implementation of threads and processes differs
between operating systems, but in most cases a thread is a component of a process.
Multiple threads can exist within one process, executing concurrently and sharing

resources such as memory, while different processes do not share these resources. In
particular, the threads of a process share its executable code and the values of its
variables at any given time.
Multithreading is mainly found in multitasking operating systems. Multithreading is a
widespread programming and execution model that allows multiple threads to exist
within the context of one process. These threads share the process's resources, but are
able to execute independently. The threaded programming model provides developers
with a useful abstraction of concurrent execution. Multithreading can also be applied to
one process to enable parallel execution on a multiprocessing system.
Multithreaded applications have the following advantages:

Responsiveness: multithreading can allow an application to remain responsive


to input. In a one-thread program, if the main execution thread blocks on a
long-running task, the entire application can appear to freeze. By moving such
long-running tasks to a worker thread that runs concurrently with the main
execution thread, it is possible for the application to remain responsive to user
input while executing tasks in the background. On the other hand, in most
cases multithreading is not the only way to keep a program responsive, with
non-blocking I/O and/or Unix signals being available for gaining similar

results.[6]
Faster execution: this advantage of a multithreaded program allows it to
operate faster on computer systems that have multiple central processing units
(CPUs) or one or more multi-core processors, or across a cluster of machines,
because the threads of the program naturally lend themselves to parallel
execution, assuming sufficient independence (that they do not need to wait for

each other).
Lower resource consumption: using threads, an application can serve multiple
clients concurrently using fewer resources than it would need when using
multiple process copies of itself. For example, the Apache HTTP server uses
thread pools: a pool of listener threads for listening to incoming requests, and a

pool of server threads for processing those requests.


Better system utilization: as an example, a file system using multiple threads
can achieve higher throughput and lower latency since data in a faster medium

(such as cache memory) can be retrieved by one thread while another thread
retrieves data from a slower medium (such as external storage) with neither

thread waiting for the other to finish.


Simplified sharing and communication: unlike processes, which require a
message passing or shared memory mechanism to perform inter-process
communication (IPC), threads can communicate through data, code and files

they already share.


Parallelization: applications looking to use multicore or multi-CPU systems
can use multithreading to split data and tasks into parallel subtasks and let the
underlying architecture manage how the threads run, either concurrently on
one core or in parallel on multiple cores. GPU computing environments like
CUDA and OpenCL use the multithreading model where dozens to hundreds
of threads run in parallel across data on a large number of cores.

Threading has been extensively used on the Android applications for better system
performance and user interaction.

4.5 MD5/SHA1/SHA2

The MD5 message-digest algorithm is a widely used vulnerable cryptographic hash function
producing a 128-bit (16-byte) hash value, typically expressed in text format as a 32-digit
hexadecimal number. MD5 has been utilized in a wide variety of cryptographic applications and
is also commonly used to verify data integrity.
MD5 is a one-way function; it is neither encryption nor encoding. It can be
reversed by brute-force attack and suffers from extensive vulnerabilities as
detailed in the security section below.

SHA-1 forms part of several widely used security applications and protocols, including TLS and
SSL, PGP, SSH, S/MIME, andIPsec. Those applications can also use MD5; both MD5 and SHA1 are descended from MD4. SHA-1 hashing is also used indistributed revision control systems
like Git, Mercurial, and Monotone to identify revisions, and to detect data corruption or
tampering. The algorithm has also been used on Nintendo's Wii gaaming console for signature

verification when booting, but a significant flaw in the first implementations of the firmware
allowed for an attacker to bypass the system's security scheme. [12]
SHA-1 and SHA-2 are the secure hash algorithms required by law for use in
certain U.S. Government applications, including use within other cryptographic
algorithms and protocols, for the protection of sensitive unclassified information.
FIPS PUB 180-1 also encouraged adoption and use of SHA-1 by private and

commercial organizations
SHA-2 (Secure Hash Algorithm 2) is a set of cryptographic hash functions designed by the
National Security Agency (NSA). SHA stands for Secure Hash Algorithm. Cryptographic hash
functions are mathematical operations run on digital data; by comparing the computed "hash"
(the output from execution of the algorithm) to a known and expected hash value, a person can
determine the data's integrity. For example, computing the hash of a downloaded file and
comparing the result to a previously published hash result can show whether the download has
been modified or tampered with.[4] A key aspect of cryptographic hash functions is their collision
resistance: nobody should be able to find two different input values that result in the same hash
output.
SHA-2 includes significant changes from its predecessor, SHA-1. The SHA-2 family consists of
six hash functions with digests (hash values) that are 224, 256, 384 or 512 bits: SHA-224, SHA256, SHA-384, SHA-512, SHA-512/224, SHA-512/256.

5. Project Design
5.1 OTP Fetch DFD

Figure 3 OTP DFD Level 0

Figure 4 OTP DFD Level 1

5.2 Call Notes DFD

Figure 5 Call Notes DFD level 0

Figure 6 Call Notes

DFD Level 1

Figure 7 Call Notes DFD Level 2

6. Implementation
Concept analysisand Requirements Analysis and POC: This phase involved learningand
discovering various new technologies used in the project. I had to understand the basic concepts of
Java and Android.. This phase also involved analysing the requirements of the project, discussing
details and gathering information in collaboration with the mentor.
Systems design and Structure: This phase involved designing the actual system andconverting
the requirements into suitable modules. Database for each applications was designed and UI was
decided upon
Implementation:This phase witness the actual development of the project and turningthe project
into actual program. Work on android application was done according to the requirements and UI
elements.

Testing: This phase will engage in testing and debugging. All the issues are recorded. The
issues are then resolved and tested again.

7. Testing
7.1 OTP Fetch Test Cases
TC Id
OTP_M_1

OTP_M_2

OTP_M_3

OTP_M_4
OTP_M_5

Test
Descriptio
n
Application
should not
crash on launch
Application should
switch activities
without stacking up
and without crash
Clicking on
Bluetooth button
should ask
permission to turn
on Bluetooth if not
enabled
Nearby Bluetooth
devices need to be
scanned
Authenticate
devices

OTP_M_6

OTP fetch test

OTP_M_7

Deleting the
authenticate device

Test
Procedure
Install the
application on
mobile device and
click on its icon
Start the
application and
click on all
buttons.
Click on
Bluetooth button
inside the
application
Click on Search
devices button
Click on any
device name to
authenticate
Select the device
from trusted
device to fetch the
device
From the trusted
device list ,
choose the device
to be deleted

Accepted
Behavior
No crash

Result
No crash

Activities should
not stack and
application should
not crash
Clicking on
Bluetooth button
should ask
permission to turn
on Bluetooth if
not enabled
Nearby Bluetooth
devices should
show up
Device should be
added in the
trusted list
OTP should be
fetched from the
device

Activities do not
stack up and
application does
not crash
Permission to turn
on Bluetooth is
asked

Device should be
deleted and we
should not be now
able to fetch the
OTP from the
same

Device deleted
and OTP not
fetched from the
device.

Nearby devices
are shown
Device added in
the trusted list
OTP fetched
successfully

7.2 Call Notes Test Cases

TC Id

Test Description

Test Procedure

CNO_M_1

Notes display

Create a note for a


contact using the
app interface

CNO_M_1

Application should
not crash on
launch

CNO_M_2

CNO_M_3

Application should
switch activities
without stacking
up and without
crash
Add new note

Install the
application on
mobile device and
click on its icon
Start the
application and
click on all
buttons.

CNO_M_4

Add new note

CNO_M_5

Start PopUp
service

CNO_M_6

Show notes during


call

Click on + button
and add title,
description and
add contact
Click on + button
and add title,
description and
add contact. Click
in tick button.
Go to settings
icon and tap on
Start Service
Make a call to the
contact for which
a note is saved

Accepted
Behavior
The saved note
text should popup
when that contact
is called or is
calling
No crash

Result

Activities should
not stack and
application should
not crash

Activities do not
stack up and
application does
not crash

Contact List
should be shown

Contact List is
shown

Note should be
saved and
displayed on
home screen

Note is saved

Service should be
started

Service is
started(Verified
using LogCat)
A yellow text box
pops up

A yellow text box


should pop up

Note is displayed
as saved in the
overlay window
on top of other
apps
No crash

7.3 Res Finder and Encryptor Test Cases


TC Id

Test Description

Test Procedure

RES_M_1

Resolution finder

Test the app on


different
resolution devices

TC Id

Test Description

Test Procedure

ENC_M_1

encryptor

Select file from


the app

Accepted
Behavior
The app interface
should show the
proper resolution
and orientation of
the device
Accepted
Behavior
Selected apps
SHA1 SHA256
and MD5 dump
should be created

Result
Proper resolution
and orientation of
the device is
shown on app
interface
Result
Dumps are
created
succesfully

8. Results
8.1 LEARNING
Undertaking a challenging project in a leading company not only helped me to
understand the the working culture of IT firms but also gave me an opportunity to learn
about new areas of computing, new tools, technologies and languages not covered in
lectures in college. The project Hive helped me to increase my knowledge set as I
learnt following new technologies and used them to complete the project:
Java : I was proficient in C/C++ and this was my first time dabbling in Core Java and its
concepts such as Singleton classes.
Android :Android was used to create all the applications.
Bluetooth APIs: I had to go through the Bluetooth API documentation for android to
understand its concepts and implement it
Threading: Although I have learnt threading in OS but this was the first time I
implemented it in a project.

Apart from these new tools and technologies, the languages and technologies
learnt in college helped in the completion of the project.

8.2 Snapshots
Here are a few snapshots of Hive Applications which will display some its
features

Figure 9 OTP Bluetooth pairing

Figure 10 Fetched One Time


Password from another device

Figure 8 OTP Trusted Devices

Figure 11 1Long press options

Figure 11
Figure
Saved
12Notes
Saved notes

Figure 13 1Call notes shown

50

9. LIMITATIONS AND CHALLENGES


Main challenge was to learn and implement new technologies in short period of time. Keeping in
mind the time and space complexities of the code developed was also one of the challenges faced
in developing the project. It was also a challenge to work under organizational constraints

10. FUTURE WORK


As the project is currently in test phase, there is still scope of some future work.
Adding features to Hive applications.
Resolving issues while testing and deploying

51

You might also like