keys: limit keytypes and validate uploads of the new keys API
split of from #8815 (closed)
-
limit possible uploaded keytypes -
bring back key format validation
We used to validate the pgp key actually looked like an armored pgp block. We should bring this back and have a similar thing for the katzenpost keys.
The two things could probably be combined in a datastructure like this
{ keytype: ClassThatVerifiesIt, openpgp: PgpKey }
Not sure if we need to expose these as a config option. For now i would say no - we don't.
Edited by azul