aboutsummaryrefslogtreecommitdiff
path: root/src/encoding/json/v2_encode.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/encoding/json/v2_encode.go')
-rw-r--r--src/encoding/json/v2_encode.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/encoding/json/v2_encode.go b/src/encoding/json/v2_encode.go
index cbb167dbd0..c2d620bcbb 100644
--- a/src/encoding/json/v2_encode.go
+++ b/src/encoding/json/v2_encode.go
@@ -10,6 +10,14 @@
//
// See "JSON and Go" for an introduction to this package:
// https://golang.org/doc/articles/json_and_go.html
+//
+// # Security Considerations
+//
+// See the "Security Considerations" section in [encoding/json/v2].
+//
+// For historical reasons, the default behavior of v1 [encoding/json]
+// unfortunately operates with less secure defaults.
+// New usages of JSON in Go are encouraged to use [encoding/json/v2] instead.
package json
import (