Skip to content

Commit 91f7919

Browse files
committed
fix(serializer): disable MsgpackSerializer and remove shamaton/msgpack dependency
Disable Marshal and Unmarshal in MsgpackSerializer by converting them into stubs that return errors. This addresses a security concern in the upstream shamaton/msgpack library (ref: shamaton/msgpack#60). The type is marked deprecated and will be removed in a future release. - Remove github.com/shamaton/msgpack/v3 from go.mod - Bump github.com/hyp3rd/ewrap from v1.3.8 to v1.3.9
1 parent 3ed0054 commit 91f7919

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

internal/libs/serializer/msgpack.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ func (*MsgpackSerializer) Marshal(_ any) ([]byte, error) { // receiver omitted (
3333
//
3434
// Deprecated: This method is now a shim and will be removed in a future release for security reasons.
3535
// REF: https://github.com/shamaton/msgpack/pull/60
36-
// Please use the `Marshal` method of the `Serializer` interface instead.
36+
// Please use the `Unmarshal` method of the `Serializer` interface instead.
3737
func (*MsgpackSerializer) Unmarshal(_ []byte, _ any) error { // receiver omitted (unused)
3838
// err := msgpack.Unmarshal(data, v)
3939
// if err != nil {

0 commit comments

Comments
 (0)