10.09.2016 Views

Hacking_and_Penetration_Testing_with_Low_Power_Devices

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Adding security<br />

187<br />

a different channel <strong>and</strong> PAN ID has little chance of being noticed. This is a form of<br />

security through obscurity that is not really security at all.<br />

You may be tempted to just automatically start encrypting all your traffic. Before<br />

you do so, realize that there are certain drawbacks to adding encryption. First,<br />

encryption adds computational overhead. Second, encryption increases latency<br />

thanks to the time it takes to encrypt <strong>and</strong> decrypt each packet. Third, the maximum<br />

packet size is reduced when encryption is enabled. This means that more packets will<br />

be required <strong>and</strong> that some of the scripts provided in this chapter must be updated<br />

when encryption is used. Finally, encryption adds complexity. If all modems aren’t<br />

using the same encryption key, things will not work properly. These types of problems<br />

tend to be hard to diagnose.<br />

Should you decide to encrypt an XBee network, the process is straightforward.<br />

For Series 1 modems, enable encryption by setting the EE (encryption enable)<br />

parameter to 1 <strong>and</strong> then store your chosen AES encryption key (of at most 32 characters)<br />

in the KY variable on each modem in the network. Don’t forget to save your<br />

changes to the modem. Note that the KY value cannot be read, only set. Figure 7.11<br />

shows how these values can be set in the X-CTU software.<br />

Enabling encryption on Series 2 routers <strong>and</strong> end devices is very similar to the<br />

Series 1 case. The EE value is set to 1 <strong>and</strong> the KY value to the chosen key. Setup<br />

of a router is shown in Figure 7.12. The coordinator in a ZigBee network has an<br />

FIGURE 7.11<br />

Enabling encryption <strong>with</strong> Series 1 XBee modems.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!