{"name":"ethereumjs-blockchain","version":"3.3.3","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.6.1","ethashjs":"~0.0.7","ethereumjs-block":"~2.1.0","ethereumjs-common":"~0.6.0","ethereumjs-util":"~6.0.0","flow-stoplight":"^1.0.0","level-mem":"^3.0.1","lru-cache":"^4.1.3","safe-buffer":"^5.1.2","semaphore":"^1.1.0"},"devDependencies":{"coveralls":"^3.0.2","nyc":"^13.0.1","standard":"^11.0.1","tape":"^4.9.1"},"gitHead":"3c458defc8529e9a7b2ef146432ff7751cd288e4","_id":"ethereumjs-blockchain@3.3.3","_npmVersion":"6.4.1","_nodeVersion":"8.12.0","_npmUser":{"name":"holgerd77","email":"Holger.Drewes@gmail.com"},"dist":{"integrity":"sha512-B2612y7DwOZK3ONo0DLsENB3Rx0R5QOqJno9MTPY48BNiDwEwcPfYRUz/DD8F4/5kkbx0kGQBomPMauHSRv66Q==","shasum":"5bc8ef0a587281ece6056ff4871bba43b12af0d1","tarball":"http://registry-npm.ywwl.com/ethereumjs-blockchain/download/ethereumjs-blockchain-3.3.3.tgz","fileCount":7,"unpackedSize":77577,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcLw+BCRA9TVsSAnZWagAAbHsQAJ2sAllHJ7RrA5ljzL6d\nJx0fumAlGZoh1o7oojbme+K5MuFCmXbipkyRmmkOc74PpZSB4Iq13pSfuSQ4\n5ryzZ/3lPXQYaZvHabz8pU42EXbeaP/YyCxaX/hy73L/fReFNVC0mpDhP7OG\nhu85Q3718iYVDO0co65pMEUC3VesTZ7FNCpZgsH1ocTt0VHOWVqXeQDHVSqk\nzVvgRIbqigF3RcbncPCjajWCFW6C6iNLJOrA0cuYMGCyAGa2w9RWqSxedwo8\nNP0j3cv+wB6P1DL+o7+achw6s//nY68YS9Uadm9LGTMu5a5BjW2tRYrHfIU0\nx1P8xBqMcIQNP0v+N7WUysZ5zSpsWG4+YG+nk1OetHjECNUAHPFwYSroDZsQ\nDsxSV8VlSbb197+1aWiRzy7R8yINFNaKWa3+pYjXTlDqp/F0YHCXoVTHC/SY\nFzb7+cGedFakAI3UmBl4583AqAVLvDEeSnNDvwZ4oISmQ6piIpyeEcWa7R2X\nmAQlZh2WgE+3G1nqeff4xd3/SLUizCat6sgXqzJmHzc4dugeYV7LoeW9lxxR\nFh0c26QTGArObtcvkrysZWENCPHgsfvE8+txz5s2QRxE10wlnN3oF503xSBl\nbQccUWDHyj00ybSztDUaMR9SP0sMm6HFcCfWd/ZFZZ8Csbx2L10FiJoa/5fZ\nh/IE\r\n=lDlk\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICHEoemDz+yrgzmoWd+gkvX5Bvtmor1U4CofQTfukwwHAiBuHrSFFgEWpL8G4w74VTn2GDEux3opP5okdbbA8njZNA=="}],"size":16800,"noattachment":false,"key":"/ethereumjs-blockchain/-/ethereumjs-blockchain-3.3.3.tgz"},"maintainers":[{"email":"alextsg@gmail.com","name":"alextsg"},{"email":"alex@rtfs.hu","name":"axic"},{"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"},{"email":"v@pulim.com","name":"vpulim"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ethereumjs-blockchain_3.3.3_1546588033109_0.134162461963365"},"_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":1546588033274,"_cnpm_publish_time":1546588033274,"dist-tags":{"latest":"4.0.4"}}