Skip to content

Commit

Permalink
fix conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
qmuntal committed Mar 3, 2023
1 parent 85ac595 commit f13c034
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 22 deletions.
18 changes: 16 additions & 2 deletions patches/0003-Add-crypto-backend-foundation.patch
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ Subject: [PATCH] Add crypto backend foundation
src/crypto/rsa/pkcs1v15.go | 2 +-
src/crypto/rsa/pss.go | 2 +-
src/crypto/rsa/rsa.go | 4 +-
src/crypto/rsa/rsa_test.go | 2 +-
src/crypto/sha1/boring.go | 2 +-
src/crypto/sha1/sha1_test.go | 2 +-
src/crypto/sha256/sha256.go | 2 +-
Expand All @@ -37,7 +38,7 @@ Subject: [PATCH] Add crypto backend foundation
src/crypto/tls/cipher_suites.go | 2 +-
src/go/build/deps_test.go | 2 +
src/runtime/runtime_boring.go | 5 +
33 files changed, 291 insertions(+), 28 deletions(-)
34 files changed, 292 insertions(+), 29 deletions(-)
create mode 100644 src/crypto/internal/backend/backend_test.go
create mode 100644 src/crypto/internal/backend/bbig/big.go
create mode 100644 src/crypto/internal/backend/common.go
Expand Down Expand Up @@ -575,6 +576,19 @@ index 11f87e8e4973e3..512e4a4d6616e5 100644
"crypto/internal/randutil"
"crypto/rand"
"crypto/subtle"
diff --git a/src/crypto/rsa/rsa_test.go b/src/crypto/rsa/rsa_test.go
index 3278a7ff305766..95f4b8e98d2fb0 100644
--- a/src/crypto/rsa/rsa_test.go
+++ b/src/crypto/rsa/rsa_test.go
@@ -8,7 +8,7 @@ import (
"bufio"
"bytes"
"crypto"
- "crypto/internal/boring"
+ boring "crypto/internal/backend"
"crypto/rand"
. "crypto/rsa"
"crypto/sha1"
diff --git a/src/crypto/sha1/boring.go b/src/crypto/sha1/boring.go
index b5786d1bf4ea92..e82a21c44a57c8 100644
--- a/src/crypto/sha1/boring.go
Expand Down Expand Up @@ -667,7 +681,7 @@ index 04e6dfe0189b47..68598961fda6e4 100644
"crypto/sha1"
"crypto/sha256"
diff --git a/src/go/build/deps_test.go b/src/go/build/deps_test.go
index ff9877b6793e6e..a6bd4eeba92c05 100644
index 36091d5a94c8bf..efa94c83eb2642 100644
--- a/src/go/build/deps_test.go
+++ b/src/go/build/deps_test.go
@@ -399,6 +399,7 @@ var depsRules = `
Expand Down
10 changes: 5 additions & 5 deletions patches/0005-Add-OpenSSL-crypto-backend.patch
Original file line number Diff line number Diff line change
Expand Up @@ -635,8 +635,8 @@ index 19dd06fee37ae8..eccb90ae2d36ac 100644

require (
+ github.com/microsoft/go-crypto-openssl v0.2.3
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4
golang.org/x/net v0.7.0
)
diff --git a/src/go.sum b/src/go.sum
index ef6748d5968c24..799a91a2af7f4d 100644
Expand All @@ -645,9 +645,9 @@ index ef6748d5968c24..799a91a2af7f4d 100644
@@ -1,3 +1,5 @@
+github.com/microsoft/go-crypto-openssl v0.2.3 h1:bbY1FjnyjNcxZydzBcWp3FDruolP66P1gUGDlN5WGug=
+github.com/microsoft/go-crypto-openssl v0.2.3/go.mod h1:rC+rtBU3m60UCQifBmpWII0VETfu78w6YGZQvVc0rd4=
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a h1:diz9pEYuTIuLMJLs3rGDkeaTsNyRs6duYdFyPAxzE/U=
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4=
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10 h1:Frnccbp+ok2GkUS2tC84yAq/U9Vg+0sIO7aRL3T4Xnc=
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4 h1:8CmdfDrqo5/AGztF4Zk/aBNGTgL5dgcfPMmmvH1z8Lo=
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU=
golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=
diff --git a/src/go/build/deps_test.go b/src/go/build/deps_test.go
index a7041966cc851a..7b6ccd1f189f7f 100644
--- a/src/go/build/deps_test.go
Expand Down
20 changes: 6 additions & 14 deletions patches/0006-Add-CNG-crypto-backend.patch
Original file line number Diff line number Diff line change
Expand Up @@ -695,22 +695,14 @@ diff --git a/src/crypto/rsa/rsa_test.go b/src/crypto/rsa/rsa_test.go
index 379fb06526ccc7..d844cc4b8d749e 100644
--- a/src/crypto/rsa/rsa_test.go
+++ b/src/crypto/rsa/rsa_test.go
@@ -8,6 +8,7 @@ import (
"bufio"
"bytes"
"crypto"
+ boring "crypto/internal/backend"
"crypto/rand"
. "crypto/rsa"
"crypto/sha1"
@@ -16,6 +17,7 @@ import (
"encoding/pem"
"flag"
"fmt"
+ "internal/goexperiment"
"internal/testenv"
"math/big"
"strings"
"testing"
@@ -111,6 +113,9 @@ func testKeyBasics(t *testing.T, priv *PrivateKey) {
if priv.D.Cmp(priv.N) > 0 {
t.Errorf("private exponent too large")
Expand Down Expand Up @@ -1064,8 +1056,8 @@ index eccb90ae2d36ac..7fd7320e0a0e91 100644
require (
github.com/microsoft/go-crypto-openssl v0.2.3
+ github.com/microsoft/go-crypto-winnative v0.0.0-20230125071228-ef6c7cb780c6
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4
golang.org/x/net v0.7.0
)
diff --git a/src/go.sum b/src/go.sum
index 799a91a2af7f4d..ce5ddcdf80951f 100644
Expand All @@ -1076,9 +1068,9 @@ index 799a91a2af7f4d..ce5ddcdf80951f 100644
github.com/microsoft/go-crypto-openssl v0.2.3/go.mod h1:rC+rtBU3m60UCQifBmpWII0VETfu78w6YGZQvVc0rd4=
+github.com/microsoft/go-crypto-winnative v0.0.0-20230125071228-ef6c7cb780c6 h1:6DT0+Xkuu2MOaGrK41ATNUB4AhqUVq1/wWcOsCTAkck=
+github.com/microsoft/go-crypto-winnative v0.0.0-20230125071228-ef6c7cb780c6/go.mod h1:fveERXKbeK+XLmOyU24caKnIT/S5nniAX9XCRHfnrM4=
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a h1:diz9pEYuTIuLMJLs3rGDkeaTsNyRs6duYdFyPAxzE/U=
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4=
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10 h1:Frnccbp+ok2GkUS2tC84yAq/U9Vg+0sIO7aRL3T4Xnc=
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4 h1:8CmdfDrqo5/AGztF4Zk/aBNGTgL5dgcfPMmmvH1z8Lo=
golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU=
golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=
diff --git a/src/go/build/deps_test.go b/src/go/build/deps_test.go
index 7b6ccd1f189f7f..f6796dbc1ff029 100644
--- a/src/go/build/deps_test.go
Expand Down
2 changes: 1 addition & 1 deletion patches/0007-Vendor-crypto-backends.patch
Original file line number Diff line number Diff line change
Expand Up @@ -6213,6 +6213,6 @@ index 3e4bb5b90bc672..e9962f98172436 100644
+github.com/microsoft/go-crypto-winnative/internal/bcrypt
+github.com/microsoft/go-crypto-winnative/internal/subtle
+github.com/microsoft/go-crypto-winnative/internal/sysdll
# golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a
# golang.org/x/crypto v0.5.1-0.20230203195927-310bfa40f1e4
## explicit; go 1.17
golang.org/x/crypto/chacha20

0 comments on commit f13c034

Please sign in to comment.