Commit Graph

235 Commits

Author SHA1 Message Date
Martin Holst Swende
c60f7dd08d
deps: update minisign (#28066)
This updates minisign to the latest version. One new thing is that minisign (not go-minisign) has started to prehash the file, and in order to make geth pass the version-check, we need to sign the file in legacy-mode.
2023-09-07 04:18:46 -04:00
ucwong
2f77299136
go.mod: goupnp 1.3.0 (#28053) 2023-09-06 11:17:36 +03:00
Péter Szilágyi
5b159498bb
go.mod: regenerate all indirect dependencies to clean up the junk (#28037) 2023-08-31 16:00:31 +03:00
Péter Szilágyi
ab3762b2d9
go.mod: update pebble to crl-release-23.1 (#27967) 2023-08-23 10:50:28 +03:00
Martin Holst Swende
16946d218a
rpc: use go-winio for named pipes (#27972)
We're trying a new named pipe library, which should hopefully fix some occasional failures in CI.

---------

Co-authored-by: Felix Lange <fjl@twurst.com>
2023-08-23 04:39:01 +02:00
Marius van der Wijden
0b4b299099
go.mod: update docker (#27970) 2023-08-22 14:11:25 +03:00
Martin Holst Swende
55c5f5964d
travis, build: update Go to 1.21.0 (#27958)
build: update to go 1.21
2023-08-22 11:00:01 +03:00
ucwong
509cd428e9
go.mod: upgrade goja (#27899) 2023-08-14 14:59:05 +02:00
Felix Lange
e91b21ce2b
go.mod, build: upgrade c-kzg-4844 (#27907)
This upgrades to the latest release of ckzg, and also attempts to fix some blst-related
build errors that occur on launchpad.net.
2023-08-12 00:21:46 +02:00
Péter Szilágyi
be65b47645
all: update golang/x/ext and fix slice sorting fallout (#27909)
The Go authors updated golang/x/ext to change the function signature of the slices sort method. 
It's an entire shitshow now because x/ext is not tagged, so everyone's codebase just 
picked a new version that some other dep depends on, causing our code to fail building.

This PR updates the dep on our code too and does all the refactorings to follow upstream...
2023-08-12 00:04:12 +02:00
dependabot[bot]
86d7f5aeee
deps: update supranational/blst to 0.3.11 (#27890)
build(deps): bump github.com/supranational/blst

Bumps [github.com/supranational/blst](https://github.com/supranational/blst) from 0.3.11-0.20230406105308-e9dfc5ee724b to 0.3.11.
- [Release notes](https://github.com/supranational/blst/releases)
- [Commits](https://github.com/supranational/blst/commits/v0.3.11)

---
updated-dependencies:
- dependency-name: github.com/supranational/blst
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-08-10 06:50:09 -04:00
691dc334fa Update plugeth-utils 2023-08-08 20:58:22 +08:00
d730849b7e Use external main module
* renames main package so it's importable
* adds wrapmain sub-module as main module
2023-08-08 20:58:22 +08:00
Péter Szilágyi
1662228ac6
core/txpool/blobpool: 4844 blob transaction pool (#26940)
* core/blobpool: implement txpool for blob txs

* core/txpool: track address reservations to notice any weird bugs

* core/txpool/blobpool: add support for in-memory operation for tests

* core/txpool/blobpool: fix heap updating after SetGasTip if account is evicted

* core/txpool/blobpool: fix eviction order if cheap leading txs are included

* core/txpool/blobpool: add note as to why the eviction fields are not inited in reinject

* go.mod: pull in inmem billy form upstream

* core/txpool/blobpool: fix review commens

* core/txpool/blobpool: make heap and heap test deterministic

* core/txpool/blobpool: luv u linter

* core/txpool: limit blob transactions to 16 per account

* core/txpool/blobpool: fix rebase errors

* core/txpool/blobpool: luv you linter

* go.mod: revert some strange crypto package dep updates
2023-07-27 13:45:35 +03:00
Delweng
47b9f1b4ae
cmd/geth: use automaxprocs to apply cpu quota correctly (#27506)
It is usually best to set GOMAXPROCS to the number of available CPU cores. However, setting
it like that does not work well when the process is quota-limited to a certain number of CPUs.
The automaxprocs library configures GOMAXPROCS, taking such limits into account.
2023-07-14 19:14:47 +02:00
philip-morlier
e9630a85f4 This is a functional build a dev tagged release of foundation plugeth
This brings the project up to geth v1.12.0

The plugeth test plugin has been added but is failing on the live tracer hooks as of this commit
2023-07-13 13:10:19 -07:00
philip-morlier
e516d5842c automated merge 2023-07-11 16:01:17 -07:00
Felix Lange
cecd22143b
go.mod: upgrade github.com/karalabe/usb to fix build warning (#27698) 2023-07-11 22:34:22 +02:00
Guillaume Ballet
85b8d1c06c
params, trie: add verkle fork management + upgrade go-verkle (#27464)
* params, trie: add verkle fork management + upgrade go-verkle

* remove the two verkle files

* core, eth, params: add missing function

* Gary's feedback

* remove trie/utils/verkle.go

* add verkle block override

---------

Co-authored-by: Gary Rong <garyrong0905@gmail.com>
2023-06-28 12:08:48 +03:00
Marius van der Wijden
091c25d983
go.mod: update kzg libraries to use big-endian (#27510)
* go.mod: update kzg libraries to use big-endian

* go.sum: ran go mod tidy

* core/testdata/precompiles: fix blob verification test

* core/testdata/precompiles: fix blob verification test
2023-06-19 15:08:13 +03:00
Sina Mahmoodi
7823ff6d06
eth/tracers: refactor exporting js buffer (#27472)
We had to do this workaround because it wasn't possible to export typed arrays from
JS to []byte. This was added in dop251/goja@2352993, so we can use the better way now.
2023-06-14 19:07:24 +02:00
philip-morlier
d8d864768a Updated mod and sum to reflect v1.2.0
Also changed the injection and hook from hooktester to blockchain().
2023-06-12 13:37:29 -07:00
ucwong
cc2ab421e4
go.mod: golang.org/x upgrade (#27299)
go.mod:golang upgrade
2023-05-31 03:10:16 -04:00
Shude Li
6a6318b1d2
go.mod: usegopkg.in/yaml.v3 instead of github.com/go-yaml/yaml (#27295) 2023-05-17 23:35:30 +02:00
Felföldi Zsolt
c08dc59aad
beacon/types: add beacon chain data types (#27292)
* beacon/types: add beacon chain data types

* beacon/merkle: added comments

* go.mod: cleanups

---------

Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2023-05-17 17:39:33 +03:00
Felix Lange
41fafa47b6
go.mod: upgrade gencodec (#27288) 2023-05-17 15:03:38 +03:00
Justin Traglia
9ca84e6b0b
crypto/kzg4844: upgrade c-kzg-4844 to v0.2.0 (#27257)
Upgrade c-kzg-4844 to v0.2.0
2023-05-12 20:16:14 +03:00
Péter Szilágyi
2169fa343a
crypto/kzg4844: pull in the C and Go libs for KZG cryptography (#27155)
* cryto/kzg4844: pull in the C and Go libs for KZG cryptography

* go.mod: pull in the KZG libraries

* crypto/kzg4844: add basic becnhmarks for ballpark numbers

* cmd, crypto: integrate both CKZG and GoKZG all the time, add flag

* cmd/utils, crypto/kzg4844: run library init on startup

* crypto/kzg4844: make linter happy

* crypto/kzg4844: push missing file

* crypto/kzg4844: fully disable CKZG but leave in the sources

* build, crypto/kzg4844, internal: link CKZG by default and with portable mode

* crypto/kzg4844: drop verifying the trusted setup in gokzg

* internal/build: yolo until it works?

* cmd/utils: make flag description friendlier

Co-authored-by: Martin Holst Swende <martin@swende.se>

* crypto/ckzg: no need for double availability check

* build: tiny flag cleanup nitpick

---------

Co-authored-by: Martin Holst Swende <martin@swende.se>
2023-05-10 14:54:14 +03:00
philip-morlier
829b8c4821 Expose state trie to plugins
Also merged changes in support geth v1.11.6. Updated to plugeth-utils v1.1.0.
2023-05-05 14:14:15 -07:00
philip-morlier
1b5aa6c570 Updated plugeth-utils to v0.0.25 2023-04-27 09:07:44 -07:00
philip-morlier
c3e91ce1af These files were changed by hand to support the merge
The previous commit message was made in error, it should say v1.11.6 not v1.11.5. Fixing the commit message is causing us to have to fix confilicts and we are going to leave it alone.
The project builds but doesnt load the required pluggins. More work needs to be done acrross the various projects.
2023-04-26 14:32:55 -07:00
philip-morlier
e986bbfa6f Initial commit of merge geth v1.11.5 2023-04-21 13:24:40 -07:00
sudeep
7076ae00aa
cmd/geth: enable log rotation (#26843)
This change enables log rotation, which can be activated using the flag --log.rotate. Additional parameters that can be given are: 

  - log.maxsize to set maximum size before files are rotated,
  - log.maxbackups to set how many files are retailed, 
  - log.maxage to configure max age of rotated files, 
  - log.compress whether to compress rotated files

The way to configure location of the logfile(s) is left unchanged, via the `log.logfile` parameter.  

---------

Co-authored-by: Martin Holst Swende <martin@swende.se>
2023-04-03 05:05:36 -04:00
ucwong
dc2f4b9304
go.mod : update snappy (#27027) 2023-04-03 03:35:13 -04:00
Martin Holst Swende
0137bd69c5
go.mod: update golang.org/x/tools (#26960) 2023-03-24 12:39:20 +01:00
Martin Holst Swende
f6c3a534a4
metrics/influxdb: use smaller dependency and reuse code between v1 and v2 reporters (#26963)
This change switches to use the smaller influxdata/influxdb1-client package instead of depending on the whole infuxdb package. The new smaller client is very similar to the influxdb-v2 client, which made it possible to refactor the two reporters to reuse code a lot more.
2023-03-23 15:12:32 -04:00
philip-morlier
f3e558d4e0 Merge commit 'a38f41085' into merge/geth-v1.11.5
Manual touches in core/state_transtion.go and go.mod
2023-03-21 08:39:16 -07:00
Péter Szilágyi
8a9a73c99b
log: add special casing of uint256 into the logger (#26936) 2023-03-21 12:01:43 +02:00
Martin Holst Swende
b80f05bde2
core/vm: use golang native big.Int (#26834)
reverts #26021, to use the upstream bigint instead.
2023-03-08 13:12:53 -05:00
philip-morlier
6e40cd7920 Merge commit '5ed08c473' into merge/geth-v1.11.3 2023-03-07 10:04:53 -08:00
Péter Szilágyi
403cac71eb
README, go.mod, event, internal/version: bump min Go to 1.19 (#26803) 2023-03-03 12:24:09 +02:00
philip-morlier
89bc9e0ee6 updtated utils to v0.0.24 2023-02-23 09:44:05 -08:00
Martin Holst Swende
09a9ccdbce
core/rawdb, node: use standalone flock dependency (#26633) 2023-02-23 09:11:50 +02:00
philip-morlier
78e00bf68d Manual touches to preserve compatability of other networks with utils as well as fix a failing test in core/rawdb. 2023-02-21 10:29:25 -08:00
philip-morlier
bff86afa0c updated utils to v0.0.21 2023-02-17 14:11:53 -08:00
philip-morlier
ef92d21d25 Manual touches to modify types to conform to geth v1.11.1 2023-02-17 08:29:46 -08:00
philip-morlier
2f6b8d86f1 manual geth v1.11.1 merge 2023-02-17 07:53:01 -08:00
Péter Szilágyi
77380b9629
go.mod: update pebble to latest master (#26654) 2023-02-09 19:01:31 +02:00
Péter Szilágyi
bf1798e04e
common/prque: generic priority queue (#26290)
* common, core, eth, les, trie: make prque generic

* les/vflux/server: fixed issues in priorityPool

* common, core, eth, les, trie: make priority also generic in prque

* les/flowcontrol: add test case for priority accumulator overflow

* les/flowcontrol: avoid priority value overflow

* common/prque: use int priority in some tests

No need to convert to int64 when we can just change the type used by the
queue.

* common/prque: remove comment about int64 range

---------

Co-authored-by: Zsolt Felfoldi <zsfelfoldi@gmail.com>
Co-authored-by: Felix Lange <fjl@twurst.com>
2023-02-09 13:03:54 +02:00
Martin Holst Swende
ed51b8c5d3
ethdb: pebble backend (64bit platforms only) (#26517)
* ethdb: use pebble

Co-authored-by: Gary Rong <garyrong0905@gmail.com>

foo

update

* apply suggested changes

* flags: go format

node: fix ddir lookup mistake

accounts/abi/bind: fix go.mod replacement for generated binding

deps: update pebble + with fix 32-bit build

* ethdb/pebble: respect max memtable size

* core/rawdb, ethdb: enable pebble on non-32bit platforms only

* core/rawdb: fix build tags, fix some review concerns

* core/rawdb: refactor methods for database opening

* core/rawdb: remove erroneous build tag

* cmd/geth: fix the flag default handling + testcase

* cmd/geth: improve testing regarding custom backends

* ethdb/pebble, deps: update pebble dependency

* core/rawdb: replace method with Open

* ethdb/pebble: several updates for pebble (#49)

* ethdb/pebble: fix size count in batch

* ethdb/pebble: disable seek compaction

* ethdb/pebble: more fixes

* ethdb, core, cmd: polish and fixes (#50)

* cmd/utils, core/rawdb, ethdb/pebble: address some review concerns

* Update flags.go

* ethdb/pebble: minor refactors

* ethdb/pebble: avoid copy on batch replay

* ethdb: fix compilation flaw

* cmd: fix test fail due to mismatching error message

* cmd/geth, node: rename backingdb to db.engine

---------

Co-authored-by: Jared Wasinger <j-wasinger@hotmail.com>
Co-authored-by: rjl493456442 <garyrong0905@gmail.com>
Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2023-02-09 10:48:34 +02:00
Péter Szilágyi
d9699c8238
accounts, build, mobile: remove Andriod and iOS support 2023-02-03 12:29:07 +02:00
Martin Holst Swende
8ded6a9fcd
cmd/puppeth: remove puppeth 2023-01-31 10:16:30 +01:00
ucwong
a63875bf4d
go.mod: gnark-crypto upgrade (#26545) 2023-01-27 07:39:26 -05:00
Sina Mahmoodi
d36e6fc49d
go.mod: upgrade to latest goja (#26523)
Co-authored-by: Felix Lange <fjl@twurst.com>
2023-01-23 17:59:25 +01:00
meehow
24c7023df6
go.mod: upgrade to go-bip39 v1.1.0 (#26527) 2023-01-20 10:33:41 +01:00
Austin Roberts
026f9ef80c Align dependencies with matic 2022-12-30 10:21:24 -06:00
philip-morlier
c0530b8313 Updated plugin loader, mod, and sum to reflect changes made in utils v0.0.21. 2022-12-08 11:40:22 -08:00
Felix Lange
12df45662a
all: remove remaining uses of untyped golang-lru (#26194) 2022-11-17 11:15:28 +01:00
Jolly Zhao
f58ebd9696
all: use github.com/deckarep/golang-set/v2 (generic set) (#26159)
Co-authored-by: Felix Lange <fjl@twurst.com>
2022-11-14 15:16:52 +01:00
Martin Holst Swende
e34e540e4c
accounts/keystore: replace inotify with fsnotify (#26176) 2022-11-14 12:38:10 +01:00
Felix Lange
62c973eba6
go.mod: minimum Go version 1.18 (#26160)
This will allow use of generics and other new standard library APIs
such as package net/netip.
2022-11-11 13:11:24 +01:00
protolambda
0ad2014026
go.mod: update status-im/keycard-go (#26141) 2022-11-10 01:32:02 +01:00
Martin Holst Swende
15b7e0b254
common/math, tests/fuzzers: use big.Int clone (#26006)
* common/math, tests/fuzzers: use big.Int clone

* common/math: license
2022-10-18 15:42:16 +02:00
Martin Holst Swende
fb75f11e87
Revert "go.mod: upgrade github.com/dop251/goja" (#25975)
Revert "go.mod: upgrade github.com/dop251/goja (#25955)"

This reverts commit 9207e348f0.
2022-10-12 20:08:36 +02:00
ucwong
9207e348f0
go.mod: upgrade github.com/dop251/goja (#25955)
This upgrade pulls in a fix to handling of 'continue' in loops.
2022-10-12 12:03:45 +02:00
Felix Lange
564751668a
cmd/geth: fix help output issues (#25941)
This update resolves an issue where StringSliceFlag would not be
rendered correctly in help output + mention that -H can be used multiple times

Co-authored-by: Martin Holst Swende <martin@swende.se>
2022-10-06 19:59:23 +02:00
Guillaume Ballet
9d717167aa
cmd/geth: add a verkle subcommand (#25718)
* cmd/geth: add a verkle subcommand

* fix copyright year

* remove unused command parameters

* check that the output file was successfully written to

Co-authored-by: Martin Holst Swende <martin@swende.se>

* cmd/geth: goimports fix

Co-authored-by: Martin Holst Swende <martin@swende.se>
2022-09-14 12:05:03 +02:00
Austin Roberts
5a88b67e6f Update plugeth utils version 2022-08-25 14:54:19 -05:00
philip-morlier
81a8106bc6 Merge Geth v1.10.21 as well as update to Plugeth-Utils v0.0.18 2022-07-27 10:38:42 -07:00
rjl493456442
14b0eedacf
go.mod: downgrade leveldb (#25413) 2022-07-27 09:31:13 +03:00
Martin Holst Swende
62306a5ebe
deps: update goleveldb 2022-07-23 09:46:28 +02:00
Marius van der Wijden
e3c1a7c671
go.mod: updated logfmt dependency (#25231)
This fixes an issue in abigen tests with go 1.17.
2022-07-05 14:45:44 +02:00
willian.eth
52ed3570c4
cmd: migrate to urfave/cli/v2 (#24751)
This change updates our urfave/cli dependency to the v2 branch of the library.
There are some Go API changes in cli v2:

- Flag values can now be accessed using the methods ctx.Bool,
  ctx.Int, ctx.String, ... regardless of whether the flag is 'local' or
  'global'.

- v2 has built-in support for flag categories. Our home-grown category
  system is removed and the categories of flags are assigned as part of
  the flag definition.

For users, there is only one observable difference with cli v2: flags must now
strictly appear before regular arguments. For example, the following command is
now invalid:

   geth account import mykey.json --password file.txt

Instead, the command must be invoked as follows:

   geth account import --password file.txt mykey.json
2022-06-27 18:22:36 +02:00
ucwong
0f044f3433
go.mod: upgrade to latest goleveldb (#25067)
Co-authored-by: Felix Lange <fjl@twurst.com>
2022-06-23 10:35:27 +02:00
Martin Holst Swende
a907d7e81a
all: more linters (#24783)
This enables the following linters

- typecheck
- unused
- staticcheck
- bidichk
- durationcheck
- exportloopref
- gosec

WIth a few exceptions.

- We use a deprecated protobuf in trezor. I didn't want to mess with that, since I cannot meaningfully test any changes there.
- The deprecated TypeMux is used in a few places still, so the warning for it is silenced for now.
- Using string type in context.WithValue is apparently wrong, one should use a custom type, to prevent collisions between different places in the hierarchy of callers. That should be fixed at some point, but may require some attention.
- The warnings for using weak random generator are squashed, since we use a lot of random without need for cryptographic guarantees.
2022-06-13 16:24:45 +02:00
s7v7nislands
b453767ccd
go.mod: clean up (#25017) 2022-06-03 09:25:25 +02:00
Jonathan Le Brun
5bc4e8f09d
go.mod: set go version to 1.17 (#24926)
set go version to 1.17
2022-06-02 20:26:44 +02:00
Marius van der Wijden
3c6d6f7ee8
tests/fuzzers/bls12381: Add BLST to fuzzing support (#24249)
* tests/fuzzers/bls12381: added blst library

* go.mod: added blst dependency

* tests/fuzzers/bls12381: stuff

* tests/fuzzers/bls12381: added blst to pairing fuzzer
2022-06-02 13:13:28 +02:00
philip-morlier
2f93e2ae10 Merge feature/merge-v1.10.18-attempt-two 2022-05-25 13:07:38 -07:00
Felix Lange
b807f785c3
go.mod: upgrade to docker v1.6.2 (#24956)
This upgrade is necessary to silence a Dependabot warning.
2022-05-25 13:37:02 +02:00
Felix Lange
c9e324ce16
go.mod: upgrade to btcsuite/btcd/btcec v2.2.0 (#24939)
This should fully resolve dependency conflict issues in modules
that also depend on btcsuite/btcd v0.22.0.
2022-05-24 10:20:37 +02:00
Sina Mahmoodi
ba47d800b1
eth/tracers/js: drop duktape engine (#24934)
#23773 added a JS tracer which uses Goja as its engine. In this PR I remove the previous tracer which used duktape as well as remove the dependencies.

This PR also comes with 2 fixes in the Goja tracer and one small behavioural change:

    I had handled errors in the native Go functions by panicing. My oversight was that Goja only handles panics with a Goja.Value as argument. The difference is panic(goja.Value) allows JS to catch the exception whereas Interrupt(error) doesn't.
    There was a race in how I handled Stop.
    Because of 1. some of the methods that simply return nil on error (like memory.slice) now throw an exception.
2022-05-23 22:26:10 +02:00
Sina Mahmoodi
bf693228a3
eth/tracers/js: goja tracer (#23773)
This adds a JS tracer runtime environment based on the Goja VM. The new
runtime replaces the duktape runtime, which will be removed soon.

Goja is implemented in Go and is faster for cases where the Go <-> JS
transition overhead dominates overall performance. It is faster because
duktape is written in C, and the transition cost includes the cost of using
cgo. Another reason for using Goja is that go-duktape is not maintained
anymore.

We expect the performace of JS tracing to be at least as good or better with
this change.
2022-05-18 16:34:18 +02:00
philip-morlier
e87859e9ab Updating mod and sum to reflect plugeth-utils v0.0.17. Made corresponding changes to wrapper function to reflect the close() method on the Node object returned by NewNode(). Created a new tag v1.10.17-2 to reflect these changes. 2022-05-16 09:48:46 -07:00
s7v7nislands
7ab15490e9
all: use 'embed' instead of go-bindata (#24744) 2022-04-25 11:15:14 +02:00
Felix Lange
bb5633c5ee
go.mod: upgrade btcec and add 'chainhash' module requirement (#24700)
See ethereum/go-ethereum#24554 and btcsuite/btcd#1839

This is an attempt to resolve a Go module dependency issue that arises
when both 'github.com/btcsuite/btcd/btcec/v2' and the older, non-v2
btcd module are required as dependencies.
2022-04-17 14:53:25 +02:00
ucwong
d4d288e3f1
build: add imports for go generate tools (#24682)
This adds a tools.go file to import all command packages used for
go:generate. Doing so makes it possible to execute go-based code
generators using 'go run', locking in the tool version using go.mod.

Co-authored-by: Felix Lange <fjl@twurst.com>
2022-04-12 20:24:02 +02:00
Austin Roberts
011619ec82 Update plugeth-utils version 2022-04-05 13:31:38 -05:00
philip-morlier
4211c5c401 Merge tag 'v1.10.17' into merge/v1.10.17 2022-03-30 15:40:07 -07:00
philip-morlier
48f1bf8c4c Updating plugeth-utils to v0.0.15. 2022-03-30 15:31:53 -07:00
philip-morlier
4a33bc66c5 Changes in service of extending block context object into the tracer plugins 2022-03-30 15:20:54 -07:00
philip-morlier
ec965607cd Cahnges made in service of pretracer type. 2022-03-30 15:15:37 -07:00
philip-morlier
b404517691 Merge tag 'v1.10.16' into re-merge/v1.10.16 2022-03-30 15:03:13 -07:00
ucwong
763b3f8d1f
go.mod : upnp 1.0.3 stable version (#24573) 2022-03-29 22:33:19 +02:00
Jonathan Chappelow
830231c1c4
crypto: use btcec/v2 for no-cgo (#24533)
This updates the no-cgo implementations in the crypto package to use
the github.com/btcsuite/btcd/btcec/v2 module instead of the older btcec
package that was part of the main github.com/btcsuite/btcd module.

name                   old time/op  new time/op  delta
EcrecoverSignature-32   198µs ± 0%   144µs ± 0%  -27.11%
VerifySignature-32      177µs ± 0%   128µs ± 0%  -27.44%
DecompressPubkey-32    20.9µs ± 0%  10.1µs ± 0%  -51.51%

Use (*ModNScalar).IsOverHalfOrder instead of math/big.Int when checking
for malleable signatures.
2022-03-16 14:23:14 +01:00
ucwong
279409a98e
go.mod: upgrade upnp dependency (#24536) 2022-03-14 10:12:51 +02:00
Martin Holst Swende
4860e50e05
cmd/geth, node, rpc: implement jwt tokens (#24364)
* rpc, node: refactor request validation and add jwt validation

* node, rpc: fix error message, ignore engine api in RegisterAPIs

* node: make authenticated port configurable

* eth/catalyst: enable unauthenticated version of engine api

* node: rework obtainjwtsecret (backport later)

* cmd/geth: added auth port flag

* node: happy lint, happy life

* node: refactor authenticated api

Modifies the authentication mechanism to use default values

* node: trim spaces and newline away from secret

Co-authored-by: Marius van der Wijden <m.vanderwijden@live.de>
2022-03-07 09:30:27 +02:00
uji
8fddf27a98
internal/build: switch azure sdk from Azure/azure-storage-blob-go to Azure/azure-sdk-for-go/sdk/storage/azblob. (#24473)
* go.mod: update azure-storage-blob-go

update Azure/azure-storage-blob-go from v0.7.0 to v0.14.0.
relation #24396.

* internal/build: fix for breaking changes of azure-storage-blob-go

fix for breaking changes of update Azure/azure-storage-blob-go from v0.7.0 to v0.14.0.
relation #24396.

* internal/build: switch azure sdk from Azure/azure-storage-blob-go to Azure/azure-sdk-for-go/sdk/storage/azblob.

* internal/build refactor appending BlobItems

* internal/build: fix azure blobstore client to include container id

Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2022-03-02 13:05:14 +02:00
Felix Lange
9b93564e21
rlp/rlpgen: RLP encoder code generator (#24251)
This change adds a code generator tool for creating EncodeRLP method
implementations. The generated methods will behave identically to the
reflect-based encoder, but run faster because there is no reflection overhead.

Package rlp now provides the EncoderBuffer type for incremental encoding. This
is used by generated code, but the new methods can also be useful for
hand-written encoders.

There is also experimental support for generating DecodeRLP, and some new
methods have been added to the existing Stream type to support this. Creating
decoders with rlpgen is not recommended at this time because the generated
methods create very poor error reporting.

More detail about package rlp changes:

* rlp: externalize struct field processing / validation

This adds a new package, rlp/internal/rlpstruct, in preparation for the
RLP encoder generator.

I think the struct field rules are subtle enough to warrant extracting
this into their own package, even though it means that a bunch of
adapter code is needed for converting to/from rlpstruct.Type.

* rlp: add more decoder methods (for rlpgen)

This adds new methods on rlp.Stream:

- Uint64, Uint32, Uint16, Uint8, BigInt
- ReadBytes for decoding into []byte
- MoreDataInList - useful for optional list elements

* rlp: expose encoder buffer (for rlpgen)

This exposes the internal encoder buffer type for use in EncodeRLP
implementations.

The new EncoderBuffer type is a sort-of 'opaque handle' for a pointer to
encBuffer. It is implemented this way to ensure the global encBuffer pool
is handled correctly.
2022-02-16 18:14:12 +01:00
Felix Lange
fb3a6528cf
go.mod: upgrade to github.com/karalabe/usb v0.0.2 (#24356)
This upgrade resolves a build issue on Android 7+ and removes
a build warning on macOS >= 12.0.
2022-02-08 19:58:27 +01:00