Hello, welcome back to this course.
I will talk in this lesson about ZigBee security and exploitation. ZigBee is maintained by the ZigBee Alliance
and based on the IEEE 802.15.4 standard for Wireless Personal Area Network. From the ZigBee
Alliance website, of which the slide shows a screenshot, it is possible to retrieve various technical
in-depth material on ZigBee.
Let's see some technical characteristics of the protocol. ZigBee uses frequencies, 2.4 GHz,
915 MHz in USA and 868 MHz in Europe.
It uses 16 channels, each of 2 MHz
The data rate is 250 Kbits per second.
It supports network and application encryption using AES 128
And the communication range is between 75 and 100 meters indoors.
The ZigBee protocol is used in numerous Iot devices to handle short-distance data transmissions.
The slide provides a short list of such devices. Iot devices that use ZigBee are: devices for building automation
and smart home, such as smart locks, smart lightning, smart thermostats, security system, etc.
devices for smart health care, industrial control devices, etc..
ZigBee supports full-mesh networks with hundreds of devices for each individual network. In ZigBee devices
operating roles are:
ZigBee Coordinator,
It is the most intelligent device among those available, it forms the root of a ZigBee network and can act
as a bridge between multiple networks.
There can be only one coordinator in each network.
It is also capable of storing information about its network and can act as a repository for security
keys. The coordinator stores and distributes the network keys. In a ZigBee network
the coordinator cannot sleep and needs to be continuously powered.
Another role is the ZigBee Router, these devices act as intermediate routers, passing data to and
from other devices.
In fact, there are no hardware distinctions between a ZigBee Coordinator and a Router, except that the
coordinator is given the role of initializing the network, after which they become identical devices.
Similar to the coordinator,
Routers also cannot sleep as long as the network is established. And the last role is the ZigBee
End Device. End devices include only the minimum functionalities for communicating with the parent
node, coordinator or router.
They cannot transmit data from other devices and therefore do not participate in the multi-hop of a message.
They are the nodes that require the least amount of memory and therefore are often cheaper than router
or coordinator.
End Devices are what the customers are more familiar with, like motion sensors, contact sensors and
smart light bulbs.
The end devices also must join the network first to communicate with other devices.
The end devices can enter low power mode and sleep to conserve power.
The slide shows a graphic that visually represents the typical architecture of a ZigBee network showing
the various ZigBee devices and the roles covered in the hierarchy.
Here, the structure of the ZigBee protocol stack is shown, from the physical layer, media access control
layer, regulated by the standard IEEE, up to the network and security layer and application layer
both defined by ZigBee alliance.
Let's see some supported security measures. ZigBee uses 128 bit AES based encryption system.
It uses a frame counter to counteract the replay attacks.
The receiving end point always checks the frame counter and ignores duplicate messages.
ZigBee also supports frequency
agility that is network is relocated in case of jamming attack. Concerning network security model
supported by ZigBee. Two models are supported; a centralized security network and a distributed security
network.
They differ in how they admit new devices into the network and how they protect messages on the network.
A distributed security model provides a less secure and simpler system.
It has two devices types: routers and end devices.
Here, are a router can form a distributed security network when it can't find an existing network. Each
router can issue network keys. As more routers and devices join the network, the previous routers on
the network send the key. To participate in distributed security networks,
all routers and end devices must be pre-configured
with a link key that is used to encrypt the network key when passing it from a router parent
to a newly joined node. All the devices in the network encrypt messages with the same network key.
A centralized security model provides higher security.
It is also more complicated as it includes a third device type, the Trust Center (TC), which is usually
also the network coordinator. The Trust Center forms a centralized network, configures and authenticates
routers and devices to join a network.
The Trust Center establishes a unique TC link key for each device on the network as they join and
link keys for each pair of devices as requested.
The Trust Center also determines the network key. To participate in a centralized security network model,
all entities must be pre-configured with a link key that is used to encrypt the network key when passing it
from the TC to a newly joined entity.
ZigBee uses two types of encryption keys: a network key of 128 bit length, that is used for broadcasting
communications, and is shared among all devices (nodes), and must itself be protected by encryption when
it is passed to the joining node.
And Link keys
with the same length of 128 bit that is used for secure unicast communication, each one of the link keys
is shared only between two devices.
A vulnerability, regarding security keys, is linked to the initial phase of adding a new ZigBee device
to a network (the pairing phase), if it is used the pre-configured global cryptographic key ZigBee-defined
to encrypt the network key.
The slide shows the value of the pre-configured global key ZigBee-defined.
Has been discovered several security vulnerabilities of a ZigBee. For example, slide shows details
about a vulnerability found by Checkpoint researchers in Philips
Hue Bridge model 2.X not patched.
Another vulnerability has been discovered in the ZigBee protocol implementation on Texas Instruments
CC2538 devices.
Here are some typical vulnerabilities found in ZigBee Iot devices that do not fully implement the security
features of the protocol.
And they are: the insecure storage of keys; the attacker extract the key from the chip or from the ZigBee
network layer. The use of ZigBee predefine key for securing the initial key exchange. Insecure transport
of the key, such as plaintext transport of the key in OTA communications. The reuse of
initialization vectors, and no key rotation applied.
In order to check, in a vulnerability assessment of ZigBee device, the correct use of security features
provided by ZigBee, it is possible to use packet sniffing and analysis tools.
The slide shows a couple of hardware devices useful for ZigBee sniffing.
A popular software suite for ZigBee packet capture and analysis is the KillerBee project, downloadable
from GitHub.
The suite includes various command line tools, including the zbdump tool that allows the capture
of ZigBee data traffic packets. Some other notable tools included in the killerbee framework include
zbassocflood used to crash the device from too many connect to stations.
zbdsniff used to capture ZigBee traffic and return the key if found, and zbstumbler, an active
network discovery tool that sends beacon request frames out and returns the user information on discovered
devices.
The software suite can be used with supported hardware
devices where firmware for killerbee must be flashed.
For example, Apimote with killerbee supports, sniffing injection and jamming functionalities.
With zbdump tool, it is possible to capture ZigBee traffic and save the data traffic in
a file for subsequent inspection with a packet analyzer such as Wireshark.
OK, thank you for your attention bye.