https://git.schokokeks.org/derivepassphrase.git/tree/e98174420e001619acfd84a076f9df498076c89cRecent commits to derivepassphrase.git (e98174420e001619acfd84a076f9df498076c89c)2025-08-05T21:11:03+02:00tag:gitlist.org,2012:commit/e98174420e001619acfd84a076f9df498076c89cChange the code style to use double quotes for strings2025-08-05T21:11:03+02:00Marco Riccisoftware@the13thletter.info
<pre>As is standard in Python auto-formatting (Black, Ruff), we now use
double quotes for strings where possible, reverting to single quotes
only where necessary.
(The numerous code changes in `scripts/`, `src/` and `tests/` stem from
the auto-formatter re-adjusting the quotes.)
Background: I originally started out as a Perl programmer, and in Perl,
single quotes signify literal strings without any interpolation
whatsoever, and double quotes signify strings with interpolation and
escape sequences. In those languages, the choice of string quotes makes
a subtle difference. In Python, the choice of quote character does not
matter, so while there is no reason to prefer one over the other, the
inertia of being used to "single means literal, double means
interpolated" meant that I basically kept my existing style of quoting.
Python, meanwhile, although careful not to *prescribe* one quote
character or the other (see PEP 8), uses double quotes by default in
`str.__repr__` and in docstrings (see PEP 257). The Black
auto-formatter, which Ruff is modeled on, also defaults to double
quotes, arguing in its style guide that (among other things) the empty
string with double quotes unambiguously looks like an empty string,
regardless of fonts and syntax highlighting, but the empty string with
single quotes not necessarily: it may look like a single double quote
character.
More importantly, auto-formatters are specifically designed to make
these (essentially arbitrary) decisions about code formatting for you,
in the name of a uniform code style such that a reader can focus on the
code *content*, not the code *presentation*. The concrete set of
arbitrary decisions is essentially secondary, but the Black team (and
the Ruff team too) have a pretty good track record of keeping the
resulting code readable and sensibly diffable, and this styling decision
has long been established by Black and "blackened" code "in the wild"
(and thus tested), so I have no reason to object to this particular
arbitrary choice. Furthermore, there's no need to manually adjust all
quote characters, or even to pay much attention during code authoring to
the quote characters; the auto-formatting pass will take care of
harmonizing them for you.
Given these reasons, continuing to insist on single-quoted strings, in
Python, out of some vague sense of familiarity with *other* programming
languages where quote characters have different meanings, seems rather
untenable to me.
</pre>
tag:gitlist.org,2012:commit/0003d4596d632d41c7c03ff8145c152c9d0e4531Merge topic branch 'ssh-agent-socket-providers' into master2025-08-04T21:41:47+02:00Marco Riccisoftware@the13thletter.info
<pre>* ssh-agent-socket-providers:
Add a changelog entry for the SSH agent socket provider feature
Make all command/format/feature enums self-testing
Document the new level of support for SSH agents (also in `--version` output)
Update the "SSH key" feature flag in `--version` output
Support looking up a socket provider, even if merely registered
Add tests for the SSH agent socket provider machinery
Introduce a stubbed SSH agent, for testing
Introduce SSH agent socket providers
Turn the `ssh_agent` submodule into a subpackage
Generalize the error message for missing SSH agent support
</pre>
tag:gitlist.org,2012:commit/881e05f45103800021077ac152098af878c3295fAdd a changelog entry for the SSH agent socket provider feature2025-08-04T21:37:03+02:00Marco Riccisoftware@the13thletter.info
<pre>Also include a changelog entry for the self-testing feature flags.
</pre>
tag:gitlist.org,2012:commit/74b94268335a852cb6dad771aa7e5f13b8542324Update wishlist to post-v0.5.22025-08-03T21:57:58+02:00Marco Riccisoftware@the13thletter.info
<pre></pre>
tag:gitlist.org,2012:commit/269369a694a74c6d509755f82b32407cfcc32420Release 0.5.22025-08-03T21:47:37+02:00Marco Riccisoftware@the13thletter.info
<pre></pre>
tag:gitlist.org,2012:commit/af222512798d18348bd27f5a75b2c378ff204c40Merge topic branch 'fix-version-number' into master2025-08-03T20:45:36+02:00Marco Riccisoftware@the13thletter.info
<pre>* fix-version-number:
Fix the automatic version increment in `__init__.py`
</pre>
tag:gitlist.org,2012:commit/bf55246b94b88068d589977aada6ce60c80dbec5Fix the automatic version increment in `__init__.py`2025-08-03T20:45:21+02:00Marco Riccisoftware@the13thletter.info
<pre>Despite using software (`bump-my-version`) to automatically update all
version number references throughout the project, I forgot to include
a rule to update the version recorded in the code itself:
`derivepassphrase/__init__.py:__version__`. Thus, version 0.5 and
version 0.5.1 have been released while both claiming to be version "0.5
alpha 1 (development build 1)". Oops.
</pre>
tag:gitlist.org,2012:commit/608a84da61fabd375cf2859d21acfdb5d5f4b607Merge topic branch 'pageant-068-080-keys' into master2025-08-03T20:20:55+02:00Marco Riccisoftware@the13thletter.info
<pre>* pageant-068-080-keys:
Add a script to query test key signatures and derived passphrases from an agent
Add Pageant 0.68–0.80 signatures and derived passphrases for DSA keys
Harmonize syntax for the test key definitions
</pre>
tag:gitlist.org,2012:commit/07abfb9a325939fbb8f06378b1819bbfe0cf171aAdd a script to query test key signatures and derived passphrases from an agent2025-08-03T20:07:56+02:00Marco Riccisoftware@the13thletter.info
<pre>The script attempts to upload each test key to the running SSH agent,
then queries the agent for the signature of the `vault` UUID and
computes the derived passphrase. If that works, then it prints the test
key, augmented by the new signature and new derived passphrase, in
a `repr`-compatible representation that could principally directly be
included into the `tests` module.
(The real code in the `tests` module basically only differs in
whitespace: the hex codes that make up the signatures and the key data
are wrapped manually, in a manner that highlights their structure but
which is difficult/tedious to produce automatically.)
The script has only been tested on UNIX, and because it imports the
`tests` module directly, it should be run in a compatible environment,
e.g., the `hatch-static-analysis` environment.
</pre>
tag:gitlist.org,2012:commit/ea2c3cb5d4ca09932f947922c91baaa906daeb25Add Pageant 0.68–0.80 signatures and derived passphrases for DSA keys2025-08-03T19:59:19+02:00Marco Riccisoftware@the13thletter.info
<pre>I generated these signatures and derived passphrases against a manually
compiled instance of Pageant 0.80. (Because, as already hinted at in
d2bb555fd898d63b413b37dc2bd1374d82daeffe, it is somewhat hard to obtain
pre-compiled versions of Pageant with a known security hole. It turned
out to be much easier to compile Pageant ourselves than to find an
unpatched PuTTY distribution.)
(These test vectors are not actually in active use yet.)
</pre>