{"name":"ethereumjs-blockchain","version":"3.1.0","description":"A module to store and interact with blocks","main":"index.js","scripts":{"coverage":"nyc npm run test && nyc report --reporter=text-lcov > .nyc_output/lcov.info","coveralls":"npm run coverage && coveralls <.nyc_output/lcov.info","lint":"standard","test":"tape ./test/index.js"},"repository":{"type":"git","url":"git+https://github.com/ethereumjs/ethereumjs-blockchain.git"},"keywords":["ethereum","blockchain"],"author":{"name":"mjbecze","email":"mjbecze@gmail.com"},"license":"MPL-2.0","bugs":{"url":"https://github.com/ethereumjs/ethereumjs-blockchain/issues"},"homepage":"https://github.com/ethereumjs/ethereumjs-blockchain#readme","dependencies":{"async":"^2.1.2","ethashjs":"~0.0.7","ethereumjs-block":"~1.7.0","ethereumjs-util":"~5.2.0","flow-stoplight":"^1.0.0","levelup":"^1.3.0","memdown":"^1.1.0","safe-buffer":"^5.1.1","semaphore":"^1.0.3","lru-cache":"^4.1.2"},"devDependencies":{"coveralls":"^3.0.0","nyc":"^11.8.0","standard":"^11.0.1","tape":"^4.2.1"},"gitHead":"d9d5fd5e34fcf56f92b972b52411a6599508b275","_id":"ethereumjs-blockchain@3.1.0","_npmVersion":"5.6.0","_nodeVersion":"8.4.0","_npmUser":{"name":"holgerd77","email":"Holger.Drewes@gmail.com"},"dist":{"integrity":"sha512-rpF5m5sYVd0j9NfnXmAs01FkAeHoGAntr7tHrOKNf3rE+1dVTF+yqv27FflOvZTz/cVjcqUHddj5t6TruDEQhg==","shasum":"23b05c951450f9411c29566717e74c71db0f4ce1","tarball":"http://registry-npm.ywwl.com/ethereumjs-blockchain/download/ethereumjs-blockchain-3.1.0.tgz","fileCount":7,"unpackedSize":65776,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbBnFUCRA9TVsSAnZWagAAHA8QAJkXHijneKEJ21Mplvjx\nJ9S2GTF7wnjMJHEIVzSHdcHKlPF23SjBpywCnLzvrH8FZ/8uIIgZPBLwNvUD\nTv3zvfBS9uBwj0NKDzLyMl8SHOqGog5peNjW/DUzw3KlZQ/piCkycCvfVeHz\ne0NIwZfLWP5SV+7fZDvZfnpC8NQYH/0oiKCtYdVqLQxxAHhb6K/ihbPzURyk\nzO0aGsLOOwEANCOvyiGCnmsHk/ZA1P+yVgPnBb2p4853F8OrYollnvyz/JMp\nitVhgdUWfZMaF79MR1PIOIV68IOqU6iN5Z7KrJTtdg1wPnlZeIr4t4DZuWV1\nFFcoyYUvRz2YG/9W3HqiRwf0DW/MG3CsdF1cWB1yH21d7HmbeRjQIrztfP2I\n3w5n8HLPyeAXy/3OxQuVddCKeTOK9u8j6ssNqoBQ4/tP0E4r3O7DD4gZsT3S\nLnn+RXMrTyQBKHFDupDv4PbkfJI74EAcIkgG/TPRtVzAZBLXLXxEjFI8MbOF\nuJ6WvmPR9yB5Vh1++etZ/FwCl7CzNZCAyZlBhgG+TPN2XQ+jqfCqrrYqyN+A\n3ZMYL5fBP+Dvp1BOCPlwru6zrb/JYFYG7Cl8k5drKTBBZmDXRa5pE1CHsDNW\n74XlUVvshE9vgFOmGxRJyo9b0AdxkfhTvadQ09SYhFq7sZel8iOqG55sNG0H\na3Kb\r\n=kDjK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGTi+eXEdn0Di5V+rPmy88CEAR9pWPuHHZiihfLHOe2CAiEA1EO0VHGoUzaiXP3/xZMPuS+sJhIOWHPOvp9qlURBzb8="}],"size":14603,"noattachment":false,"key":"/ethereumjs-blockchain/-/ethereumjs-blockchain-3.1.0.tgz"},"maintainers":[{"email":"Holger.Drewes@gmail.com","name":"holgerd77"},{"email":"j-wasinger@hotmail.com","name":"jwasinger"},{"email":"aaron@kumavis.me","name":"kumavis"},{"email":"null_radix@riseup.net","name":"null_radix"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ethereumjs-blockchain_3.1.0_1527148883422_0.6321792231683632"},"_hasShrinkwrap":false,"deprecated":"New package name format for new versions: @ethereumjs/blockchain. Please update.","readme":"# SYNOPSIS\n\n[![NPM Package](https://img.shields.io/npm/v/ethereumjs-blockchain.svg?style=flat-square)](https://www.npmjs.org/package/ethereumjs-blockchain)\n[![Actions Status](https://github.com/ethereumjs/ethereumjs-blockchain/workflows/blockchain-test/badge.svg)](https://github.com/ethereumjs/ethereumjs-blockchain/actions)\n[![Coverage Status](https://img.shields.io/coveralls/ethereumjs/ethereumjs-blockchain.svg?style=flat-square)](https://coveralls.io/r/ethereumjs/ethereumjs-blockchain)\n[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/ethereum/ethereumjs-lib?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) or #ethereumjs on freenode\n\nA module to store and interact with blocks.\n\n# INSTALL\n\n`npm install ethereumjs-blockchain`\n\n# API\n\n[./docs/](./docs/README.md)\n\n# EXAMPLE\n\nThe following is an example to iterate through an existing Geth DB (needs `level` to be installed separately).\n\nThis module performs write operations. Making a backup of your data before trying it is recommended. Otherwise, you can end up with a compromised DB state.\n\n```javascript\nconst level = require('level')\nconst Blockchain = require('ethereumjs-blockchain').default\nconst utils = require('ethereumjs-util')\n\nconst gethDbPath = './chaindata' // Add your own path here. It will get modified, see remarks.\nconst db = level(gethDbPath)\n\nnew Blockchain({ db: db }).iterator(\n  'i',\n  (block, reorg, cb) => {\n    const blockNumber = utils.bufferToInt(block.header.number)\n    const blockHash = block.hash().toString('hex')\n    console.log(`BLOCK ${blockNumber}: ${blockHash}`)\n    cb()\n  },\n  err => console.log(err || 'Done.'),\n)\n```\n\n**WARNING**: Since `ethereumjs-blockchain` is also doing write operations\non the DB for safety reasons only run this on a copy of your database, otherwise this might lead\nto a compromised DB state.\n\n# EthereumJS\n\nSee our organizational [documentation](https://ethereumjs.readthedocs.io) for an introduction to `EthereumJS` as well as information on current standards and best practices.\n\nIf you want to join for work or do improvements on the libraries have a look at our [contribution guidelines](https://ethereumjs.readthedocs.io/en/latest/contributing.html).\n","publish_time":1527148883512,"_cnpm_publish_time":1527148883512,"dist-tags":{"latest":"4.0.4"}}