-
Notifications
You must be signed in to change notification settings - Fork 2k
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
tinydtls_sock_dtls: save session info after data successfully decrypted #14307
Conversation
LGTM, however, what about the other fix (#12907 (comment)) |
Added in 44f2f50 |
All green! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK. Tested this by sending a couple of UDP packets from a client to a server using examples/dtls-sock
.
BTW. Starting a server on a node and sending on the same node to localhost |
That has never worked on master either, main reason I would say is because how the application blocks on while waiting for handshake to finish. |
AFAIK the application does not do a busy wait, so that does not make sense. |
I think this is low-priority for now but I opened #14315 to note this in the issue tracker. |
commit 877790599bcf582681bc1663290ccf3cb241d9eb Merge: a4a5483 ba8d178 Author: M Aiman Ismail <muhammadaimanbin.ismail@haw-hamburg.de> Date: Fri Jun 19 16:33:59 2020 +0200 Merge branch 'tinydtls/enh/async-sock' of https://github.com/miri64/RIOT into tinydtls/enh/async-sock commit ba8d178 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Fri May 22 16:25:05 2020 +0200 tests: provide test for tinydtls with sock_async commit 7dc4f78 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:04:48 2020 +0200 sock_async: add missing license header to `net/sock/async/types.h` commit 4013c61 Author: Martine Lenders <m.lenders@fu-berlin.de> Date: Mon Dec 9 13:51:29 2019 +0100 tinydtls: add `sock_async` support for `sock_dtls` commit 1b23037 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Fri May 22 16:24:38 2020 +0200 sock_async: change flags for new sock_dtls behavior commit f402de2 Merge: 2bdf9b1 44f2f50 Author: Martine Lenders <m.lenders@fu-berlin.de> Date: Thu Jun 18 15:20:58 2020 +0200 Merge pull request RIOT-OS#14307 from pokgak/tinydtls/save-session-info tinydtls_sock_dtls: save session info after data successfully decrypted commit 44f2f50 Author: M Aiman Ismail <muhammadaimanbin.ismail@haw-hamburg.de> Date: Thu Jun 18 14:14:12 2020 +0200 tinydtls_sock_dtls: don't put alert & EVENT_CONNECT in mbox commit 2e16b90 Author: M Aiman Ismail <muhammadaimanbin.ismail@haw-hamburg.de> Date: Thu Jun 18 11:44:02 2020 +0000 tinydtls_sock_dtls: save session information after data decrypted commit a4a5483 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Thu Jun 18 07:51:40 2020 +0200 fixup! tests: provide test for tinydtls with sock_async commit 0b729ff Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Thu Jun 18 07:50:22 2020 +0200 fixup! tinydtls: add `sock_async` support for `sock_dtls` commit d6f0af6 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Fri May 22 16:25:05 2020 +0200 tests: provide test for tinydtls with sock_async commit 497fed7 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:45:29 2020 +0200 fixup! tinydtls: add `sock_async` support for `sock_dtls` commit 44e8be1 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:13:42 2020 +0200 fixup! tinydtls: add `sock_async` support for `sock_dtls` commit 5bff9bf Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:09:23 2020 +0200 fixup! tinydtls: add `sock_async` support for `sock_dtls` commit 609b0af Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:06:07 2020 +0200 fixup! tinydtls: add `sock_async` support for `sock_dtls` commit 0f17576 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Tue Jun 16 14:04:48 2020 +0200 sock_async: add missing license header to `net/sock/async/types.h` commit 6b55527 Author: Martine Lenders <m.lenders@fu-berlin.de> Date: Mon Dec 9 13:51:29 2019 +0100 tinydtls: add `sock_async` support for `sock_dtls` commit 8a8b912 Author: Martine S. Lenders <mail@martine-lenders.eu> Date: Fri May 22 16:24:38 2020 +0200 sock_async: change flags for new sock_dtls behavior
Contribution description
This PR fixes a bug (#12907 (comment)) in the tinydtls implementation of sock dtls where the session information is not saved after the data is successfully decrypted.
Testing procedure
Test using
examples/dtls-sock
using two native nodes. Try send normal message, empty, etc. The result should be the same with the version inmaster
.