diff options
author | Zeling Feng <zeling@google.com> | 2021-08-19 13:12:50 -0700 |
---|---|---|
committer | gVisor bot <gvisor-bot@google.com> | 2021-08-19 13:15:40 -0700 |
commit | 50ed6b2e0994225b9bffa63b57a42da2d05e02b9 (patch) | |
tree | b023743da3d581c22e62bb3b224aab249a451e6b /pkg/tcpip/checker | |
parent | a4ae5fed32c09d5c09b4d540b9d5faa8fcd5dda1 (diff) |
Use a hash function to generate tcp timestamp offset
Also fix an option parsing error in checker.TCPTimestampChecker while I am here.
PiperOrigin-RevId: 391828329
Diffstat (limited to 'pkg/tcpip/checker')
-rw-r--r-- | pkg/tcpip/checker/checker.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pkg/tcpip/checker/checker.go b/pkg/tcpip/checker/checker.go index e0dfe5813..2f34bf8dd 100644 --- a/pkg/tcpip/checker/checker.go +++ b/pkg/tcpip/checker/checker.go @@ -729,7 +729,7 @@ func TCPTimestampChecker(wantTS bool, wantTSVal uint32, wantTSEcr uint32) Transp return } l := int(opts[i+1]) - if i < 2 || i+l > limit { + if l < 2 || i+l > limit { return } i += l |