Skip to content

Commit f93a56c

Browse files
authored
Merge pull request #368 from ConsenSys/develop
v0.10.0 placeholder
2 parents 8f7ca09 + a57dcc3 commit f93a56c

File tree

204 files changed

+124914
-1823
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

204 files changed

+124914
-1823
lines changed

.github/workflows/pr.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
on: pull_request
2-
env:
2+
env:
33
GOPROXY: "https://proxy.golang.org"
44

55
name: pull_request
@@ -10,7 +10,7 @@ jobs:
1010
- name: install Go
1111
uses: actions/setup-go@v2
1212
with:
13-
go-version: 1.19.x
13+
go-version: 1.20.x
1414
- name: checkout code
1515
uses: actions/checkout@v2
1616
with:
@@ -39,11 +39,11 @@ jobs:
3939
git update-index --assume-unchanged go.mod
4040
git update-index --assume-unchanged go.sum
4141
if [[ -n $(git status --porcelain) ]]; then echo "git repo is dirty after runing go generate -- please don't modify generated files"; echo $(git diff);echo $(git status --porcelain); exit 1; fi
42-
42+
4343
test:
4444
strategy:
4545
matrix:
46-
go-version: [1.18.x, 1.19.x]
46+
go-version: [1.19.x, 1.20.x]
4747
os: [ubuntu-latest]
4848
runs-on: ${{ matrix.os }}
4949
needs:
@@ -72,12 +72,12 @@ jobs:
7272
go test -p=1 -v -timeout=30m ./...
7373
go test -p=1 -tags=purego -v -timeout=30m ./...
7474
- name: Test (32 bits & race)
75-
if: (matrix.os == 'ubuntu-latest') && (matrix.go-version == '1.18.x')
75+
if: (matrix.os == 'ubuntu-latest') && (matrix.go-version == '1.19.x')
7676
run: |
7777
go test -p=1 -v -timeout=30m -short -race ./ecc/bn254/...
7878
go test -p=1 -v -timeout=30m -short -tags=noadx ./ecc/bn254/...
7979
GOARCH=386 go test -p=1 -timeout=30m -short -v ./ecc/bn254/...
80-
80+
8181
slack-workflow-status-failed:
8282
if: failure()
8383
name: post workflow status to slack

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838

3939
### Go version
4040

41-
`gnark-crypto` is tested with the last 2 major releases of Go (1.17 and 1.18).
41+
`gnark-crypto` is tested with the last 2 major releases of Go (currently 1.19 and 1.20).
4242

4343
### Install `gnark-crypto`
4444

ecc/bls12-377/bls12-377.go

+8-2
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ import (
4040
// ID bls377 ID
4141
const ID = ecc.BLS12_377
4242

43-
// bCurveCoeff b coeff of the curve Y²=X³+b
43+
// aCurveCoeff is the a coefficients of the curve Y²=X³+ax+b
44+
var aCurveCoeff fp.Element
4445
var bCurveCoeff fp.Element
4546

4647
// twist
@@ -97,7 +98,7 @@ type E6 = fptower.E6
9798
type E12 = fptower.E12
9899

99100
func init() {
100-
101+
aCurveCoeff.SetUint64(0)
101102
bCurveCoeff.SetUint64(1)
102103
// D-twist
103104
twist.A1.SetUint64(1)
@@ -148,3 +149,8 @@ func Generators() (g1Jac G1Jac, g2Jac G2Jac, g1Aff G1Affine, g2Aff G2Affine) {
148149
g2Jac = g2Gen
149150
return
150151
}
152+
153+
// CurveCoefficients returns the a, b coefficients of the curve equation.
154+
func CurveCoefficients() (a, b fp.Element) {
155+
return aCurveCoeff, bCurveCoeff
156+
}

ecc/bls12-377/ecdsa/ecdsa.go

+1-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ecc/bls12-377/fp/element.go

+4-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ecc/bls12-377/fr/element.go

+4-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ecc/bls12-377/fr/fft/domain.go

+31-12
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)