Skip to content

Commit 9dcd86c

Browse files
authored
CVEs Fix (#1526)
* CVE-2025-22868 * Upgrade go module to 1.24.6 * Telegraf dalec upgrade test * Telegraf upgrade 1.36.1 local * rexml vul fix * uninstaall rexml * telegraf official image changes * go build fix
1 parent fb8011c commit 9dcd86c

File tree

5 files changed

+12
-9
lines changed

5 files changed

+12
-9
lines changed

kubernetes/linux/setup.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ rm -rf /usr/lib/ruby/gems/3.3.0/gems/rdoc-6.6.3.1
3737
# remove net-imap gem as it has a known CVE (CVE-2025-43857) and is not used by the agent
3838
gem uninstall net-imap --force
3939

40+
# remove rexml gem as it has a known CVE (CVE-2025-58767) and is not used by the agent
41+
gem uninstall rexml --force
42+
4043
sudo tdnf install -y azure-mdsd-1.37.0
4144
cp -f $TMPDIR/mdsd.xml /etc/mdsd.d
4245
cp -f $TMPDIR/envmdsd /etc/mdsd.d
@@ -59,7 +62,7 @@ sudo tdnf install jq-1.7.1-1.azl3 -y
5962
#used to setcaps for ruby process to read /proc/env
6063
sudo tdnf install libcap -y
6164

62-
sudo tdnf install telegraf-agent-1.34.3 -y
65+
sudo tdnf install telegraf-agent-1.36.1 -y
6366
telegraf_version=$(sudo tdnf list installed | grep telegraf | awk '{print $2}')
6467
echo "telegraf $telegraf_version" >> packages_version.txt
6568
mv /usr/bin/telegraf-agent /opt/telegraf

source/plugins/go/input/go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module Docker-Provider/source/plugins/go/input
22

3-
go 1.23.8
3+
go 1.24.6
44

55
require github.com/calyptia/plugin v1.0.2
66

source/plugins/go/src/go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module Docker-Provider/source/plugins/go/src
22

3-
go 1.23.8
3+
go 1.24.6
44

55
require (
66
github.com/Microsoft/go-winio v0.6.1
@@ -38,7 +38,6 @@ require (
3838
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
3939
github.com/philhofer/fwd v1.1.2 // indirect
4040
golang.org/x/net v0.38.0 // indirect
41-
golang.org/x/oauth2 v0.19.0 // indirect
4241
golang.org/x/sys v0.31.0 // indirect
4342
golang.org/x/term v0.30.0 // indirect
4443
golang.org/x/text v0.23.0 // indirect
@@ -53,6 +52,7 @@ require (
5352
github.com/pmezard/go-difflib v1.0.0 // indirect
5453
github.com/rogpeppe/go-internal v1.12.0 // indirect
5554
golang.org/x/mod v0.17.0 // indirect
55+
golang.org/x/oauth2 v0.27.0 // indirect
5656
golang.org/x/sync v0.12.0 // indirect
5757
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect
5858
google.golang.org/protobuf v1.33.0 // indirect

source/plugins/go/src/go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,8 @@ golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwY
115115
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
116116
golang.org/x/net v0.38.0 h1:vRMAPTMaeGqVhG5QyLJHqNDwecKTomGeqbnfZyKlBI8=
117117
golang.org/x/net v0.38.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8=
118-
golang.org/x/oauth2 v0.19.0 h1:9+E/EZBCbTLNrbN35fHv/a/d/mOBatymz1zbtQrXpIg=
119-
golang.org/x/oauth2 v0.19.0/go.mod h1:vYi7skDa1x015PmRRYZ7+s1cWyPgrPiSYRe4rnsexc8=
118+
golang.org/x/oauth2 v0.27.0 h1:da9Vo7/tDv5RH/7nZDz1eMGS/q1Vv1N/7FCrBhI9I3M=
119+
golang.org/x/oauth2 v0.27.0/go.mod h1:onh5ek6nERTohokkhCD/y2cV4Do3fxFHFuAejCkRWT8=
120120
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
121121
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
122122
golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=

source/plugins/go/src/oms.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ func createLogger() *log.Logger {
421421
logfile, err = os.OpenFile(logPath, os.O_APPEND|os.O_WRONLY, 0600)
422422
if err != nil {
423423
SendException(err.Error())
424-
fmt.Printf(err.Error())
424+
fmt.Print(err.Error())
425425
}
426426
}
427427

@@ -430,7 +430,7 @@ func createLogger() *log.Logger {
430430
logfile, err = os.Create(logPath)
431431
if err != nil {
432432
SendException(err.Error())
433-
fmt.Printf(err.Error())
433+
fmt.Print(err.Error())
434434
}
435435
}
436436

@@ -2314,7 +2314,7 @@ func InitializePlugin(pluginConfPath string, agentVersion string) {
23142314
ret, err := InitializeTelemetryClient(agentVersion)
23152315
if ret != 0 || err != nil {
23162316
message := fmt.Sprintf("Error During Telemetry Initialization :%s", err.Error())
2317-
fmt.Printf(message)
2317+
fmt.Print(message)
23182318
Log(message)
23192319
}
23202320

0 commit comments

Comments
 (0)