updated vendor

This commit is contained in:
2026-06-16 08:02:19 +02:00
parent 2f7f99d3f0
commit 77299d0c64
1283 changed files with 67302 additions and 208958 deletions
@@ -58,12 +58,18 @@ var decode cbor.DecMode = func() cbor.DecMode {
// with or without tagging. If a tag number is present, it must be valid.
TimeTag: cbor.DecTagOptional,
// Observed depth up to 16 in fuzzed batch/v1 CronJobList. JSON implementation limit
// is 10000.
MaxNestedLevels: 64,
// MaxNestedLevels is set to the same value used in the JSON implementation.
MaxNestedLevels: 10000,
MaxArrayElements: 1024,
MaxMapPairs: 1024,
// MaxArrayElements is set to the maximum allowed by the cbor library. We rely on
// the library initial wellformedness scan and on the api max request limit to
// prevent preallocating very large slices during decoding.
MaxArrayElements: 2147483647,
// MaxMapPairs specifies the maximum number of key-value pairs allowed in a map.
// We selected this value as it is large enough so that in practice the API server
// decoder will always hit the request body limit before the limit here is reached.
MaxMapPairs: 2097152,
// Indefinite-length sequences aren't produced by this serializer, but other
// implementations can.
+2 -2
View File
@@ -50,7 +50,7 @@ var rawTypeTranscodeFuncs = map[reflect.Type]func(reflect.Value) error{
return nil
}
fields := rv.Addr().Interface().(*metav1.FieldsV1)
if fields.Raw == nil {
if fields.GetRawReader().Size() == 0 {
// When Raw is nil it encodes to null. Don't change nil Raw values during
// transcoding, they would have unmarshalled from JSON as nil too.
return nil
@@ -59,7 +59,7 @@ var rawTypeTranscodeFuncs = map[reflect.Type]func(reflect.Value) error{
if err != nil {
return fmt.Errorf("failed to transcode FieldsV1 to JSON: %w", err)
}
fields.Raw = j
fields.SetRawBytes(j)
return nil
},
}