Long response follows for a difficult subject......
For all encryption problems you have to think of the client application encrypting the data, transmitting it, and the receiver decrypting it back to the original.
The transmit phase is the point where sniffers/hackers may be able to see the data on the wire.
If your transmit medium is a physical cable then its easy - as its hard for a sniffer to plug in an extra cable to see the messages without you noticing.
But once you go with a wireless medium, at a robo competition say, then there may be lots of other folks (hackers) with their own wireless laptops.
Lets take the simple scenario of 'no encryption'. You type the password 'ABCDEF' into Hyperterminal on your laptop and each character is sent over the wireless link. It is received by the robot but also by all the hackers. They now know your password and can use it themselves. So the addition of a password is useless.
The next step is to apply encryption/decryption at both ends of the message. ie on your laptop you type in 'ABCDEF' but it gets sent as 'NO1DEG', the robot receives this and decrypts it back to 'ABCDEF'. Sounds cool. But first off all you cant use hyperterminal. You need to write a custom app for your PC that takes the characters 'ABCDEF' and encrypts them into 'NO1DEG' before sending them. In the meantime the hackers see 'NO1DEG' as the message going over the wireless. They may not know about the encryption mechanism but they dont have to. They can just type 'NO1DEG' into Hyperterminal to crack your code - they dont need to know that what you originally typed was 'ABCDEF'.
You could go a step further. ie when switching on the robot it could create a random key (from ADCs, IMU readings etc) that is used for encrypt/decrypt process - and in this way the key would be different every time. But your client app would need to know what key to use. The robot could send the key to the pc (un-encrypted). This would work and would be reasonsably secure. Howerver: if I make this part of WebbotLib then if any of the hackers have WebbotLib then their PC knows everything yours does ! Hence not a good thing to add to a library.
But lets go back and challenge the problem. Your robot is sending/receiving data to/from the PC. Does it matter if someone else can see it? Of course certain telemetry data could just be written to an sdCard for later review and never transmitted at all.
If the answer is YES then the simplest thing of all is to not let the hackers connect their laptop to your wireless link in the first place. So with Bluetooth, for example, you can say if it is a secure link and give a password. If the hackers dont know the password then they cannot join the wireless link - and so you don't then need to encrypt/decrypt the data on the link.But then thats a hardware thing and nothing that WebbotLib can do to facilitate.