Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

block-filler

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

block-filler

Simple cl tool for spamming ethereum nodes with block filling transactions

  • 1.0.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Block filler

A simple command line tool for spamming ethereum nodes with block filling transactions using deployed smart contracts.

Install

npm install -g block-filler

Quickstart

> blockfiller --help
Usage: blockfiller [options]

Options:
  --help                 Show help                                     [boolean]
  --version              Show version number                           [boolean]
  --jobfilepath, -j, -f  Path to input file.                 [string] [required]
  --accountfilepath, -a  Path to an account file containing addresses and
                         private keys. These can be used as "from" accounts and
                         signing the transactions locally.              [string]

Jobs

The script works with jobs given as input. They are specified in a JSON file as objects in an array:

  • rpc (string): the rpc endpoint of an ethereum node,
  • batchNum (num): how many transactions are sent at once
  • tx (object): transaction object as in web3
    • The blocks will be filled up ~ the specified gas limit
    • Nonces are set in the script
  • slow (bool): whether to fill the blocks with more time consuming slow operations or relatively overpriced fast ones (default: fast)
  • once (bool) whether to execute job only once or run it in an infinite loop
  • noWaitForAll (bool) whether to wait until the whole batch is mined or not

See an example below.

Example

blockfiller -f ./jobs.json -a ./accounts.json

Example content of a jobs file (jobs.json):

[
    {
        "rpc": "http://localhost:8545",
        "batchNum": 10,
        "tx": {
            "from": "0xb5ee8b57b0519a32b9c6d9689bc645f3edf51302",
            "gas": 7999000,
            "gasPrice": 61
        },
        "once": true
    },
    {
        "rpc": "https://volta-rpc.energyweb.org",
        "batchNum": 1,
        "tx": {
            "from": "0xb5125eb59b200e36cf06adb57ea948ac9e6202a0",
            "gas": 7999000,
            "gasPrice": 200
        },
        "slow": true
    },
    {
        "rpc": "https://tobalaba-rpc.energyweb.org",
        "batchNum": 1,
        "tx": {
            "from": "0xb5125eb59b200e36cf06adb57ea948ac9e6202a0",
            "gas": 1000000,
            "gasPrice": 1000000000
        },
        "noWaitForAll": true
    }
]

Example content of accounts file (accounts.json). These are added to web3's software wallet and used for signing locally:

[
    {
        "address": "0xb5ee8b57b0519a32b9c6d9689bc645f3edf51302",
        "privateKey": "0x..."
    },
    {
        "address": "0xb5125eb59b200e36cf06adb57ea948ac9e6202a0",
        "privateKey": "0x..."
    }
]

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests.

Versioning

SemVer is used for versioning. For the versions available, see the tags on this repository.

License

This project is licensed under the GPLv3.0 License - see the LICENSE.md file for details.

Keywords

FAQs

Package last updated on 30 Jul 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc