Encrypt files

You can encrypt files on the file system. This provides two things:

  1. Protection of the client private key for TLS authentication while it is stored on the XBee Smart Modem.
  2. Protection for user's MicroPython applications.

Use ATFS XPUT filename to place encrypted files on the file system. The XPUT operation is otherwise identical to the PUT operation. Files placed in this way are indicated with a pound sign (#) following the filename. The XBee Smart Modem does not allow an encrypted file to be read by normal use so it:

  1. Cannot be retrieved with the GET operation.
  2. Cannot be opened and read in MicroPython applications.
  3. Cannot be created by a MicroPython application.

When ATFS HASH filename is run with the filename of an encrypted file, it reports the SHA256 hash of the file contents. In this way you can validate that the correct file has been placed on the XBee Smart Modem.