This article presents a secure routing scheme based on the ESP NOW protocol of ESP32 microcontrollers. In addition to security specific to this protocol, the data transmitted is encapsulated in a symmetric cryptography algorithm based on binary and hash cryptographic functions. A unique encryption and decryption key is used when sending and receiving data. The algorithm is written in C++ program in the form of a library and included in an Arduino sketch. The sensor node calls the library for encryption and the central node uses this same library to decrypt the message received and restore the encrypted information. The tests are carried out on a network made up of two ESP 32, each coupled with a DHT11 sensor which sends the information to a central node for control and monitoring. The results obtained optimize data security in networks based on ESP NOW communication protocols. The goal is to contribute to the reinforcement of data transmission security for a sensor network within a logistics transport chain equipped with temperature and humidity sensors.