Commit Graph

197 Commits (700a01f6f0f357af25f4cfe2ba3d101ce673ef49)

Author SHA1 Message Date
dgarske 700a01f6f0 Merge pull request #33 from ejohnstown/release-v1.1.0
Update the configure script and readme for v1.1.0.
2017-06-15 08:25:54 -07:00
John Safranek afdbf2b7fe Update the configure script and readme for v1.1.0. 2017-06-15 08:08:20 -07:00
dgarske 770b90d0fd Merge pull request #32 from ejohnstown/unit-testing
Expanded Unit Testing
2017-06-14 18:08:48 -07:00
John Safranek 9c8a77c240 1. Add a separate API test.
2. Eliminate the unit.h file, included into api.c.
2017-06-14 09:10:35 -07:00
John Safranek 24b19daa16 1. Copied over some of the test infrastructure from wolfSSL.
2. Added API test cases for only wolfSSH_Init and wolfSSH_Cleanup.
2017-06-13 10:35:11 -07:00
John Safranek c3d0c895d2 add stub for the API test 2017-06-13 09:15:44 -07:00
John Safranek efeb9a41b2 rename directory test as tests 2017-06-13 09:05:57 -07:00
dgarske f3293dff87 Merge pull request #31 from ejohnstown/echoserver
Echoserver Enhancement
2017-06-12 16:41:15 -07:00
John Safranek 408ce5653d 1. Echoserver to catch Ctrl-E to provide session statistics.
2. Add wolfSSH_GetStats() to return session statistics.
3. Echoserver server_worker threads get a context with their
   wolfSSH session, an ID number, and socket fd.
2017-06-12 16:23:00 -07:00
John Safranek bcbf807fa0 Modify echoserver to have a stats key in addition to the
cancel session key.
2017-06-12 16:22:29 -07:00
dgarske ef1a92fe8b Merge pull request #30 from ejohnstown/gex
Add Group Exchange Support
2017-06-12 12:44:31 -07:00
John Safranek 26642bfa2c Remove the TEST_GEX build option. The DHGEX key agreement is the
first desired algo for the server.
2017-06-12 12:24:57 -07:00
John Safranek da126bfa48 Refactor the KEX init code to delay the start of calculating the KEX
hash until the KEXINIT from the client is received.
2017-06-12 12:24:57 -07:00
John Safranek 97e27cb7be DH-GEX
Filled out the message handling for the DH-GEX additional messages. To use
the DH-GEX, one needs to add the flag TEST_GEX. It is still a WIP. The
handshake state machine needs a change and the start of the hash calculation
needs to wait until receiving the client's KEX INIT message and the hash
type for the handshake signature can be resolved.
2017-06-12 12:24:57 -07:00
John Safranek 1a81d66f78 Framing in DH-GEX. 2017-06-12 12:24:57 -07:00
John Safranek 4319cb069c Unified Hashing
1. Added support for the wc_Hash wrappers. Need to keep track of the
   hash being used.
2. Assumed SHA1 only, and modified everything to use the hash wrappers.
2017-06-12 12:24:57 -07:00
John Safranek fcf0e5c55d SHA-256 Hash Support
1. Expanded GenerateKey() to obey the hash type.
2. Added cases for SHA-256 to the KDF test.
2017-06-12 12:24:57 -07:00
dgarske a35ed26e2c Merge pull request #29 from ejohnstown/client-rekey
Fix bug where client initiated rekeying failed
2017-06-12 12:14:12 -07:00
John Safranek 3cb286b600 Fix bug where client initiated rekeying failed. 2017-06-12 11:58:39 -07:00
dgarske 687d13a349 Merge pull request #28 from ejohnstown/string-clean
Update a few debugging strings were copied and pasted.
2017-06-12 11:17:38 -07:00
dgarske 7eb1dad6ef Merge pull request #27 from ejohnstown/fix-getstring
Fix GetString
2017-06-12 11:17:17 -07:00
dgarske a0d40e0cd1 Merge pull request #26 from ejohnstown/banner-config
Update the banner
2017-06-12 11:16:11 -07:00
dgarske 5ae31ea0c7 Merge pull request #25 from ejohnstown/global-request
Global Request Message
2017-06-12 11:15:11 -07:00
John Safranek 95a435055f Update a few debugging strings were copied and pasted. 2017-06-12 10:17:54 -07:00
John Safranek 711a52e4ce Adding the macOS DS_Store filename to the gitignore. 2017-05-30 16:16:16 -07:00
John Safranek ff14fbaef8 In GetString() added a check for the size of the destination buffer. 2017-05-30 14:38:15 -07:00
John Safranek a4285571f4 Update the banner
1. Add the banner to the WOLFSSH_CTX.
2. Moved the canned banner to be a debug option.
3. Default the banner to NULL of zero length.
4. Use the banner stored in the WOLFSSH_CTX.
5. Add an accessor to set the banner to a C string.
2017-05-30 14:25:41 -07:00
John Safranek 3d79d4ffa3 Global Request Message
1. Added parsing of the Global Request message. Will log the request
   name string.
