Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
281 changes: 281 additions & 0 deletions SPECS/influxdb/CVE-2025-11065.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,281 @@
From 742921c9ba2854d27baa64272487fc5075d2c39c Mon Sep 17 00:00:00 2001
From: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
Date: Sat, 12 Jul 2025 07:25:50 +0200
Subject: [PATCH] fix: error message leaks

Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>

Upstream Patch reference: https://github.com/go-viper/mapstructure/commit/742921c9ba2854d27baa64272487fc5075d2c39c.patch
---
.../mitchellh/mapstructure/decode_hooks.go | 12 +-
.../mitchellh/mapstructure/error.go | 156 ++++++++++++++++++
.../mitchellh/mapstructure/mapstructure.go | 10 +-
3 files changed, 169 insertions(+), 9 deletions(-)

diff --git a/vendor/github.com/mitchellh/mapstructure/decode_hooks.go b/vendor/github.com/mitchellh/mapstructure/decode_hooks.go
index 1f0abc6..4f70b03 100644
--- a/vendor/github.com/mitchellh/mapstructure/decode_hooks.go
+++ b/vendor/github.com/mitchellh/mapstructure/decode_hooks.go
@@ -113,7 +113,9 @@ func StringToTimeDurationHookFunc() DecodeHookFunc {
}

// Convert it by parsing
- return time.ParseDuration(data.(string))
+ d, err := time.ParseDuration(data.(string))
+
+ return d, wrapTimeParseDurationError(err)
}
}

@@ -134,7 +136,7 @@ func StringToIPHookFunc() DecodeHookFunc {
// Convert it by parsing
ip := net.ParseIP(data.(string))
if ip == nil {
- return net.IP{}, fmt.Errorf("failed parsing ip %v", data)
+ return net.IP{}, fmt.Errorf("failed parsing ip")
}

return ip, nil
@@ -157,7 +159,7 @@ func StringToIPNetHookFunc() DecodeHookFunc {

// Convert it by parsing
_, net, err := net.ParseCIDR(data.(string))
- return net, err
+ return net, wrapNetParseError(err)
}
}

@@ -176,7 +178,9 @@ func StringToTimeHookFunc(layout string) DecodeHookFunc {
}

// Convert it by parsing
- return time.Parse(layout, data.(string))
+ ti, err := time.Parse(layout, data.(string))
+
+ return ti, wrapTimeParseError(err)
}
}

diff --git a/vendor/github.com/mitchellh/mapstructure/error.go b/vendor/github.com/mitchellh/mapstructure/error.go
index 47a99e5..8c3b078 100644
--- a/vendor/github.com/mitchellh/mapstructure/error.go
+++ b/vendor/github.com/mitchellh/mapstructure/error.go
@@ -3,8 +3,12 @@ package mapstructure
import (
"errors"
"fmt"
+ "net"
+ "net/url"
"sort"
+ "strconv"
"strings"
+ "time"
)

