Commit Graph

21 Commits (bac12d8a5e61b8bdb6fb73f6f9104b9760a92060)

Author SHA1 Message Date
John Safranek 62f309c8ae
Merge pull request #170 from kojo1/GlobalReq
Global request
2019-06-18 10:18:46 -07:00
John Safranek 56616d3416 Public key authentication
1. Cleanup some debug printouts.
2. Add option to the echoserver and wolfSFTP client to use ECC keys or RSA
keys for user authentication.
3. Add option to the echoserver to use ECC keys for peer authentication.

Note, the user authentication type is still hardcoded in the library as
password. To use public key, need to update the authId in
SendUserAuthFailure().
2019-06-06 11:59:35 -07:00
John Safranek d755132ccf Public key authentication
1. Refactor of the RSA public key and password user auth code.
2. In the userauth code remove some usused variable names or use some orphaned variables.
3. Fix the sizes used for calculating the buffer size for ECC public keys.
4. Add in the length of the ECDSA signature wrapping the set r,s.
5. Return the public key rejected error code from DoUserAuthRequestPublicKey when the callback returns invalid public key.
2019-06-06 10:37:22 -07:00
Takashi Kojo faa9764753 add Global Request callback 2019-06-06 07:10:44 +09:00
Takashi Kojo 86cbb26868 Add send Global Request 2019-06-06 07:10:44 +09:00
John Safranek 150ad93a07 Memory Refactor
1. Add functions to print out the sizes of various structures.
2019-05-09 09:37:29 -07:00
Jacob Barthelmeh 9f66a16ed5 add wc_ecc_fp_free to test treads for ecc caching 2019-04-09 15:46:11 -06:00
John Safranek 9aaebbb146 Update the copyright to 2019 2019-04-08 10:24:08 -07:00
Jacob Barthelmeh 9df6e300f8 do not exit on want read with console parsing 2019-04-01 13:16:59 -06:00
Jacob Barthelmeh ff84dea8a0 add function to get extended data and example remote command execute
update client example remote command execute for Windows

add wolfSSH_stream_peek and console translation

improvements to console translation and add client side psuedo terminal

windows client -c fix, clang build, sanity check on side for exec

fix for warnings with VS 2010 build

cast return value of WSTRLEN

update termios guard and fix for scan-build check

advance extended data buffer index on read

fix for error.h after rebase
2019-03-29 09:25:27 -06:00
John Safranek 8a267e2bd2 Public Key Check Callback
The public key check callback hook is given a pointer to the public key, the size of the key, and the application-specific context data.
1. Added a callback function hook for checking the public key sent to the client by the server. It defaults to accepting the key.
2. Added accessors for the public key check callback function and context data.
3. Added a dummy callback to all the example tools.
2019-03-26 13:51:35 -07:00
John Safranek 2350ffe00e Review Fixes
1. Add a wrapper to the key-gen code that checks for wolfCrypt's keygen flag and errors if keygen isn't available.
2. The main loops around wolfSSH_stream_read() for the example client and server needed to check the error register for WANT_READ or WANT_WRITE, not the return code.
2019-02-27 11:28:24 -08:00
John Safranek 7e9981c6ec Updated the main API, echoserver, client, and server for the NO_WOLFSSH_SERVER and NO_WOLFSSH_CLIENT options. 2019-01-09 14:25:50 -08:00
Jacob Barthelmeh fc92e85853 use int type for getting example args 2018-12-11 17:01:56 -07:00
John Safranek d2a1c2ab1b Non-blocking fix
1. Added a non-blocking socket option to the client.
2. Added a non-blocking socket option to the server.
3. Added support for select to the test header.
4. Updated the usage strings so they are formatted the same.
2018-11-21 11:38:33 -08:00
John Safranek b97b237695 Static Analysis Fixes
Ran the clang static analysis and infer and fixed most of the reported
items. There were many that infer found that looked like false
positives.
2018-11-15 13:28:42 -08:00
John Safranek cf959db741 Grouping test header functions into test-client, test-server, or
test-threading blocks. Adding flags to the examples and testsuite to
enable various test functions.
2018-09-20 16:10:13 -07:00
Jacob Barthelmeh 73bcd5c95a external test script 2018-07-02 17:07:51 -06:00
Jacob Barthelmeh bb668fe743 use of buffer keys in examples with no filesystem 2018-03-30 10:45:24 -06:00
John Safranek 16b4a31cfb Test Suite
1. Add an automated test suite.
2. Refactor the existing test and example code to be better components for the test suite.
3. Rename some of the internal functions used by the examples and test suite.
4. Echoserver now only handles one connection at a time, has option to exit after single connection.
5. Echoserver can do the port zero trick for the test suite.
6. Some whitespace changes.
7. Added a `(void)` to a variable to hush an unused assignment warning.
2017-09-29 13:48:40 -07:00
John Safranek 65fb16ddc4 Client
1. Added support to the library for clients.
2. Added example client.
3. Added VS solutions for building client example.
4. Added ECC client keys. Renamed existing keys.
5. Since defunct server is copy of echoserver, updated it.
2017-09-25 14:45:03 -07:00