Skip to content
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

Expose certificate verification status to node.js #3

Open
bu5hm4nn opened this issue Jun 15, 2018 · 0 comments
Open

Expose certificate verification status to node.js #3

bu5hm4nn opened this issue Jun 15, 2018 · 0 comments
Labels
enhancement New feature or request

Comments

@bu5hm4nn
Copy link
Collaborator

bu5hm4nn commented Jun 15, 2018

When the DTLS connection is negotiated, mbedtls will attempt to verify the certificate. Depending on the setting, the connection will be refused when the certificate fails or a warning will be issued and the connection established anyways.

To support these two scenarios we need to

  1. Expose the verification setting to node js. Specifying this setting should be made mandatory in the API. ( MBEDTLS_SSL_VERIFY_NONE, MBEDTLS_SSL_VERIFY_OPTIONAL and MBEDTLS_SSL_VERIFY_REQUIRED)

  2. Expose an optional callback that can be registered from nodejs for the server to be notified about whether verification has succeeded when set to MBEDTLS_SSL_VERIFY_OPTIONAL.

To verify that the setting works, create test/example programs and associated Keys and Certificates that will demonstrate

  1. Handshake with only keys and MBEDTLS_SSL_VERIFY_NONE.

  2. With MBEDTLS_SSL_VERIFY_OPTIONAL
    a. Handshake with successful verification reported by the callback.
    b. Handshake with failed verification reported by the callback.

  3. With MBEDTLS_SSL_VERIFY_REQUIRED
    a. Successful verification
    b. failed verification

@bu5hm4nn bu5hm4nn added the enhancement New feature or request label Jun 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant