Commit Graph

1440 Commits

Author SHA1 Message Date
rjl493456442 b6b6f52ec8
cmd: implement preimage dump and import cmds 2018-03-26 12:51:46 +03:00
Felföldi Zsolt 1488fdaf19 cmd/utils: fix maxpeers vs lightpeers logic (#16125) 2018-03-09 11:55:03 +02:00
Vlad Bokov 52697fb1b2
cmd/puppeth: allow any vhost in wallet 2018-03-09 00:02:31 +07:00
Kurkó Mihály 39c16c8a1e cmd, ethdb, vendor: integrate leveldb iostats (#16277)
* cmd, dashboard, ethdb, vendor: send iostats to dashboard

* ethdb: change names

* ethdb: handle parsing errors

* ethdb: handle iostats syntax error

* ethdb: r -> w
2018-03-08 14:59:00 +02:00
Kurkó Mihály 704840a8ad cmd, dashboard: use webpack dev server, remove custom assets (#16263)
* cmd, dashboard: remove custom assets, webpack dev server

* dashboard: yarn commands, small fixes
2018-03-08 10:22:21 +02:00
gluk256 f1d440a437 whisper: final refactoring (#16259)
whisper: final refactoring
2018-03-06 23:37:43 +01:00
Péter Szilágyi b7e57ca1d0
cmd/evm, core/vm, internal/ethapi: don't disable call gas metering 2018-03-05 14:01:13 +02:00
Martin Holst Swende 478143d69a utils: fix #16138 by checking if vhosts flag is set (#16141)
* utils: fix #16138 by checking if vhosts flag is set

* utils,node: fix defaults for rpcvhosts

* node,utils: address review concerns
2018-03-05 13:02:32 +02:00
Vlad 61a061c9b4 whisper: refactoring go-routines 2018-03-04 23:35:05 +01:00
Vlad 95cca85d6d whisper: minor refactoring 2018-03-03 21:37:16 +01:00
gluk256 66cd41af1e
Merge pull request #16231 from gluk256/303-reader
whisper: filereader mode introduced to wnode
2018-03-03 09:40:01 +01:00
Vlad 6219a33822 whisper: filereader mode introduced to wnode 2018-03-02 14:54:54 +01:00
Péter Szilágyi 49bcb5fbd5
Merge pull request #16228 from karalabe/faucet-background-skip
cmd/faucet: update state in background, skip when busy
2018-03-02 12:13:19 +02:00
Péter Szilágyi 6f13e515f4
cmd/faucet: update state in background, skip when busy 2018-03-02 12:02:23 +02:00
Zhenguo Niu d520bf4503 cmd/swarm: fix some typos in manifest cmd (#16227)
Replace "atleast" with "at least" in the manifest error message.
2018-03-02 10:59:26 +01:00
Vlad ee75a90ab4 whisper: topics replaced by bloom filters 2018-03-01 16:04:09 +01:00
gluk256 5a150e1b77 whisper: serious security issue fixed (#16219)
The diagnostic tool was saving the unencrypted version of the messages, which is an obvious
security flaw. As of this commit:
  * encrypted messages saved instead of plain text.
  * all messages are stored, even that created by the user of wnode.
2018-03-01 09:34:46 +01:00
Saulius Grigaitis c41f1a3e23 puppeth: fix Parity Chain Spec parameter GasLimitBoundDivision (#16188) 2018-02-27 12:56:51 +02:00
Guillaume Ballet 4c845bdc27
Merge pull request #16198 from gluk256/266-wnode
whisper: refactor wnode to systematically store messages if a directory is provided
2018-02-26 21:23:51 +01:00
Vlad f4e676cccd whipser: comments updated 2018-02-26 19:26:36 +01:00
Vlad 6e0667fa06 whisper: wnode updated - all messages are saved if savedir param is given 2018-02-26 13:58:04 +01:00
Domino Valdano d398d04e27 cmd/geth: fix broken links to JavaScript-Console wiki in cmd line help (#16183)
* Fixed broken link to JavaScript-Console wiki in cmd line help

* cmd/geth: Added missing r in 'JavaScript'
2018-02-26 11:38:17 +02:00
Anton Evangelatov dcca613a0b swarm: initial instrumentation (#15969)
* swarm: initial instrumentation with go-metrics

* swarm: initialise metrics collection and add ResettingTimer to HTTP requests

* swarm: update metrics flags names. remove redundant Timer.

* swarm: rename method for periodically updating gauges

* swarm: finalise metrics after feedback

* swarm/network: always init kad metrics containers

* swarm/network: off-by-one index in metrics containers

* swarm, metrics: resolved conflicts
2018-02-23 14:19:59 +01:00
Martin Holst Swende 44d40ffce1 core, vm, common: define constantinople fork + shift (#16045)
* core, vm, common: define constantinople fork, start implementation of shift instructions

* vm: more testcases

* vm: add tests for intpool erroneous intpool handling

* core, vm, common: fix constantinople review concerns

* vm: add string<->op definitions for new opcodes
2018-02-23 12:32:57 +02:00
Janos Guljas 6a9730edaa swarm, cmd/swarm: Merge branch 'master' into multiple-ens-endpoints 2018-02-22 18:51:34 +01:00
Janos Guljas a3a07350dc swarm, cmd/swarm: Merge branch 'master' into multiple-ens-endpoints 2018-02-22 14:23:17 +01:00
Péter Szilágyi 72c4c50777
cmd/faucet: resolve twitter user from final redirect 2018-02-22 13:20:36 +02:00
Nilesh Trivedi 085d3fbf72
cmd/puppeth: Don't allow hyphen in network name. Fixes #16155 2018-02-22 00:23:50 +05:30
Péter Szilágyi 01507d9b9d
cmd, console: support all termination signals 2018-02-21 15:23:10 +02:00
Guillaume Ballet 5f9b01a283 whisper: only use the node id as a p2p id, not for sending messages (#16102)
This is in preparation for the switch to libp2p: the ID generated
will be from a private key created with the help of libp2p's crypto
library, while Whisper will still use Go's default crypto libraries
for encrypting its messages. This change removes a conflict.

It shouldn't have any impact as the person receiving emails is
the user, not the node.
2018-02-15 14:43:48 +02:00
Péter Szilágyi b92276c700
Merge pull request #16098 from holiman/fix_import
main: add gc flags to import-command
2018-02-15 12:34:33 +02:00
Martin Holst Swende de93a9d437
main: add gc flags to import-command 2018-02-15 09:16:59 +01:00
Felix Lange a5c0bbb4f4
all: update license information (#16089) 2018-02-14 13:49:11 +01:00
Péter Szilágyi 12dab53495
cmd/puppeth: unify discv4 and discv5 ports 2018-02-12 16:27:53 +02:00
Martin Holst Swende 589b603a9b rpc: dns rebind protection (#15962)
* cmd,node,rpc: add allowedHosts to prevent dns rebinding attacks

* p2p,node: Fix bug with dumpconfig introduced in r54aeb8e4c0bb9f0e7a6c67258af67df3b266af3d

* rpc: add wildcard support for rpcallowedhosts + go fmt

* cmd/geth, cmd/utils, node, rpc: ignore direct ip(v4/6) addresses in rpc virtual hostnames check

* http, rpc, utils: make vhosts into map, address review concerns

* node: change log messages to use geth standard (not sprintf)

* rpc: fix spelling
2018-02-12 14:52:07 +02:00
Felix Lange 9123eceb0f p2p, p2p/discover: misc connectivity improvements (#16069)
* p2p: add DialRatio for configuration of inbound vs. dialed connections

* p2p: add connection flags to PeerInfo

* p2p/netutil: add SameNet, DistinctNetSet

* p2p/discover: improve revalidation and seeding

This changes node revalidation to be periodic instead of on-demand. This
should prevent issues where dead nodes get stuck in closer buckets
because no other node will ever come along to replace them.

Every 5 seconds (on average), the last node in a random bucket is
checked and moved to the front of the bucket if it is still responding.
If revalidation fails, the last node is replaced by an entry of the
'replacement list' containing recently-seen nodes.

Most close buckets are removed because it's very unlikely we'll ever
encounter a node that would fall into any of those buckets.

Table seeding is also improved: we now require a few minutes of table
membership before considering a node as a potential seed node. This
should make it less likely to store short-lived nodes as potential
seeds.

* p2p/discover: fix nits in UDP transport

We would skip sending neighbors replies if there were fewer than
maxNeighbors results and CheckRelayIP returned an error for the last
one. While here, also resolve a TODO about pong reply tokens.
2018-02-12 14:36:09 +02:00
Guillaume Ballet 5cf75a30c1 whisper: get wnode to work with v6 (#16051)
The bulk of the issue was to adapt to the new requirement
that a v6 filter has to either contain a symmertric key or
an asymmetric one.

This commits revert one of the fixes that I made to remove
a linter warning: unexporting NewSentMessage. This is not
really a problem as I have a cleanup in the pipe that will
solve this issue.
2018-02-10 15:35:32 +02:00
Péter Szilágyi 55599ee95d core, trie: intermediate mempool between trie and database (#15857)
This commit reduces database I/O by not writing every state trie to disk.
2018-02-05 17:40:32 +01:00
Felföldi Zsolt c3f238dd53 les: limit LES peer count and improve peer configuration logic (#16010)
* les: limit number of LES connections

* eth, cmd/utils: light vs max peer configuration logic
2018-02-05 15:41:53 +02:00
Martin Holst Swende ec28a58cc1
utils: fix #16006 by not lowering OS ulimit 2018-02-02 09:33:33 +01:00
Guillaume Ballet 367c329b88 whisper: remove linter warnings (#15972)
* whisper: fixes warnings from the code linter

* whisper: more non-API-breaking changes

The remaining lint errors are because of auto-generated
files and one is because an exported function has a non-
exported return type. Changing this would break the API,
and will be part of another commit for easier reversal.

* whisper: un-export NewSentMessage to please the linter

This is an API change, which is why it's in its own commit.
This change was initiated after the linter complained that
the returned type wasn't exported. I chose to un-export
the function instead of exporting the type, because that
type is an implementation detail that I would like to
change in the near future to make the code more
readable and with an increased coverage.

* whisper: update gencodec output after upgrading it to new lint standards
2018-01-26 13:45:10 +02:00
Felföldi Zsolt c335821479 cmd, params: update discovery v5 bootnodes (#15954) 2018-01-25 12:25:00 +02:00
Péter Szilágyi 5c83a4e5dd
Merge pull request #15832 from karalabe/abigen-events
accounts/abi/bind: support event filtering in abigen
2018-01-24 10:55:24 +02:00
Péter Szilágyi 1bf508b449
accounts/abi/bind: support event filtering in abigen 2018-01-24 10:54:13 +02:00
Felföldi Zsolt 92580d69d3 p2p, p2p/discover, p2p/discv5: implement UDP port sharing (#15200)
This commit affects p2p/discv5 "topic discovery" by running it on
the same UDP port where the old discovery works. This is realized
by giving an "unhandled" packet channel to the old v4 discovery
packet handler where all invalid packets are sent. These packets
are then processed by v5. v5 packets are always invalid when
interpreted by v4 and vice versa. This is ensured by adding one
to the first byte of the packet hash in v5 packets.

DiscoveryV5Bootnodes is also changed to point to new bootnodes
that are implementing the changed packet format with modified
hash. Existing and new v5 bootnodes are both running on different
ports ATM.
2018-01-22 13:38:34 +01:00
Felix Lange f08cd94fb7
cmd/ethkey: fix formatting, review nits (#15807)
This commit:

- Adds a --msgfile option to read the message to sign from a file
  instead of command line argument.
- Adds a unit test for signing subcommands.
- Removes some weird whitespace in the code.
2018-01-16 15:42:41 +01:00
Kurkó Mihály 938cf4528a dashboard: deep state update, version in footer (#15837)
* dashboard: footer, deep state update

* dashboard: resolve asset path

* dashboard: remove bundle.js

* dashboard: prevent state update on every reconnection

* dashboard: fix linter issue

* dashboard, cmd: minor UI fix, include commit hash

* remove geth binary

* dashboard: gitCommit renamed to commit

* dashboard: move the geth version to the right, make commit optional

* dashboard: commit limited to 7 characters

* dashboard: limit commit length on client side

* dashboard: run go generate
2018-01-15 11:20:00 +02:00
Péter Szilágyi bd0dbfa2a8
cmd/geth: user friendly light miner error 2018-01-12 11:59:18 +02:00
Ricardo Domingos 56152b31ac common/fdlimit: Move fdlimit files to separate package (#15850)
* common/fdlimit: Move fdlimit files to separate package

When go-ethereum is used as a library the calling program need to set
the FD limit.

This commit extract fdlimit files to a separate package so it can be
used outside of go-ethereum.

* common/fdlimit: Remove FdLimit from functions signature

* common/fdlimit: Rename fdlimit functions
2018-01-11 22:55:21 +02:00
Felix Lange 5c2f1e0014 all: update generated code (#15808)
* core/types, core/vm, eth, tests: regenerate gencodec files

* Makefile: update devtools target

Install protoc-gen-go and print reminders about npm, solc and protoc.
Also switch to github.com/kevinburke/go-bindata because it's more
maintained.

* contracts/ens: update contracts and regenerate with solidity v0.4.19

The newer upstream version of the FIFSRegistrar contract doesn't set the
resolver anymore. The resolver is now deployed separately.

* contracts/release: regenerate with solidity v0.4.19

* contracts/chequebook: fix fallback and regenerate with solidity v0.4.19

The contract didn't have a fallback function, payments would be rejected
when compiled with newer solidity. References to 'mortal' and 'owned'
use the local file system so we can compile without network access.

* p2p/discv5: regenerate with recent stringer

* cmd/faucet: regenerate

* dashboard: regenerate

* eth/tracers: regenerate

* internal/jsre/deps: regenerate

* dashboard: avoid sed -i because it's not portable

* accounts/usbwallet/internal/trezor: fix go generate warnings
2018-01-08 14:15:57 +02:00