Skip to content

Commit 3d0efa2

Browse files
authored
docs(transport): fix old/new mixup (#2039)
In the `path_forwarding_attack` unit test ``` rust /// This simulates an attack where a valid packet is forwarded on /// a different path. This shows how both paths are probed and the /// server eventually returns to the original path. fn path_forwarding_attack() { ``` data is send on two paths, a IPv6 path (aka. "old") and an IPv4 path (aka. "new"). Towards the end of the test it asserts one path, but mentions the other in the doc comment. This commit fixes the mix-up in the doc comment.
1 parent dad1c51 commit 3d0efa2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

neqo-transport/src/connection/tests/migration.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -166,10 +166,10 @@ fn path_forwarding_attack() {
166166

167167
// Until new data is received from the client on the old path.
168168
server.process_input(&client_data2, now);
169-
// The server sends a probe on the "old" path.
169+
// The server sends a probe on the new path.
170170
let server_data3 = send_something(&mut server, now);
171171
assert_v4_path(&server_data3, true);
172-
// But switches data transmission to the "new" path.
172+
// But switches data transmission to the old path.
173173
let server_data4 = server.process_output(now).dgram().unwrap();
174174
assert_v6_path(&server_data4, false);
175175
}

0 commit comments

Comments
 (0)