UDP and AES with C++ I'm implementing different applications that will use UDP to exchange real-time data, thus a low impact on performance is very important. This system will not be connected to the Internet so I just need a symmetric encryption mechanism and one option would be AES-128. I am googling a lot but I am not finding a lot of material about the combination of AES, UDP and C++, is it not used much? Any resources would be really appreciated!

Would DTLS be an appropriate choice for this case in this private LAN far away from the internet?



I've posted a similar question on Information Security SE with more details (after the answers here came in).
Consider using Noise.  If that's too heavy, consider using NaCl crypto_secretbox, at least.

Now that we've got that out of the way: Write down a design document that articulates what you're trying to enable the legitimate parties to achieve with what resources, enumerates the powers of an adversary, and identifies the security properties you hope to guarantee in the face of an adversary.  Do this without mentioning cryptography!  You need to be specific about what resources the adversary can subvert and how—read packets on the wire, replace them, act maliciously to peers in some way—and specific about what you want to guarantee they can't do in spite of those powers.

Then you can use that design document decide what cryptography to use to provide those security properties, and anyone else studying your system can use that design document to assess whether you did it sensibly.  Simply putting the letters A-E-S or D-T-L-S in your application means approximately nothing other than that you used everyone's favorite pseudorandom permutation family or the unloved cousin of a protocol whose family gave us Heartbleed.