Abhishekmishra2808 commented on PR #19209:
URL: https://github.com/apache/nuttx/pull/19209#issuecomment-5011423452

   @FelipeMdeO, while testing sim:dropbear with nuttx PR #19209 and nuttx-apps 
PR #3557 (after the defconfig/crypto fixes), I ran into a separate issue that 
looks unrelated to the PBKDF2/passwd changes. Reporting it here in case it 
helps.
   
   SSH login succeeds and the client shows nsh>, but keyboard input does not 
work (commands are not accepted).
   
   Logs (sim)
   ```
   nsh> useradd admin 'Dropbear1!'
   nsh> [6] Jun 01 00:01:27 connection from 10.255.255.254:44222
   [6] Jun 01 00:01:29 Password auth succeeded for 'admin' from 
10.255.255.254:44222
   [6] Jun 01 00:01:29 NSH PTY session started
   [6] Jun 01 00:01:29 NSH session wait failed: Unknown error 10
   (Unknown error 10 is ECHILD on NuttX.)
   ```
   
   What seems to be happening
   From `netutils/dropbear/dropbear_nshsession.c:`
   
   NSH is started with `task_spawn()` from the dropbear task.
   A pthread waiter calls `waitpid(sess->nsh_pid, ...).`
   On NuttX, `waitpid()` appears to return ECHILD immediately (waiter thread is 
not the spawning parent).
   On failure, the code still sets `sess->done = true`, which makes 
`dropbear_sesscheckclose()` treat the SSH channel as closed. So the session 
stops accepting input even though the nsh> prompt was already sent.
   
   PTAL !! When you have a chance. :-)


-- 
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]

Reply via email to