2. Send global request failure response if reply is requested.
(This was an issue with a particular SSH client.)
2016-11-11 12:00:22 -08:00
toddouska 87eb3ad26d Merge pull request #24 from ejohnstown/chan-success
Channel Success Message
2016-10-25 14:45:45 -07:00
John Safranek c2480eb46c Add function to send Channel Success and Failure to the client when
receiving Channel Request messages, when requested.
2016-10-25 14:14:05 -07:00
toddouska ad80b4b613 Merge pull request #23 from ejohnstown/wc-fix
wolfCrypt Fix
2016-10-25 12:19:30 -07:00
John Safranek 6af24baf38 Fixed a missed set of wolfCrypt functions whose return values weren't getting checked. 2016-10-24 15:24:04 -07:00
toddouska a612d6cafe Merge pull request #22 from ejohnstown/rekeying
Rekeying
2016-10-24 15:19:05 -07:00
John Safranek 4ff6a525b6 Update README with the change of name of the keys directory. 2016-10-24 15:10:22 -07:00
John Safranek b76f376381 scan-build fix. clear a whole buffer before filling it before checking
with ConstantCompare().
2016-10-24 15:08:58 -07:00
John Safranek c802b331bd Check all return codes on wolfCrypt functions. 2016-10-24 15:03:54 -07:00
John Safranek c183000b93 1. Manage case where Client KEX Init arrives in same recv() as the
client version string.
2. Shrink the receive buffer after reading the client version
   string.
3. Resize the buffer correctly when needed data is already in the input
   buffer and grab the remainder as expected.
2016-10-24 13:42:58 -07:00
John Safranek 718a4f4b40 cleanup accept state machine 2016-10-24 11:51:42 -07:00
John Safranek ccc1101612 Fix where the result of sending a channel close was getting replaced
with success.
2016-10-23 16:14:17 -07:00
John Safranek 184182d152 Prep for v1.0.0
1. Bump version number.
2. Update readme.
3. Move the coding standard to a notes file.
2016-10-23 16:06:08 -07:00
John Safranek bc9eff91d6 1. Rename function ProcessReply(), conflicts when linking against
wolfSSL not using cryptonly mode.
2. Send server version before expecting client version.
2016-10-23 15:43:08 -07:00
John Safranek 5b07c8cb1d 1. Parse the Channel EOF message.
2. Parse the Channel Close message, and reply with a Channel Close.
2016-10-23 14:46:34 -07:00
John Safranek 184b2218d4 Rekeying Update
1. Add the Trigger Rekeying function.
2. Fixing the keying state machine.
3. Modify echoserver for rekeying.
2016-10-21 13:40:35 -07:00
John Safranek 41ec11e6ab Rekeying Update
1. Flushing out the keying state machine, taking it out of the accept
   state machine.
2. Changed the HandshakeInfo record to be something that can be
   recreated post-initial connection for rekeying.
3. Fixed the name of a previously unused size variable.
4. Moved some constants around.
2016-10-16 20:25:24 -07:00
John Safranek c564550999 Automatic Session Rekeying
1. Add stub rekey trigger function.
2. Add new default highwater callback that calls the rekey trigger
   function.
3. Rename the highwater level as "mark" rather than "count".
4. Add a flag to call the highwater callback once, cleared when the
   txCount is cleared when sending new keys message to peer.
5. Add new state machine for key exchange.
6. Start massaging the accept state machine for new KEX machine.
7. Update some default sizes, and replace magic numbers with named
   constants.
8. Scale back the accept state machine to add in the KEX state
   machine.
9. Capture the client version string and the server's KEX init message
   for rekeying.
10. Add compiler flag to allow "none" as a user auth method.
2016-10-16 15:16:24 -07:00
John Safranek b3ee5cd381 Send channel window adjust update when the receive buffer
has processed at least half of its available space. By
default, the receive window is 1MB, and the window size is
increased every 512kB.
2016-10-16 12:11:50 -07:00
John Safranek 919ed1f944 Optionally compile keygen.c. 2016-10-14 13:16:07 -07:00
John Safranek b6cda842e8 add function to notify peer of window size adjustment 2016-10-14 12:45:09 -07:00
John Safranek a69b7fba26 More Tweaks
1. Made default window size updatable at configure time.
2. Lowered the default highwater mark by 32k.
3. Removed a parameter name from a couple function protypes.
2016-10-14 12:45:09 -07:00
John Safranek d9808cec31 tweak the peerWindowSz updating and logging 2016-10-14 12:45:09 -07:00