1. 03 11月, 2016 2 次提交
    • M
      Fail if an unrecognised record type is received · 436a2a01
      Matt Caswell 提交于
      TLS1.0 and TLS1.1 say you SHOULD ignore unrecognised record types, but
      TLS 1.2 says you MUST send an unexpected message alert. We swap to the
      TLS 1.2 behaviour for all protocol versions to prevent issues where no
      progress is being made and the peer continually sends unrecognised record
      types, using up resources processing them.
      
      Issue reported by 郭志攀
      Reviewed-by: NTim Hudson <tjh@openssl.org>
      436a2a01
    • M
      Fix read_ahead · a7faa6da
      Matt Caswell 提交于
      The function ssl3_read_n() takes a parameter |clearold| which, if set,
      causes any old data in the read buffer to be forgotten, and any unread data
      to be moved to the start of the buffer. This is supposed to happen when we
      first read the record header.
      
      However, the data move was only taking place if there was not already
      sufficient data in the buffer to satisfy the request. If read_ahead is set
      then the record header could be in the buffer already from when we read the
      preceding record. So with read_ahead we can get into a situation where even
      though |clearold| is set, the data does not get moved to the start of the
      read buffer when we read the record header. This means there is insufficient
      room in the read buffer to consume the rest of the record body, resulting in
      an internal error.
      
      This commit moves the |clearold| processing to earlier in ssl3_read_n()
      to ensure that it always takes place.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      a7faa6da
  2. 02 11月, 2016 5 次提交
  3. 28 10月, 2016 5 次提交
  4. 18 10月, 2016 2 次提交
    • D
      Add SSL_OP_NO_ENCRYPT_THEN_MAC · cde6145b
      David Woodhouse 提交于
      Reviewed-by: NTim Hudson <tjh@openssl.org>
      Reviewed-by: NMatt Caswell <matt@openssl.org>
      cde6145b
    • D
      Fix encrypt-then-mac implementation for DTLS · e23d5071
      David Woodhouse 提交于
      OpenSSL 1.1.0 will negotiate EtM on DTLS but will then not actually *do* it.
      
      If we use DTLSv1.2 that will hopefully be harmless since we'll tend to use
      an AEAD ciphersuite anyway. But if we're using DTLSv1, then we certainly
      will end up using CBC, so EtM is relevant — and we fail to interoperate with
      anything that implements EtM correctly.
      
      Fixing it in HEAD and 1.1.0c will mean that 1.1.0[ab] are incompatible with
      1.1.0c+... for the limited case of non-AEAD ciphers, where they're *already*
      incompatible with other implementations due to this bug anyway. That seems
      reasonable enough, so let's do it. The only alternative is just to turn it
      off for ever... which *still* leaves 1.0.0[ab] failing to communicate with
      non-OpenSSL implementations anyway.
      
      Tested against itself as well as against GnuTLS both with and without EtM.
      Reviewed-by: NTim Hudson <tjh@openssl.org>
      Reviewed-by: NMatt Caswell <matt@openssl.org>
      e23d5071
  5. 11 10月, 2016 1 次提交
    • D
      Remove trailing whitespace from some files. · 609b0852
      David Benjamin 提交于
      The prevailing style seems to not have trailing whitespace, but a few
      lines do. This is mostly in the perlasm files, but a few C files got
      them after the reformat. This is the result of:
      
        find . -name '*.pl' | xargs sed -E -i '' -e 's/( |'$'\t'')*$//'
        find . -name '*.c' | xargs sed -E -i '' -e 's/( |'$'\t'')*$//'
        find . -name '*.h' | xargs sed -E -i '' -e 's/( |'$'\t'')*$//'
      
      Then bn_prime.h was excluded since this is a generated file.
      
      Note mkerr.pl has some changes in a heredoc for some help output, but
      other lines there lack trailing whitespace too.
      Reviewed-by: NKurt Roeckx <kurt@openssl.org>
      Reviewed-by: NMatt Caswell <matt@openssl.org>
      609b0852
  6. 03 10月, 2016 10 次提交
  7. 02 10月, 2016 1 次提交
  8. 30 9月, 2016 5 次提交
  9. 29 9月, 2016 9 次提交