mirror of
https://github.com/hanzoai/visor.git
synced 2026-09-24 17:04:14 +00:00
Drop PickEphemeralPortStable which uses a hash-based algorithm from RFC 6056, instead just use PickEphemeralPort that uses a randomized algorithm from RFC 6056 to avoid potential security concerns. Discovered by Inon Kaplan (PhD candidate in the Hebrew University School of Computer Science and Engineering), Ron Even (BSc graduate of Bar Ilan University) and Amit Klein (faculty member in the Hebrew University School of Computer Science and Engineering). Details will be provided in their paper, to be presented in a forthcoming academic conference. PiperOrigin-RevId: 581334218
34 lines
642 B
Python
34 lines
642 B
Python
load("//tools:defs.bzl", "go_library", "go_test")
|
|
|
|
package(
|
|
default_applicable_licenses = ["//:license"],
|
|
licenses = ["notice"],
|
|
)
|
|
|
|
go_library(
|
|
name = "ports",
|
|
srcs = [
|
|
"flags.go",
|
|
"ports.go",
|
|
],
|
|
visibility = ["//visibility:public"],
|
|
deps = [
|
|
"//pkg/rand",
|
|
"//pkg/sync",
|
|
"//pkg/tcpip",
|
|
"//pkg/tcpip/header",
|
|
],
|
|
)
|
|
|
|
go_test(
|
|
name = "ports_test",
|
|
srcs = ["ports_test.go"],
|
|
library = ":ports",
|
|
deps = [
|
|
"//pkg/rand",
|
|
"//pkg/tcpip",
|
|
"//pkg/tcpip/testutil",
|
|
"@com_github_google_go_cmp//cmp:go_default_library",
|
|
],
|
|
)
|