FelipeMdeO opened a new pull request, #3626: URL: https://github.com/apache/nuttx-apps/pull/3626
*Note: Please adhere to [Contributing Guidelines](https://github.com/apache/nuttx/blob/master/CONTRIBUTING.md).* ## Summary Backs Dropbear's SHA-256 and HMAC-SHA-256 with NuttX's native crypto (crypto/sha2.h, crypto/hmac.h) instead of the bundled libtomcrypt implementation, avoiding duplicate crypto code and reducing flash usage. `port/dropbear_ltc_sha256.c` / `port/dropbear_ltc_hmac_sha256.c ` implement libtomcrypt's expected SHA-256/HMAC API, backed internally by NuttX calls. `patch/0005-use-nuttx-sha256-hmac.patch` adjusts libtomcrypt's internal sha256_state/hmac_state struct layout so it matches NuttX's context size instead of libtomcrypt's own. ## Impact Dropbear application start to use NuttX crypto native. ( libs migration not finished yet, this is first step ). ./nuttx ## Testing Test done using Linux Ubuntu 22.04 using 2 terminals Use the config: `./tools/configure.sh sim:dropbear` Build and follow steps below to execute nuttx in the first terminal: `sudo setcap cap_net_admin+ep ./nuttx ./nuttx ` The expected output is: ``` nuttx git:(feature/crypto-chacha20-ocf) ./nuttx dropbear [6:100] NuttShell (NSH) NuttX-13.0.0-RC2 nsh> [6] Jun 01 00:00:00 using NuttX passwd auth at /tmp/passwd dropbear: listening on port 2222 ``` create a user and password to receive connection, use the example below: `nsh> useradd testuser testpass` In the second terminal `ssh -p 2222 -o StrictHostKeyChecking=no -c [email protected] [email protected]` After follow steps the remote connection will be available. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
