shamblett / coap

A Coap package for dart
Other
16 stars 13 forks source link

fix: bump dtls2 to version 0.11.0, handle all exceptions during connect #163

Closed JKRhb closed 1 year ago

JKRhb commented 1 year ago

This PR bumps dtls2 to version 0.11.0 which solves a problem that could occur if the use of PSK ciphers suites was indicated with no PSK callback defined. In this case (e.g., in the get_resource_secure example when commenting out the callback argument) a segmentation fault could occur with not further information. The new version fixes this problem.

To be able to properly handle all exceptions that can occur during the connection establishment, the on clause now captures all Exception objects, closes the client, and rethrows them.