core-wg / oscore

Object Security for CoAP
7 stars 3 forks source link

Potential things to add to future update #263

Open emanjon opened 3 years ago

emanjon commented 3 years ago
chrysn commented 2 years ago

As for encryption of the sequence number, I don't see much benefit given that the key ID is still around. (Token and MID might be hidden by a proxy).

I would see value if we'd manage to encrypt the whole OSCORE option (except for the first bit that'd indicate it's encrypted), but that'd depend on all clients to learn a secret the sever shares with all its OSCORE clients for a limited time. However, I'm doubtful whether the added complexity (especially around "how to reliably roll over" and "how to prevent downgrades where an intermediary pretends that the server couldn't decrypt the encrypted OSCORE option") warrants the added privacy, given that a proxy (that hides tokens / MIDs, otherwise this is all kind of for nothing) could also establish an OSCORE tunnel with the server.

chrysn commented 2 years ago

Also, comparing to DTLS 1.3, whenever OSCORE does its equivalent of CID changes, sequence numbers reset anyway. (Tracking across CID changes is what motivates sequence number encryption in draft-ietf-tls-dtls13-43 Section 11).

In general, I appreciate collecting these things for further updates, and trust that we'll jointly do very careful vetting of anything that increases implementation complexity.

chrysn commented 2 years ago

There was related discussion today in EDHOC on not having visible identifiers, where the visibility of identifiers came up again.

emanjon commented 2 years ago

Great that you are commenting Christian. I added padding and identity update mechanism to the list above. I think kids need to be visible. The mitigation would like be a kid update mechanism similar to QUIC and DTLS 1.3

I fully agree with you. The list is not meant to be things that should be done. It is a list of potential things that we might do after careful vetting any benefits against increased implementation complexity.

We should maybe discuss to add a identity update mechanism to the rekeying mechanism document "Key Update for OSCORE (KUDOS)"

emanjon commented 2 years ago

One thing that could be added IF there ever is an RFC8613bis is: Discussion on lower layers. OSCORE does not discuss address updates. I assume it can be assumed that the server send responses to the address it received the request from. A MITM might change the address of an observe registration and use that as an DDoS attack. Not sure how practical the attack is but DTLS 1.3 writes that it is a concern.

https://github.com/EricssonResearch/coap-actuators/blob/master/draft-mattsson-t2trg-amplification-attacks.md

chrysn commented 2 years ago

Based on the impact on cacheable OSCORE (see its issue 19), I suggest that any future update revisit the classification of the Observe option; outer-only would solve a few problems, and does save a byte here and there.