Vincent Hanquez
c252ed8f49
cleanup record layer
2013-07-27 08:32:27 +01:00
Vincent Hanquez
e2d5170af7
Separate tx/rx state from a single RecordState
...
unroll a reader/state/error monad into a single simple monad,
and move back version and client context in state.
2013-07-25 21:53:32 +01:00
Vincent Hanquez
e3b3483560
move random gen back into state
2013-07-24 17:35:57 +01:00
Vincent Hanquez
4a9389c5c2
remove the need to pass the RNG in record engage.
2013-07-24 07:19:13 +00:00
Vincent Hanquez
bcc53155f1
create pure function with explicit parameter for computeDigest
2013-07-24 06:41:31 +00:00
Vincent Hanquez
0e11f63033
move pending cipher and compression in the handshake state
...
adjust code to cope
2013-07-22 07:35:53 +00:00
Vincent Hanquez
5ca744a8bf
move to a proper role type for client|server
2013-07-21 10:16:01 +01:00
Vincent Hanquez
dd30cc05b0
remove commented code.
2013-07-21 09:35:44 +01:00
Vincent Hanquez
199de057c3
separate more handshake state from other state.
...
reorganize pending state in record state.
2013-07-20 08:21:52 +01:00
Vincent Hanquez
590cd35e4e
add signatures
2013-07-19 07:05:31 +01:00
Vincent Hanquez
660f15f616
better separate tx/rx into transmission state objects
2013-07-19 06:45:02 +01:00
Vincent Hanquez
c498b95512
reorder fields
2013-07-18 07:53:57 +01:00
Vincent Hanquez
f231253d6f
rename CryptState and MACState
2013-07-18 07:32:08 +01:00
Vincent Hanquez
8f99c325fb
separate tx/rx compression and pending compression.
...
Fix issue with compression being turn on for tx and rx at the same time,
and also at too early at the hello message instead of change cipher.
2013-07-18 07:18:38 +01:00
Vincent Hanquez
78535ff8c3
set MacState as a newtype
2013-07-13 09:11:03 +01:00
Vincent Hanquez
4f66742d8b
more too much flexibility
2013-07-13 08:37:37 +01:00
Vincent Hanquez
4e86ffee28
split record state from state.
2013-07-13 08:03:25 +01:00
Vincent Hanquez
c132b4cb8b
first stab at separating record state from other state.
2013-07-11 09:03:33 +01:00
Vincent Hanquez
b025e616e4
re-indent record layer
2013-07-10 08:48:49 +00:00
Vincent Hanquez
83c1e247e6
add extra check for minimum size and being a blocksize multiple for block ciphers.
2013-02-09 16:57:22 +00:00
Vincent Hanquez
66cf59c054
remove BulkNoneF which only duplicate case for no reason.
2013-02-09 16:56:47 +00:00
Vincent Hanquez
339d2ca33a
reorganize the disengage decryptData function for further change.
2013-02-09 08:10:13 +00:00
Vincent Hanquez
3e82cc744a
fix issue when re-handshaking with a different cipher.
...
tls was correctly accounting for the difference between pending state
and active state in most place except for the actual cipher
encryption/decryption functions in use.
Hence when re-negociating with a different cipher than the current
cipher, which is fairly unusual but perfectly allowed, the lowlevel
function were switch at the server hello instead of being switch at the
switch(Tx/Rx).
2012-11-19 09:39:35 +00:00
Vincent Hanquez
957a005664
move all tls into a core directory.
2012-09-05 06:27:06 +01:00