You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Brad Fitzpatrick
86f42ea87b
cmd/cloner, cmd/viewer: handle named map/slice types with Clone/View methods
...
The cloner and viewer code generators didn't handle named types
with basic underlying types (map/slice) that have their own Clone
or View methods. For example, a type like:
type Map map[string]any
func (m Map) Clone() Map { ... }
func (m Map) View() MapView { ... }
When used as a struct field, the cloner would descend into the
underlying map[string]any and fail because it can't clone the any
(interface{}) value type. Similarly, the viewer would try to create
a MapFnOf view and fail.
Fix the cloner to check for a Clone method on the named type
before falling through to the underlying type handling.
Fix the viewer to check for a View method on named map/slice types,
so the type author can provide a purpose-built safe view that
doesn't leak raw any values. Named map/slice types without a View
method fall through to normal handling, which correctly rejects
types like map[string]any as unsupported.
Updates tailscale/corp#39502 (needed by tailscale/corp#39594 )
Change-Id: Iaef0192a221e02b4b8e409c99ef8398090327744
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2 weeks ago
..
publicdns
net/dns: add test for DoH upgrade of system DNS
3 months ago
resolvconffile
all: remove AUTHORS file and references to it
3 months ago
resolver
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
config.go
net/dns: make MagicDNS IPv6 registration opt-out now, not opt-in
2 months ago
dbus.go
all: remove AUTHORS file and references to it
3 months ago
debian_resolvconf.go
all: remove AUTHORS file and references to it
3 months ago
direct.go
all: remove AUTHORS file and references to it
3 months ago
direct_linux_test.go
all: remove AUTHORS file and references to it
3 months ago
direct_test.go
all: remove AUTHORS file and references to it
3 months ago
direct_unix_test.go
all: remove AUTHORS file and references to it
3 months ago
dns_clone.go
cmd/cloner, cmd/viewer: handle named map/slice types with Clone/View methods
2 weeks ago
dns_view.go
net/dns, ipn/local: skip health warnings in dns forwarder when accept-dns is false ( #18572 )
2 months ago
flush_default.go
all: remove AUTHORS file and references to it
3 months ago
flush_windows.go
all: remove AUTHORS file and references to it
3 months ago
ini.go
all: remove AUTHORS file and references to it
3 months ago
ini_test.go
all: remove AUTHORS file and references to it
3 months ago
manager.go
net/dns: fix duplicate search line entries (OpenBSD, primarily)
3 weeks ago
manager_darwin.go
all: remove AUTHORS file and references to it
3 months ago
manager_default.go
all: remove AUTHORS file and references to it
3 months ago
manager_freebsd.go
all: remove AUTHORS file and references to it
3 months ago
manager_linux.go
all: use Go 1.26 things, run most gofix modernizers
1 month ago
manager_linux_test.go
cmd/vet: add subtestnames analyzer; fix all existing violations
2 weeks ago
manager_openbsd.go
all: remove AUTHORS file and references to it
3 months ago
manager_plan9.go
all: remove AUTHORS file and references to it
3 months ago
manager_plan9_test.go
all: remove AUTHORS file and references to it
3 months ago
manager_solaris.go
all: remove AUTHORS file and references to it
3 months ago
manager_tcp_test.go
net/dns: make MagicDNS IPv6 registration opt-out now, not opt-in
2 months ago
manager_test.go
net/dns: make MagicDNS IPv6 registration opt-out now, not opt-in
2 months ago
manager_windows.go
control/controlknobs,net/dns,tailcfg: add a control knob that disables hosts file updates on Windows
2 months ago
manager_windows_test.go
all: remove AUTHORS file and references to it
3 months ago
nm.go
all: remove AUTHORS file and references to it
3 months ago
noop.go
net/dns: skip DNS base config when using userspace networking ( #18355 )
3 months ago
nrpt_windows.go
net/dns: use the correct separator for multiple servers in the same NRPT rule on Windows
4 weeks ago
openresolv.go
all: use Go 1.26 things, run most gofix modernizers
1 month ago
osconfig.go
all: remove AUTHORS file and references to it
3 months ago
osconfig_test.go
all: remove AUTHORS file and references to it
3 months ago
resolvconf-workaround.sh
all: remove AUTHORS file and references to it
3 months ago
resolvconf.go
all: remove AUTHORS file and references to it
3 months ago
resolvconfpath_default.go
all: remove AUTHORS file and references to it
3 months ago
resolvconfpath_gokrazy.go
all: remove AUTHORS file and references to it
3 months ago
resolvd.go
all: remove AUTHORS file and references to it
3 months ago
resolved.go
all: remove AUTHORS file and references to it
3 months ago
utf.go
all: remove AUTHORS file and references to it
3 months ago
utf_test.go
all: remove AUTHORS file and references to it
3 months ago
wsl_windows.go
all: use Go 1.26 things, run most gofix modernizers
1 month ago