correcthorsebatterystaple
this: http://xkcd.com/936/
You can try it out at https://correcthorsebatterystaple.waynewerner.com
I don't log which passwords I generate, but if you're paranoid about security you probably should just generate the passwords locally.
This project started off using Flask. Then I realized that was overkill. I decdied to make this server be able to run with pure Python, because there's literally no reason not to.
The easiest way to try it out for yourself:
python3 -m pip install --user chbs
Then you can run:
chbs -h
And that should tell you everything you need to know.
Or, clone this repo and run:
python3 chbs/server.py
And then connect to it:
$ curl localhost:8000
correct horse battery staple$
Yeah. It won't return an ending newline. That's intentional.
I also decided that for funsies I should make this into a test. What is the difference between just:
- Single threaded server.
- A server using
select. - A server using
epoll. - A multithreaded server.
- A server using asyncio.
- A server using an aiohttp server.
My theory is that a single threaded server should be about as good as it gets. Or possibly using epoll or select? Given the size of the data that we're returning, I don't think that I'll get a lot of difference between any of these servers. We shall see.
The first server that I will produce will be just a single threaded server
using raw sockets and listen(20). That seems like a reasonably large queue?
To be honest, I'm not entirely certain how that works - in the past I've used
huge numbers or smaller numbers and didn't really see a difference.
CHANGELOG
0.2.2 - 2021-11-05
Fixed
- Moved wordlists to the server.py because pip installs weren't working right.
0.2.0 - 2020-10-28
Added
--oneflag for creating a single passphrase on the command line.
Metadata
Release files for chbs 0.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| chbs-0.2.2-py3-none-any.whl | Python 3 | none | any | Details for chbs-0.2.2-py3-none-any.whl |
Release files / chbs-0.2.2-py3-none-any.whl
| Download URL | chbs-0.2.2-py3-none-any.whl |
|---|---|
| Size | 48.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e48b4111499f3fc1417606827fcd74c595fcc889920788a7e71b5914879df12e
|
|
BLAKE2b-256 checksum How to use checksums |
283677437c548276e9a4eda67c538c31b4e992d5d30e3cb44545ab1418f8fa44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.0
|
Security for chbs 0.2.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.