Daniel Liu
ed67fd4200
crypto/secp256k1: remove external LGPL dependencies ( #17239 )
2025-01-24 16:18:28 +08:00
gitglorythegreat
9ca3d10001
crypto/bn256: fix MulScalar ( #30974 )
...
The `a` parameter should be used in the `MulScalar` function. The
upstream cloudflare and google repos have already merged fixes.
Reference:
*
8d7daa0c54
* https://github.com/cloudflare/bn256/pull/33
2025-01-04 11:00:57 +08:00
kevaundray
e581093ce1
crypto, tests/fuzzers: add gnark bn254 precompile methods for fuzzing ( #30585 )
...
Makes the gnark precompile methods more amenable to fuzzing
2025-01-04 11:00:57 +08:00
Daniel Liu
15be5ba464
crypto: use decred secp256k1 directly ( #30595 )
2025-01-04 11:00:57 +08:00
zhiqiangxu
e19093f344
crypto: remove hardcoded value for secp256k1.N ( #30126 )
2025-01-04 11:00:57 +08:00
SuiYuan
104a97354a
crypto/secp256k1: change receiver variable name to lowercase ( #29889 )
2025-01-04 11:00:57 +08:00
George Ma
136e87fa4c
crypto: fix docstrings and comments
2025-01-04 11:00:57 +08:00
Daniel Liu
efad15f9f4
crypto: use clear from go1.21 ( #29307 )
2025-01-04 11:00:57 +08:00
Daniel Liu
d0566e4165
crypto: update to go version 1.22 ( #28946 )
2025-01-04 11:00:57 +08:00
Daniel Liu
3fbbc9da9f
crypto: fix typos in comments ( #29186 )
2024-12-09 17:49:00 +08:00
Daniel Liu
727855752c
crypto: add support for blobs in eth_fillTransaction ( #28839 )
2024-12-09 17:49:00 +08:00
Daniel Liu
fabfcc7f6c
crypto: fix docstring names ( #28923 )
2024-12-09 17:49:00 +08:00
Daniel Liu
cae53aa7fd
crypto/kzg4844: add helpers for versioned blob hashes ( #28827 )
2024-12-09 17:49:00 +08:00
Daniel Liu
824dea669c
crypto/kzg4844: use the new trusted setup file and format ( #28383 )
2024-12-09 17:49:00 +08:00
Daniel Liu
b5cc7e6fc0
crypto/blake2b: put architecture-dependent features behind build-tag ( #28381 )
...
This change to fixes a compilation-flaw on master, by putting architecture-specific functions behind corresponding build tags.
2024-12-09 17:49:00 +08:00
Daniel Liu
f7b6ad67a7
crypto, tests: update fuzzers to native go fuzzing ( #28352 )
2024-12-09 17:49:00 +08:00
Daniel Liu
247ebd6a6d
crypto/kzg4844: do lazy init in all ckzg funcs ( #27679 )
...
* crypto/kzg4844: remove unnecessary init call & fix typo
* Fix kzg4844 tests/benchmarks
* Make init lazy & revert changes to tests
2024-12-09 17:49:00 +08:00
Daniel Liu
bd93c59bae
crypto: replace noarg fmt.Errorf with errors.New ( #27333 )
2024-12-09 17:49:00 +08:00
Daniel Liu
ed03a99770
crypto/kzg4844: upgrade c-kzg-4844 to v0.2.0 ( #27257 )
2024-12-09 17:49:00 +08:00
Daniel Liu
bedd571091
crypto/kzg4844: pull in the C and Go libs for KZG cryptography ( #27155 )
2024-12-09 17:49:00 +08:00
Daniel Liu
797efe74af
crypto: more linters and fix typo ( #24783 )
2024-12-09 17:49:00 +08:00
Daniel Liu
cb3edac2c7
crypto: use btcec/v2 for no-cgo ( #24533 )
2024-12-09 17:49:00 +08:00
Daniel Liu
949fa6358e
crypto/ecies: use AES-192 for curve P384 ( #24139 )
...
Using curve P384 for encryption causes the error "ecies: shared key params
are too big". Also, readme.md says curve P384 should use AES192 not AES256.
Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de>
2024-12-09 17:49:00 +08:00
Daniel Liu
146bc2be7b
crypto: add go:build lines ( #23468 )
2024-12-09 17:49:00 +08:00
Daniel Liu
9dab065373
crypto: gofuzz build directives ( #23137 )
2024-12-09 17:49:00 +08:00
Daniel Liu
b1c719029c
crypto: improve trie updates ( #21047 )
2024-12-09 17:49:00 +08:00
Daniel Liu
a64e42463a
crypto/bn256: refine comments according to #19577 , #21595 , and #21836 ( #21847 )
2024-12-09 17:49:00 +08:00
Daniel Liu
a2eb8553e8
crypto/bn256: better comments for u, P and Order ( #21836 )
2024-12-09 17:49:00 +08:00
Daniel Liu
f948466976
crypto: less allocations when hashing and tx handling ( #21265 )
2024-12-09 17:49:00 +08:00
Daniel Liu
ee303c9f3d
crypto/ecies: improve concatKDF ( #20836 )
2024-12-09 17:48:59 +08:00
Daniel Liu
b2be754647
crypto/bn256: fix import line ( #20723 )
2024-12-09 17:48:59 +08:00
Daniel Liu
6033722b72
crypto: use golangci-lint ( #20295 )
2024-12-09 17:48:59 +08:00
Daniel Liu
e1eb00ef99
crypto: make unit tests work with Go 1.13 ( #20053 )
2024-12-09 17:48:59 +08:00
Daniel Liu
ad5e7d6db3
crypto: add SignatureLength constant and use it everywhere ( #19996 )
2024-12-09 17:48:59 +08:00
Daniel Liu
8dcea8ddf8
crypto: replace t.Log(); t.FailNow() with t.Fatal() ( #19849 )
2024-12-09 17:48:59 +08:00
Daniel Liu
b9054b220c
crypto: replace fmt.Println calls with t.Log in tests ( #19670 )
2024-12-09 17:48:59 +08:00
Daniel Liu
66dd846d46
crypto/bn256/cloudflare: fix comments to describe the updated curve parameters ( #19577 )
...
* Removed comment section referring to Cloudflare's bn curve parameters
* Added comment to clarify the nature of the parameters
* Changed value of xi to i+9
2024-12-09 17:48:59 +08:00
Daniel Liu
d2ac7d0987
crypto: fix build when CGO_ENABLED=0 ( #19121 )
...
Package crypto works with or without cgo, which is great. However, to make it
work without cgo required setting the build tag `nocgo`. It's common to disable
cgo by instead just setting the environment variable `CGO_ENABLED=0`. Setting
this environment variable does _not_ implicitly set the build tag `nocgo`. So
projects that try to build the crypto package with `CGO_ENABLED=0` will fail. I
have done this myself several times. Until today, I had just assumed that this
meant that this package requires cgo.
But a small build tag change will make this case work. Instead of using `nocgo`
and `!nocgo`, we can use `!cgo` and `cgo`, respectively. The `cgo` build tag is
automatically set if cgo is enabled, and unset if it is disabled.
2024-12-09 17:48:59 +08:00
Daniel Liu
9d9bd65a01
crypto/ecies: remove unused function ( #19096 )
2024-12-09 17:48:59 +08:00
Daniel Liu
92fc843683
crypto: switch over to upstream sha3 package ( #18390 )
2024-12-09 17:48:59 +08:00
Daniel Liu
95f8abb765
crypto/bn256: fix staticcheck warning SA9009: ineffectual compiler directive
2024-10-30 21:10:45 +08:00
Daniel Liu
c6e4e880ea
all: fix staticcheck warning SA4006: never used value
2024-10-24 17:37:19 +08:00
JukLee0ira
47d27fed3b
all: replace uses of ioutil with io and os ( #24869 )
2024-09-27 15:14:17 +08:00
Daniel Liu
4f9501f12c
common, crypto: move fuzzers out of core ( #22029 )
2024-09-22 19:25:37 +08:00
JukLee0ira
2d89951e5b
all: use errrors.New instead of empty fmt.Errorf
2024-06-14 19:19:21 +08:00
Daniel Liu
01e1728a94
all: add support for EIP-2718, EIP-2930 transactions ( #21502 )
2024-05-14 23:15:35 +08:00
Daniel Liu
48f9bbed50
core: types: less allocations when hashing and tx handling ( #21265 )
2024-05-13 22:07:03 +08:00
JukLee0ira
d6737b69e6
rpc:remove package ethereum/go-ethereum
2024-05-13 19:51:50 +08:00
Wanwiset Peerapatanapokin
30581274a1
RIN-08 RIN-10 RIN-11 Fix curve issues ( #425 )
...
* update secp256k1 library from go-eth code
* cast deprecated functions to use new BitCurve type
* add IsOnCurve checks and tests
* add test outcome check
2024-02-11 01:51:11 +04:00
Liam
513114dacf
Merge pull request #398 from XinFinOrg/XDC-01
...
XDC-01 | Potential Missed Fixings in `crypto` Module
2024-01-22 14:53:49 +08:00