The widespread use of public key cryptosystems on the Internet has led to a
proliferation of publicly known but not necessarily acknowledged keys that
are used for testing purposes or that ship preconfigured in applications.
These keys provide no security, but since there's no record of them,
relying parties are often unaware that they provide no security. In order
to address this issue, this document provides a set of standard public test
keys that may be used wherever a preconfigured or sample key is required
and, by extension, also in situations where such keys may be used, such as
when testing digitally signed data. Their purpose corresponds roughly to
that of the EICAR test file, a non-virus used as a test file for antivirus
products, and the GTUBE file, a similar file used with spam-detection
products.
Crypto library developers may want to use these keys as their standard test
keys, and CAs should check for them when issuing certificates to make sure
that they're not certifying test keys for production use.
Peter.
--
You received this message because you are subscribed to the Google Groups "dev-secur...@mozilla.org" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dev-security-po...@mozilla.org.
To view this discussion on the web visit https://groups.google.com/a/mozilla.org/d/msgid/dev-security-policy/ME0P300MB0713E3C29CAA7213BE419AB1EE412%40ME0P300MB0713.AUSP300.PROD.OUTLOOK.COM.
>Relying parties should be checking keys against the dataset maintained by
>pwnedkeys.com, which has a great many keys, both test and otherwise,
>including the keys contained in RFC9500 (included since ~December 2023).
Nice! Any chance of publishing either the SPKIs or the SPKI hashes? There
are lots of things around that can't make arbitrary Internet requests every
time they see a new key.
Peter.
>I have concerns around doing so, as the data set is very large, and
>constantly updating.
Ah, I didn't realise it was that big, I thought it'd be a small collection
that could be turned into a bloom filter. If there's that many of them the
data would be interesting, any chance of publishing stats, how many
compromised keys, how many are X.509, how many are SSH, etc?
>While I'm sure there are *some* things that can't make arbitrary requests,
>I'm less confident about the "lots" part.
I'm referring to embedded systems, which have no internet access but end up
seeing keys from who-knows-where. When you see a connection with a cert
issued to Some State in Some Country [0] you've got a pretty good idea that
the private key is unlikely to be very private, but apart from that there's no
other indication that there's a problem.
That would be another reason to see what's present, although that could also
be handled in the stats without having to publish actual keys/certs, what are
the top identifiers used with non-private keys? That could be applied like a
top-ten bad passwords filter, if you can get people to stay away from the most
commonly-used insecure keys it's at least some progress.
Peter.
[0] For those who don't recognise this, it's the default OpenSSL cert data.
Hi Rob,
I don’t have any opinion on the other questions, but for:
> Should it be enabled or disabled by default?
For better or worse, it is not uncommon to install linting software on the same host as the CA system itself. In fact, that is how one popular CA software suite invokes external linters: it expects a CLI tool to be installed locally to perform linting. Having a linter running on the CA host dial out to the wider Internet is not a good idea given the security-sensitive nature of the host and the software it is running. For this reason, I think this lint should be disabled by default.
A secondary concern is that external API calls are harder to reason about in terms of performance impact due to variability in API response times.
Thanks,
Corey
To view this discussion on the web visit https://groups.google.com/a/mozilla.org/d/msgid/dev-security-policy/MW4PR17MB4729D5B085D8F19F74F244EFAA4C2%40MW4PR17MB4729.namprd17.prod.outlook.com.
>For example, every time someone says "why not just provide an SPKI dump?", I
>explain why that won't work without additional engineering to ensure currency
>of the dataset, and then... crickets.
It doesn't have to be perfect, it just has to be good enough, and in
particular better than what we have now which is nothing at all. Thus my
earlier comment that even a top-ten would be a good start, particularly if
that covers 90% of uses cases from widely-used software, i.e. prompts users to
use something other than the hardcoded out-of-the-box key in the app.
Peter.
>There's roughly 2M keys in the pwnedkeys dataset at present. Splitting by
>type can *kinda* be done, insofar as I keep track of whether the format of
>the key I found was PKCS1, PKCS8, OpenSSH, PuTTY, etc, but that's not
>definitive, since OpenSSH reads other formats of key, and they're all just
>big numbers anyway, at the end of the day.
Switching hats to the one that looks a lot like Sherlock Holmes' deerstalker,
it'd be really interesting to see stats for this since I had no idea there
were that many compromised keys out there. I think this would be quite
interesting to security researchers depending on how much data you've got on
the keys, breadown by key types, arrival rate (is it a steady trickle from
leaks or does it come in bursts due to large-scale compromises), etc. Heck,
just anything to help us understand key leaks/compromises a bit more, until
now I didn't even know how bad it was.
Peter.
Matt Palmer <mpa...@hezmatt.org> writes:
>Your proposed approach of pre-bundling, as I understand it, doesn't appear to
>meet that requirement, as it would seem to capture a point-in-time snapshot
>of the Pwnedkeys dataset.
Le mieux est l'ennemi du bien (the best is the enemy of the good). Given that
attackers seem to have no problems getting their hands on high-value Windows
code signing keys, I would imagine they have even less trouble getting as many
random noddy keys used to access a single server somewhere as they want. So
even with an always-online constantly-updated dataset what you're getting is a
best-effort subset of all compromised keys, which in turn means that while it
would be nice to have access to an up-to-the-minute dataset, in practice
access to even an older subset is still pretty good value.
In particular I see it not as a magic bullet do deal with the vast number of
likely-compromised but not necessarily known keys but more as a hygiene issue
to catch test keys inadvertently used in production, that sort of thing. Like
bad passwords, you're never going to be able to enumerate every possible weak
password, but even rejecting the top ten will deal with the low-hanging fruit,
force attackers to work a bit harder, and incentivise users to not use the
weakest possible passwords out there.
Peter.
>Well, I don't know if it's actually all that interesting to security
>researchers, since I've never had anyone ask in the six years I've been
>running Pwnedkeys.
That could be because it's been pretty well under the radar until now, I knew
it existed but that was about it, and I've never seen it mentioned in research
publications.
>But yes, I've got records of every time I find a key, including algorithm,
>bits/curve (as appropriate), when it was found, where it was found, how it
>was found, what format it was in, key passphrase (for cracked keys), and
>anything else that seemed potentially useful when I built it.
Very nice!
>I've got a whole load of research ideas floating around, but not the time to
>pursue them. For example, I had an experiment design for a measurement of
>the real-world effectiveness of revocation, but couldn't justify the time
>commitment to do the work relative to other (money-making) work. I don't
>suppose you've got a spare part-time research fellowship in your back pocket?
Nothing sorry, I work in industry despite the .edu address. However if you
look at the arxiv.org collection there's quite a few papers there which are
really just "here's a data dump, see if you find it useful" (with a lot of
padding commentary text to make it longer), so what you've got above shouldn't
preclude publication in some form or other.
(Not saying that you must do this, but just pointing out that it sounds like
there's enough there to be posted somewhere).
Peter.