-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Peer address validation #64
Comments
We have the same problem in 1.3, but there the active man-in-the-middle attack described above could be mitigated by triggering an "address validation" sub protocol (via post-handshake) either on each and every peer address change or when the rate of peer address changes is above a certain threshold. |
I would assume, that such an attack makes only sense, if an "amplified response" is expected. Is that the right assumption? |
I have some reservations wrt the use of Heartbeat as an address validation tool:
IIUC, your suggestion is for the DTLS stack to expose an address validation callback that must be supplied by the application? Not sure it'll fly -- the protocol should really clean up after itself if it creates attack surface, rather than relying on higher layers to do the mending -- but we can try if this is the only option. |
If the validation should be done in DTLS, it may cause more traffic. By the way, I don't thought on a "callback". It may be more a isVerified(address), setVerified(address), and a new error code when sending too large messages. But the implementation is out of the cope of the spec. Therefore I would only recommend something as that. |
"outside the established crypto context": But may be, you can provide some more details about that. "patchy": |
"Heartbeat": |
Why?
Peer address change is asynchronous from the PoV of the application. Your proposal above seems to imply the application does regular checks? But, yeah, the API details don't really matter (it's just an "implementation quality" consideration), as long as there's a usable API. I'm still very unsure this would be an acceptable way forward though.
Interestingly we don't say anything explicitly in this respect, so one can rightfully interpret it that way. This (i.e., requiring address validation via the heartbeat ping while limiting outgoing traffic to a minimum until the heartbeat pong is received) seems like a good way forward to me. (Certainly preferable to leaving the onus on the application.) |
Because I assume, that at least for CoAP, an ACK/SUCCESS doesn't require something additional and would cover a large part of "my traffic". And the left over traffic is something for "echo tag". But that just assumes CoAP. |
I simply prefer, that this "forwarding to upper layer" is not excluded from the valid solutions. |
It's not a question of excluding options: an implementation does exactly what it wants to. The point is that it's not possible to inflict requirements on all L7 specs from a spec at L4.5 :) |
Sure, all is not possible. But for those L7, which have defined means, it should be possible to apply them in order to optimize their way of using it. |
Yeah, if an implementation (especially an embedded one) wants to provide cross protocol optimisations, I don't see how we can outlaw it. What we need to describe here though is how to achieve internal coherency at the DTLS layer, without requiring external dependencies. |
Hello @thomas-fossati , I have questions on the attacks you described Eve (man-on-the-side) sends junk packet with the CID currently in use between Alice and Bob and a spoofed source address of Victor Eve (man-on-the-side) replays previous packet from Alice and changes source address to that of Victor Eve (man-in-the-middle) modifies packet from Alice to have the source address of Victor Thanks Philippe |
Hey @Philago ,
Even assuming that the record is rejected by the crypto layer, if the peer's address is successfully subverted in the connection context of the receiver (i.e. before any crypto processing is done), then any "return" traffic will be routed to that spoofed address -- either an existing one, i.e. the victim of a DDoS, or a blackhole to just deny service to the real peer).
I'm not sure I understand your remark. The spoofed peer will be "active" in the connection context of the subverted endpoint until a new record comes in from the legitimate peer. During that time window, any return traffic from the subverted endpoint is both a real DoS on the legitimate peer and a potential DDoS on a victim chosen by the attacker.
That's the intention. |
Try to read issue #69 . Updating the address is not only an issue under attack, it's also an issue assuming message reordering. |
I've read #69, and I agree with it (i.e., the receiver must not take into account old reordered records as far as peer address update is concerned). Yet I don't understand how does that relate to @Philago's comment? |
"newer record" based on the epoch/sequence_number. My current main concern about this is: |
Ah gotcha. Yes, I agree that to counter attack 2 above all is needed is #69, which also is necessary for general correctness of the protocol in presence of reordering at the network layer. |
Hello @thomas-fossati, thank you for your answers and thank you @boaks to have clarified my position. So to sum up we can tackle 1 and 2 with the address only being updated for "newer records, based on the epoch/sequence_number". 3 will be addressed with draft-tschofenig-tls-dtls-rrc-00 Correct ? |
Looks likely. I have tried to capture the discussion on my fork @boaks @Philago could you please check if this matches your thinking? |
Closed by #70 |
Alice has an active DTLS session + CID with Bob.
While the first two can be addressed, I don't know how to stop (or even mitigate the third).
We should add text to the SecCons along the following lines:
The text was updated successfully, but these errors were encountered: