1. client.c: It was warning a recommendation to tag the function
`readInput()` as non-return. Changed the err_sys() calls to
`fprintf(stderr, ...)` and then return from the function.
2. internal.c: In functions `DoKexInit()` and
`DoUserAuthRequestPublicKey()`, initialized a couple variables that
could be used uninitialized.
3. wolfsftp.c: Fixed a variable that was shadowing a global label.
4. wolfsftp.c: In function `wolfSSH_SFTP_RecvFSTAT()`, initialized a
variable that could be used uninitialized.
5. scpclient.c: The command line argument was read into a char value
assuming it was signed, which is usually true. On the PowerPC this
value is unsigned. Promoted it to int to match the other tools.
1. All the sources for the tests and examples did not have an include
for config.h. This fixed some inconsistent builds with an older
version of gcc.
2. Moved config.h from the src directory to the top level of the repo
directory.
1. Fixed a leak from a commit earlier in this branch.
2. Freed the correct address name when a forwarded connection closes.
3. Only muck about with the childFd when using the shell.
4. Treat the error code WS_CHANNEL_CLOSED as status, not a failure.
1. Moved SendKexDhReply()'s signature data to the heap. (413)
2. Moved SendUserAuthRequest()'s signature data to the heap. (414)
3. Moved DoKexDhReply()'s signature data to the heap. (415)
4. Moved DoUserAuthRequestRsa()'s RSA key to the heap. (416)
5. Moved wolfSSH_ProcessBuffer()'s key buffer to the heap. (422)
6. Moved wolfSSH_ReadKey_buffer()'s key bugger to the heap. (423)
7. In the echoserver, fixed a small-stack related allocation. It was
using a DYNTYPE constant, but those aren't visible. Also, the
wrong variable name was getting freed. (rebase)
1. For the client agent command line option, add the flag to the flag string.
2. Update PostSignRequest() to support all flavors of ECDSA and to
switch out code for missing algorithms.
3. Hide function SendRequestIdentities().
1. Remove calls to wc_Sha256 Init, Update, and Final and remove the
instances of the wc_Sha256 structure.
2. Remove the c32toa function, it isn't used at this point.
3. Add calls to wc_Sha256Hash().
This removes the Sha256 structure off the stack and replaces it with the
direct call to the single-shot hash routine. Flattening the size of the
hashed data and hashing it in was removed as redundant.
1. If RSA is disabled in the wolfCrypt build, the RSA related code
in wolfSSH shall be disabled.
2. Examples will force themselves to use ECC if RSA is disabled.
1. A couple places weren't passing the correct heap pointer to free.
Normally this was ignored in the build because the WMALLOC macro left
them out. Found using wolfCrypt memory logging.
2. Replaced the call to strdup() with wstrdup() that takes a heap and
type parameter so sit may allocate a buffer with WMALLOC() and be
freed correctly by WFREE().
3. Tweaked the client to use a preallocated buffer for the private key
rather than letting ReadKey allocate one. (Another WFREE() heap/type
issue.)