Skip to content
Merged
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
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
build:
parallelism: 8
docker:
- image: cimg/go:1.25
- image: cimg/go:1.26.1
steps:
- checkout

Expand All @@ -37,7 +37,7 @@ jobs:

report:
docker:
- image: cimg/go:1.25
- image: cimg/go:1.26.1
steps:
- checkout
- attach_workspace:
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# golang alpine
FROM golang:1.25.7-alpine AS builder
FROM golang:1.26.1-alpine AS builder

ARG TARGETARCH
ARG TARGETOS
Expand Down
8 changes: 8 additions & 0 deletions docs/pages/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
Release notes
#############

*************************
Hazelnut update (v5.4.25)
*************************

Release date: 2026-03-15

- Upgrade to Go 1.26.1 to fix GO-2026-4601, GO-2026-4602 and GO-2026-4603

*************************
Hazelnut update (v5.4.24)
*************************
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ module github.com/nuts-foundation/nuts-node

// This is the minimal version, the actual go version is determined by the images in the Dockerfile
// This version is used in automated tests such as the 'Scheduled govulncheck' action
go 1.25.7
go 1.26.1

require (
github.com/alicebob/miniredis/v2 v2.33.0
Expand Down
15 changes: 8 additions & 7 deletions http/requestlogger_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,17 @@ package http
import (
"bytes"
"errors"
"net/http"
"net/http/httptest"
"testing"

"github.com/labstack/echo/v4"
"github.com/nuts-foundation/nuts-node/core"
"github.com/nuts-foundation/nuts-node/mock"
"github.com/sirupsen/logrus"
"github.com/sirupsen/logrus/hooks/test"
"github.com/stretchr/testify/assert"
"go.uber.org/mock/gomock"
"net/http"
"net/http/httptest"
"testing"
)

func Test_requestLoggerMiddleware(t *testing.T) {
Expand Down Expand Up @@ -128,9 +129,9 @@ func Test_bodyLoggerMiddleware(t *testing.T) {
response := echo.NewResponse(responseRecorder, e)
response.Header().Set("Content-Type", "application/json")
echoMock := mock.NewMockContext(ctrl)
echoMock.EXPECT().NoContent(http.StatusNoContent).Do(func(status int) {
echoMock.EXPECT().String(gomock.Any(), gomock.Any()).Do(func(status int, data string) {
response.Status = status
response.Write([]byte(`"response"`))
response.Write([]byte(data))
})
echoMock.EXPECT().Request().MinTimes(1).Return(request)
echoMock.EXPECT().Response().MinTimes(1).Return(response)
Expand All @@ -140,13 +141,13 @@ func Test_bodyLoggerMiddleware(t *testing.T) {
return false
}, logger.WithFields(logrus.Fields{}))
err := logFunc(func(context echo.Context) error {
return context.NoContent(http.StatusNoContent)
return context.String(http.StatusOK, "response")
})(echoMock)

assert.NoError(t, err)
assert.Len(t, hook.Entries, 2)
assert.Equal(t, `HTTP request body: "request"`, hook.AllEntries()[0].Message)
assert.Equal(t, `HTTP response body: "response"`, hook.AllEntries()[1].Message)
assert.Equal(t, `HTTP response body: response`, hook.AllEntries()[1].Message)
})
t.Run("request and response not loggable", func(t *testing.T) {
ctrl := gomock.NewController(t)
Expand Down
Loading