Skip to content

Commit 5ed8192

Browse files
authored
allow Non-ECT markings when validating (#394)
* fix: Allow non-ECN marks when validating Because I think the algorithm in RFC9000 says "probe with N marked packets, then check the ACKs", which implies that an implementation needs to stop marking after N to have a stable comparison value. * Simplify
1 parent 4980acb commit 5ed8192

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

testcases.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,11 +1113,7 @@ def _check_ecn_any(self, e) -> bool:
11131113
return e[ECN.ECT0] != 0 or e[ECN.ECT1] != 0
11141114

11151115
def _check_ecn_marks(self, e) -> bool:
1116-
return (
1117-
e[ECN.NONE] == 0
1118-
and e[ECN.CE] == 0
1119-
and ((e[ECN.ECT0] == 0) != (e[ECN.ECT1] == 0))
1120-
)
1116+
return e[ECN.CE] == 0 and self._check_ecn_any(e)
11211117

11221118
def _check_ack_ecn(self, tr) -> bool:
11231119
# NOTE: We only check whether the trace contains any ACK-ECN information, not whether it is valid

0 commit comments

Comments
 (0)