// Error implements the error interface and can represents multiple
@@ -48,3 +52,155 @@ func appendErrors(errors []string, err error) []string {
return append(errors, e.Error())
}
}
+
+func wrapStrconvNumError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if err, ok := err.(*strconv.NumError); ok {
+ return &strconvNumError{Err: err}
+ }
+
+ return err
+}
+
+type strconvNumError struct {
+ Err *strconv.NumError
+}
+
+func (e *strconvNumError) Error() string {
+ return "strconv." + e.Err.Func + ": " + e.Err.Err.Error()
+}
+
+func (e *strconvNumError) Unwrap() error { return e.Err }
+
+func wrapUrlError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if err, ok := err.(*url.Error); ok {
+ return &urlError{Err: err}
+ }
+
+ return err
+}
+
+type urlError struct {
+ Err *url.Error
+}
+
+func (e *urlError) Error() string {
+ return fmt.Sprintf("%s", e.Err.Err)
+}
+
+func (e *urlError) Unwrap() error { return e.Err }
+
+func wrapNetParseError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if err, ok := err.(*net.ParseError); ok {
+ return &netParseError{Err: err}
+ }
+
+ return err
+}
+
+type netParseError struct {
+ Err *net.ParseError
+}
+
+func (e *netParseError) Error() string {
+ return "invalid " + e.Err.Type
+}
+
+func (e *netParseError) Unwrap() error { return e.Err }
+
+func wrapTimeParseError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if err, ok := err.(*time.ParseError); ok {
+ return &timeParseError{Err: err}
+ }
+
+ return err
+}
+
+type timeParseError struct {
+ Err *time.ParseError
+}
+
+func (e *timeParseError) Error() string {
+ if e.Err.Message == "" {
+ return fmt.Sprintf("parsing time as %q: cannot parse as %q", e.Err.Layout, e.Err.LayoutElem)
+ }
+
+ return "parsing time " + e.Err.Message
+}
+
+func (e *timeParseError) Unwrap() error { return e.Err }
+
+func wrapNetIPParseAddrError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if errMsg := err.Error(); strings.HasPrefix(errMsg, "ParseAddr") {
+ errPieces := strings.Split(errMsg, ": ")
+
+ return fmt.Errorf("ParseAddr: %s", errPieces[len(errPieces)-1])
+ }
+
+ return err
+}
+
+func wrapNetIPParseAddrPortError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ errMsg := err.Error()
+ if strings.HasPrefix(errMsg, "invalid port ") {
+ return errors.New("invalid port")
+ } else if strings.HasPrefix(errMsg, "invalid ip:port ") {
+ return errors.New("invalid ip:port")
+ }
+
+ return err
+}
+
+func wrapNetIPParsePrefixError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ if errMsg := err.Error(); strings.HasPrefix(errMsg, "netip.ParsePrefix") {
+ errPieces := strings.Split(errMsg, ": ")
+
+ return fmt.Errorf("netip.ParsePrefix: %s", errPieces[len(errPieces)-1])
+ }
+
+ return err
+}
+
+func wrapTimeParseDurationError(err error) error {
+ if err == nil {
+ return nil
+ }
+
+ errMsg := err.Error()
+ if strings.HasPrefix(errMsg, "time: unknown unit ") {
+ return errors.New("time: unknown unit")
+ } else if strings.HasPrefix(errMsg, "time: ") {
+ idx := strings.LastIndex(errMsg, " ")
+
+ return errors.New(errMsg[:idx])
+ }
+
+ return err
+}
diff --git a/vendor/github.com/mitchellh/mapstructure/mapstructure.go b/vendor/github.com/mitchellh/mapstructure/mapstructure.go
index b384d9d..21c2264 100644
--- a/vendor/github.com/mitchellh/mapstructure/mapstructure.go
+++ b/vendor/github.com/mitchellh/mapstructure/mapstructure.go
@@ -592,7 +592,7 @@ func (d *Decoder) decodeInt(name string, data interface{}, val reflect.Value) er
if err == nil {
val.SetInt(i)
} else {
- return fmt.Errorf("cannot parse '%s' as int: %s", name, err)
+ return fmt.Errorf("cannot parse '%s' as int: %s", name, wrapStrconvNumError(err))
}
case dataType.PkgPath() == "encoding/json" && dataType.Name() == "Number":
jn := data.(json.Number)
@@ -644,14 +644,14 @@ func (d *Decoder) decodeUint(name string, data interface{}, val reflect.Value) e
if err == nil {
val.SetUint(i)
} else {
- return fmt.Errorf("cannot parse '%s' as uint: %s", name, err)
+ return fmt.Errorf("cannot parse '%s' as uint: %s", name, wrapStrconvNumError(err))
}
case dataType.PkgPath() == "encoding/json" && dataType.Name() == "Number":
jn := data.(json.Number)
i, err := jn.Int64()
if err != nil {
return fmt.Errorf(
- "error decoding json.Number into %s: %s", name, err)
+ "error decoding json.Number into %s: %s", name, wrapStrconvNumError(err))
}
if i < 0 && !d.config.WeaklyTypedInput {
return fmt.Errorf("cannot parse '%s', %d overflows uint",
@@ -687,7 +687,7 @@ func (d *Decoder) decodeBool(name string, data interface{}, val reflect.Value) e
} else if dataVal.String() == "" {
val.SetBool(false)
} else {
- return fmt.Errorf("cannot parse '%s' as bool: %s", name, err)
+ return fmt.Errorf("cannot parse '%s' as bool: %s", name, wrapStrconvNumError(err))
}
default:
return fmt.Errorf(
@@ -721,7 +721,7 @@ func (d *Decoder) decodeFloat(name string, data interface{}, val reflect.Value)
if err == nil {
val.SetFloat(f)
} else {
- return fmt.Errorf("cannot parse '%s' as float: %s", name, err)
+ return fmt.Errorf("cannot parse '%s' as float: %s", name, wrapStrconvNumError(err))
}
case dataType.PkgPath() == "encoding/json" && dataType.Name() == "Number":
jn := data.(json.Number)
--
2.43.0
6 changes: 5 additions & 1 deletion SPECS/influxdb/influxdb.spec
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Summary: Scalable datastore for metrics, events, and real-time analytics
Name: influxdb
Version: 2.7.5
Release: 10%{?dist}
Release: 11%{?dist}
License: MIT
Vendor: Microsoft Corporation
Distribution: Azure Linux
Expand Down Expand Up @@ -69,6 +69,7 @@ Patch10: CVE-2024-51744.patch
Patch11: CVE-2025-22872.patch
Patch12: CVE-2025-65637.patch
Patch13: CVE-2025-10543.patch
Patch14: CVE-2025-11065.patch
BuildRequires: clang
BuildRequires: golang
BuildRequires: kernel-headers
Expand Down Expand Up @@ -158,6 +159,9 @@ go test ./...
%{_tmpfilesdir}/influxdb.conf

%changelog
* Wed Feb 04 2026 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 2.7.5-11
- Patch for CVE-2025-11065

* Wed Dec 17 2025 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 2.7.5-10
- Patch for CVE-2025-10543

Expand Down
Loading