{ "info": { "author": "Vladislav Yarmak", "author_email": "vladislav-ex-src@vm-0.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: No Input/Output (Daemon)", "Intended Audience :: System Administrators", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Operating System :: POSIX :: Linux", "Programming Language :: Python :: 3.5", "Topic :: Internet", "Topic :: Security", "Topic :: Security :: Cryptography", "Topic :: System :: Operating System Kernels :: Linux", "Topic :: Utilities" ], "description": "# drb-client\n\nDistributed Randomness Beacon client\n\nGathers entropy from multiple [drand](https://github.com/dedis/drand) instances, securely mixes responses and outputs to kernel entropy pool or stdout. Suitable for use with [League of Entropy](https://www.cloudflare.com/leagueofentropy/) servers (see \"Running\" section).\n\n`drb-client` can be used as a standalone source of high-quality random number, or as additional source for entropy pool in Linux kernel. Produced amount of entropy should be sufficient to derail attacks based on RNG predictability.\n\n## Cryptography background\n\n`drb-client` polls list of `drand` servers with given interval and requests private entropy data portion from each one. Communication between `drb-client` and `drand` is protected with AES256-GCM encryption derived on BN-256 curve on top of TLS (this is imposed by `drand` API format).\n\n`drb-client` constructs each output of entropy from at least `quorum` (`-Q` option) distinct inputs. It is assumed at least `node_count - quorum + 1` nodes produce truly unpredictable secure random numbers, so any `quorum` of distinct responses definitely contain at least one truly random input (due to [pigeonhole principle](https://en.wikipedia.org/wiki/Pigeonhole_principle)).\n\nEntropy portions from beacon servers are mixed using stateful HKDF-based mixer. Each sufficient set of random responses is used to produce random output and new salt value for HKDF mixer. Therefore, mixer output becomes unpredictable after successful generation of first output, even if all beacon servers get compromised and start feeding client with biased data.\n\nDefault poll interval is 60 seconds and such interval is chosen for a reason. `drand` generates entropy for each response using its `/dev/urandom`. On Linux `urandom` gets reinitialized from `/dev/random` each 1 minute. So there is no reason to fetch random data more often: responses between reinitializations are in functional dependence.\n\n## Installation\n\nRequires Python 3.5.3+\n\n### From PyPI\n\n```\npip3 install drb-client\n```\n\n### From source\n\nDownload or clone repository and run following command in source code directory:\n\n```\npip3 install .\n```\n\n## Running\n\nThere are few available entropy sinks (option `-O`):\n\n* `devrandom` - (default) writes collected entropy into `/dev/random` device, without increment of kernel counter of available entropy in pool.\n* `stdout` - writes collected entropy into standard output.\n* `rndaddentropy` - writes collected entropy into `/dev/random` device with increment of kernel counter of available entropy in pool. Requires superuser privileges to operate.\n\nYou may obtain latest `group.toml` config with list of League of Entropy servers [here](https://github.com/dedis/drand/tree/master/deploy).\n\nRun with default sink:\n\n```\ndrb-client group.toml\n```\n\nContribute into `/dev/random` and increment entropy counter:\n\n```\nsudo drb-client -O rndaddentropy group.toml\n```\n\nFor logging into file see \"Synopsis\" section.\n\n## Synopsis\n\n```\n$ drb-client --help\nusage: drb-client [-h] [-v {debug,info,warn,error,fatal}] [-l FILE]\n [-Q QUORUM] [-T PERIOD] [-w TIMEOUT]\n [-O {stdout,rndaddentropy,devrandom}]\n group_config\n\nDistributed Randomness Beacon client\n\npositional arguments:\n group_config group config\n\noptional arguments:\n -h, --help show this help message and exit\n -v {debug,info,warn,error,fatal}, --verbosity {debug,info,warn,error,fatal}\n logging verbosity (default: info)\n -l FILE, --logfile FILE\n log file location (default: None)\n\npoll options:\n -Q QUORUM, --quorum QUORUM\n minimal answers required on each poll. Default value\n is (node_count // 2 + 1). (default: None)\n -T PERIOD, --period PERIOD\n poll interval for each source (default: 60)\n -w TIMEOUT, --timeout TIMEOUT\n timeout for each request (default: 4)\n\noutput options:\n -O {stdout,rndaddentropy,devrandom}, --output {stdout,rndaddentropy,devrandom}\n entropy output (default: devrandom)\n```\n\n## Deployment\n\nYou may obtain latest `group.toml` config with list of League of Entropy servers [here](https://github.com/dedis/drand/tree/master/deploy).\n\nSee [deploy/drb-client.service](https://github.com/Snawoot/drb-client/blob/master/deploy/drb-client.service) for example of systemd unit file.\n\n\n## Credits\n\n* [League of Entropy](https://www.cloudflare.com/leagueofentropy/) project\n* [drand](https://github.com/dedis/drand) project\n* Jack Lloyd for [BN256 implementation for Python](https://github.com/randombit/pairings.py)\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/Snawoot/drb-client", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "drb-client", "package_url": "https://pypi.org/project/drb-client/", "platform": "", "project_url": "https://pypi.org/project/drb-client/", "project_urls": { "Homepage": "https://github.com/Snawoot/drb-client" }, "release_url": "https://pypi.org/project/drb-client/0.3.0/", "requires_dist": [ "aiohttp (>=3.4.4)", "sdnotify (>=0.3.2)", "cryptography (>=2.0)", "toml", "async-exit-stack" ], "requires_python": ">=3.5.3", "summary": "Distributed Randomness Beacon client", "version": "0.3.0" }, "last_serial": 5771767, "releases": { "0.2.1": [ { "comment_text": "", "digests": { "md5": "82c9b6d58ddec2c342e80d1af32b7a90", "sha256": "15eca307e6b2705941dc46b5ee39b2f4dfb8bd37a45ebec1e22ca40b3a9c250e" }, "downloads": -1, "filename": "drb_client-0.2.1-py3-none-any.whl", "has_sig": false, "md5_digest": "82c9b6d58ddec2c342e80d1af32b7a90", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5.3", "size": 19523, "upload_time": "2019-07-03T19:52:13", "url": "https://files.pythonhosted.org/packages/8a/48/d15235240aa959b9e0c6935323b0a212831fd19afb31cd38cb8b2adb59cd/drb_client-0.2.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "30040b0d3798f3191a7079a87acfe7ed", "sha256": "154e43e64e5543ee992ff35408e3fe35e4630c24abe9c4d798e163941b533806" }, "downloads": -1, "filename": "drb_client-0.2.1.tar.gz", "has_sig": false, "md5_digest": "30040b0d3798f3191a7079a87acfe7ed", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.3", "size": 18873, "upload_time": "2019-07-03T19:52:15", "url": "https://files.pythonhosted.org/packages/6f/b6/9920d6d440b79ac56e761d226d0736b888763e579093ba28cdb24d0b49e1/drb_client-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "4329b31e60d1063de7b2ee40b4fa46df", "sha256": "2ade58b3ad065b9b2b160b8f514f472dd1473672d8c4f8da33354482d9597b61" }, "downloads": -1, "filename": "drb_client-0.2.2-py3-none-any.whl", "has_sig": false, "md5_digest": "4329b31e60d1063de7b2ee40b4fa46df", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5.3", "size": 19551, "upload_time": "2019-07-16T14:21:01", "url": "https://files.pythonhosted.org/packages/b6/c2/53972add89516001aa3902740a400851c782bf1d386fc8faab2aac39bfff/drb_client-0.2.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "1af1b266ff69741daa9545af7bf73613", "sha256": "eb5e252b70363e19f6a76ae8bd33fd9685e5f446514231eadce1d2d74da637e9" }, "downloads": -1, "filename": "drb_client-0.2.2.tar.gz", "has_sig": false, "md5_digest": "1af1b266ff69741daa9545af7bf73613", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.3", "size": 18901, "upload_time": "2019-07-16T14:21:03", "url": "https://files.pythonhosted.org/packages/a3/f2/987d447d0a80cab3dca6fc81d84da7912ece6393680fecd32ba4408d3cf9/drb_client-0.2.2.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "ccb3212eac55d6b97df1c5ce9047b868", "sha256": "9abb617b3bceb24e239847f5cee3a831fdaa47bace2ba86da161811c826667dd" }, "downloads": -1, "filename": "drb_client-0.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "ccb3212eac55d6b97df1c5ce9047b868", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5.3", "size": 19797, "upload_time": "2019-09-02T16:35:00", "url": "https://files.pythonhosted.org/packages/80/7d/9d43489c823d664a6fb2d7f6d19b4808a7fbe59c194d9ff65025b0c0e40c/drb_client-0.3.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e7529bb7c8f0031bf6242865eae6b6fb", "sha256": "ec732355714200edb7944fa29b2aa254719713c2b895ec3bd525f0a10808e90c" }, "downloads": -1, "filename": "drb_client-0.3.0.tar.gz", "has_sig": false, "md5_digest": "e7529bb7c8f0031bf6242865eae6b6fb", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.3", "size": 19128, "upload_time": "2019-09-02T16:35:02", "url": "https://files.pythonhosted.org/packages/14/73/eb2e27a6144c5dd2e29b78289b1606f75302f996b5ee32befecd8531e8a2/drb_client-0.3.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "ccb3212eac55d6b97df1c5ce9047b868", "sha256": "9abb617b3bceb24e239847f5cee3a831fdaa47bace2ba86da161811c826667dd" }, "downloads": -1, "filename": "drb_client-0.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "ccb3212eac55d6b97df1c5ce9047b868", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.5.3", "size": 19797, "upload_time": "2019-09-02T16:35:00", "url": "https://files.pythonhosted.org/packages/80/7d/9d43489c823d664a6fb2d7f6d19b4808a7fbe59c194d9ff65025b0c0e40c/drb_client-0.3.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "e7529bb7c8f0031bf6242865eae6b6fb", "sha256": "ec732355714200edb7944fa29b2aa254719713c2b895ec3bd525f0a10808e90c" }, "downloads": -1, "filename": "drb_client-0.3.0.tar.gz", "has_sig": false, "md5_digest": "e7529bb7c8f0031bf6242865eae6b6fb", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.3", "size": 19128, "upload_time": "2019-09-02T16:35:02", "url": "https://files.pythonhosted.org/packages/14/73/eb2e27a6144c5dd2e29b78289b1606f75302f996b5ee32befecd8531e8a2/drb_client-0.3.0.tar.gz" } ] }