Add skeleton CBOR package and introduce library dependency.

This commit is contained in:
Ben Luddy 2023-10-17 16:50:15 -04:00
parent 7944ebe481
commit ef27338bef
No known key found for this signature in database
GPG Key ID: A6551E73A5974C30
2 changed files with 45 additions and 0 deletions

View File

@ -0,0 +1,21 @@
/*
Copyright 2024 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package cbor
import (
_ "github.com/fxamacker/cbor/v2"
)

24
test/fuzz/cbor/cbor.go Normal file
View File

@ -0,0 +1,24 @@
/*
Copyright 2024 The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package cbor
import (
// Adds this package and its dependencies to the dependency chain of k8s.io/kubernetes
// without affecting the size of kube binaries. Once fuzz targets are added here, this will
// become a real import.
_ "k8s.io/apimachinery/pkg/runtime/serializer/cbor"
)