-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Doc cleanup, to work better with the cheese shop
- Loading branch information
Showing
4 changed files
with
34 additions
and
81 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,37 +3,7 @@ | |
setup(name='rdrand', | ||
version='0.9.9', | ||
description="Python interface to Intel hardware rng", | ||
long_description= \ | ||
"""RDRAND | ||
====== | ||
A module to use Intel's hardware RNG with python's random class | ||
USAGE | ||
----- | ||
#easy_install rdrand | ||
#python | ||
>>>from rdrand import RdRandom | ||
>>>r = RdRandom() | ||
At this point, ``r`` will behave just like ``random`` | ||
``RdRandom`` is a subclass of ``random.Random``, and behaves like ``random.Random``, | ||
but it uses inline assembly to access the hardware RNG. This should be | ||
a cryptographically secure drop in replacement for ``random``, if the Intel random number | ||
generator is valid. No mitigation is done to modify the output of the hardware to prevent problems with Intel's implementation. Caveat Emptor. | ||
Also, it includes the function ``r.getrandombytes(i)`` where ``i`` is a positive int. This returns a string | ||
of length ``i`` filled with random bytes, which is ideal for generating a key or using directly in a protocol. | ||
Please note, as with any security solution, it is possible to subvert this. Please understand the full context before deploying. I am not liable for misuse or clever hackers. | ||
Works with 32 and 64 bit builds of python. | ||
Works with python2 and python3. | ||
""", | ||
long_description= "".join(open('setup.rst').readlines()), | ||
author="Chris Stillson", | ||
author_email="[email protected]", | ||
url='https://github.com/stillson/rdrand', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
RDRAND | ||
------ | ||
|
||
A module to use Intel's hardware RNG with python's random class | ||
|
||
USAGE | ||
===== | ||
|
||
|
||
| # easy_install rdrand | ||
| # python | ||
>>> from rdrand import RdRandom | ||
>>> r = RdRandom() | ||
|
||
At this point, ``r`` will behave just like ``random`` | ||
|
||
``RdRandom`` is a subclass of ``random.Random``, and behaves like ``random.Random``, but it uses inline assembly to access the hardware RNG. This should be a cryptographically secure drop in replacement for ``random``, if the Intel random number generator is valid. No mitigation is done to modify the output of the hardware to prevent problems with Intel's implementation. Caveat Emptor. | ||
|
||
Also, it includes the function ``r.getrandombytes(i)`` where ``i`` is a positive int. This returns a string of length ``i`` filled with random bytes, which is ideal for generating a key or using directly in a protocol. | ||
|
||
Please note, as with any security solution, it is possible to subvert this. Please understand the full context before deploying. I am not liable for misuse or clever hackers. | ||
|
||
Works with 32 and 64 bit builds of python. | ||
|
||
Works with python2 and python3. | ||
|
||
Planned for version 2: various mitigations to whiten the random numbers in case you don't trust Intel. | ||
|