redge wrote:thank you for the explanation, there the hole, use silently the vnc password instead the key or key not enough encrypted let another key used instead check the requirement is not enough for start encrypted connection. ie key don't have enough data .
Yes, that does sound like undesirable app behavior. Maybe should be popup warning?
How the receiver can know the vector if sender send it at random ?
I stop thinkinh about that. Mathematical make me headache. too complicate.
Well, forgive me adding to the headache...
The first 32 bytes of the session data stream are random salt (16B) and random initialization vector (16B) the sender created on his computer for this vnc connection. Everything after these first 32 bytes is the encrypted VNC traffic from the sender.
So the receiver now has these 32 bytes. Any eavesdropper snooping the connection also has them. But that is OK, because these bytes are not the session key (i.e. the key used for this VNC connection), they are just used to be scrambled with the shared secret key (e.g. aesv2.key data) to form a unique session key for this VNC connection.
By using different session keys each time, the eavesdropper has a much harder time trying to crack the encrypted VNC traffic.
The "scrambling" is just a MD5 (MD=message digest) checksum, are you familiar with that? Headache?