Skip to content

Commit 70a3d3a

Browse files
authored
Merge pull request #11 from retailnext/dependabot/go_modules/golang.org/x/crypto-0.49.0
Bump golang.org/x/crypto from 0.48.0 to 0.49.0
2 parents 0818352 + 79646e2 commit 70a3d3a

File tree

7 files changed

+21
-10
lines changed

7 files changed

+21
-10
lines changed

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ jobs:
1717
- name: golangci-lint
1818
uses: golangci/golangci-lint-action@v7
1919
with:
20-
version: v2.0
20+
version: v2.11

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
strategy:
1212
matrix:
13-
go: [ '1.22.x', '1.23.x', '1.24.x']
13+
go: [ '1.22.x', '1.23.x', '1.24.x', '1.25.x']
1414
steps:
1515
- uses: actions/checkout@v4
1616
- uses: actions/setup-go@v4

.golangci.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,17 @@ linters:
5151
generated: lax
5252
rules:
5353
- path: (.+)\.go$
54-
text: G104 # 'Errors unhandled. (gosec)
54+
text: G104 # Errors unhandled (gosec)
55+
- path: (.+)\.go$
56+
text: G115 # integer overflow conversion int -> byte (gosec)
57+
- path: (.+)\.go$
58+
text: G117 # Marshaled struct field matches secret pattern (gosec)
59+
- path: (.+)\.go$
60+
text: G120 # Parsing form data without limiting request body size (gosec)
61+
- path: (.+)\.go$
62+
text: G705 # XSS via taint analysis (gosec)
63+
- path: (.+)\.go$
64+
text: G706 # Log injection via taint analysis (gosec)
5565
paths:
5666
- example/.*\.go$
5767
formatters:

go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
module github.com/crewjam/saml
22

3-
go 1.24.0
3+
go 1.25.0
44

55
require (
66
github.com/beevik/etree v1.6.0
77
github.com/golang-jwt/jwt/v5 v5.3.1
88
github.com/google/go-cmp v0.7.0
99
github.com/mattermost/xml-roundtrip-validator v0.1.0
1010
github.com/russellhaering/goxmldsig v1.6.0
11-
golang.org/x/crypto v0.48.0
11+
golang.org/x/crypto v0.49.0
1212
gotest.tools v2.2.0+incompatible
1313
)
1414

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+
2121
github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
2222
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
2323
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
24-
golang.org/x/crypto v0.48.0 h1:/VRzVqiRSggnhY7gNRxPauEQ5Drw9haKdM0jqfcCFts=
25-
golang.org/x/crypto v0.48.0/go.mod h1:r0kV5h3qnFPlQnBSrULhlsRfryS2pmewsg+XfMgkVos=
24+
golang.org/x/crypto v0.49.0 h1:+Ng2ULVvLHnJ/ZFEq4KdcDd/cfjrrjjNSXNzxg0Y4U4=
25+
golang.org/x/crypto v0.49.0/go.mod h1:ErX4dUh2UM+CFYiXZRTcMpEcN8b/1gxEuv3nODoYtCA=
2626
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
2727
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
2828
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=

identity_provider.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -745,7 +745,7 @@ func (DefaultAssertionMaker) MakeAssertion(req *IdpAuthnRequest, session *Sessio
745745
attributes = append(attributes, session.CustomAttributes...)
746746

747747
if len(session.Groups) != 0 {
748-
groupMemberAttributeValues := []AttributeValue{}
748+
groupMemberAttributeValues := make([]AttributeValue, 0, len(session.Groups))
749749
for _, group := range session.Groups {
750750
groupMemberAttributeValues = append(groupMemberAttributeValues, AttributeValue{
751751
Type: "xs:string",
@@ -1084,7 +1084,8 @@ func (req *IdpAuthnRequest) MakeResponse() error {
10841084
// signingContext will create a signing context for the request.
10851085
func (req *IdpAuthnRequest) signingContext() (*dsig.SigningContext, error) {
10861086
// Create a cert chain based off of the IDP cert and its intermediates.
1087-
certificates := [][]byte{req.IDP.Certificate.Raw}
1087+
certificates := make([][]byte, 0, 1+len(req.IDP.Intermediates))
1088+
certificates = append(certificates, req.IDP.Certificate.Raw)
10881089
for _, cert := range req.IDP.Intermediates {
10891090
certificates = append(certificates, cert.Raw)
10901091
}

xmlenc/cbc.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ func (e CBC) Encrypt(key interface{}, plaintext []byte, _ []byte) (*etree.Elemen
6161

6262
plaintext = appendPadding(plaintext, block.BlockSize())
6363

64-
iv := make([]byte, block.BlockSize())
64+
iv := make([]byte, block.BlockSize(), block.BlockSize()+len(plaintext))
6565
if _, err := RandReader.Read(iv); err != nil {
6666
return nil, err
6767
}

0 commit comments

Comments
 (0)