Validate the decrypted IV before creating a reader/writer.

This commit is contained in:
akwizgran
2011-10-18 15:58:10 +01:00
parent 2f457162a5
commit d7a417f36d
18 changed files with 121 additions and 80 deletions

View File

@@ -40,7 +40,7 @@ public class ConnectionWriterTest extends TestCase {
ByteArrayOutputStream out =
new ByteArrayOutputStream(MIN_CONNECTION_LENGTH);
ConnectionWriter w = connectionWriterFactory.createConnectionWriter(out,
MIN_CONNECTION_LENGTH, true, transportId, connection, secret);
MIN_CONNECTION_LENGTH, transportId, connection, secret);
// Check that the connection writer thinks there's room for a packet
long capacity = w.getRemainingCapacity();
assertTrue(capacity >= MAX_PACKET_LENGTH);