Open attilamolnar opened 8 years ago
This is something I'd personally like to see and would be happy to implement for KICL once there's a spec. Would you see this as being specified in the STS policy or elsewhere? If it's the former, might be necessary to strip/replace the padding characters if base64 encoding is used:
:ircd.host CAP lol768 LS :sts=duration=31536000,pin-sha256=isi41AizREkLvvft0IRW4u3XMFR2Yg7bvrF7padyCJg=
Multiple values might also be a challenge with the existing spec since "Keys specified in this document MUST only occur at most once" and as an example my client implementation just uses a Map of String->String. Perhaps a different delimeter could be used.
I guess another capability would also work and side-step a few of these problems.
@lol768 Happy to see your interest. I think PKP shouldn't be implemented via the STS cap but be a different cap and perhaps use a different protocol as well to avoid having to escape data.
Regarding writing the specification, I've been waiting for STS to get a little momentum, get implemented in a few clients (making a publicly available test server helped) and see what, if any, suggestions implementors have about the STS specification before doing major work on PKP.
making a publicly available test server helped
If only I'd known about this before I started my work on STS client support... Ended up writing some very quick code to add it to charybdis, but I guess it ensured I understood the spec.
Is there a hostname I can connect to in order to test the STS stuff?
Nice work! Great to see projects starting to implement this enthusiastically, especially as I've not been able to prioritise client support on IRCCloud yet. The inspircd testnet is here and has sts enabled with a prefix as draft/sts
:
irc://testnet.inspircd.org:6667
Brilliant, seems to all be working. Apologies for derailing this issue somewhat
Likely relevant news item: RIP HPKP: Google abandons public key pinning
PKP is a security mechanism that allows servers to resist impersonation by MITMs using fraudulent certs.
Prior art is HTTP PKP (HPKP):