Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I developed a p2p-app in C# which sends and receives encrypted text messages (50

ID: 651432 • Letter: I

Question

I developed a p2p-app in C# which sends and receives encrypted text messages (50KB). For encryption, my app uses AES 128 bit in CBC cipher mode. For each message it uses a new randomly-generated IV.

Whatever, after reading the following two publications I have some concerns about my solution:

+ First solutions for SSL/TLS vulnerability
+ Vulnerability in SSL/TLS Could Allow Information Disclosure

I'm not an expert in encryption so my question is very simple: Do I have to replace CBC with another cipher mode or is it still secure in my scenario?

Since my app uses the RijndaelManaged class in C#, my alternatives are: CFB, CTS, OFB.

Explanation / Answer

The attack is due to predictable initialization vectors. If you're using a new random IV for each message the attack doesn't apply.

In pre-1.1 versions of TLS, each record's IV is the last ciphertext block of the previous record; this can be used to influence the IVs used by the server.

This is fine within a message, but the problem comes when you continue to chain cipher blocks from one message to the next.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote