diff options
author | Juraj Somorovsky <[email protected]> | 2016-09-20 14:27:46 +0200 |
---|---|---|
committer | Juraj Somorovsky <[email protected]> | 2016-09-30 00:56:54 +0200 |
commit | 024cf552377231d176099a893219c54158fab8f3 (patch) | |
tree | 04a005991b947270cc3eab4bbf6d1f7a67cea255 /src/lib/tls | |
parent | f1f6925ac1778d05eeffacff9c8ea4af59d69846 (diff) |
Vector out of bounds fix
Diffstat (limited to 'src/lib/tls')
-rw-r--r-- | src/lib/tls/msg_hello_verify.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/tls/msg_hello_verify.cpp b/src/lib/tls/msg_hello_verify.cpp index c1dc574d4..059d9d4fd 100644 --- a/src/lib/tls/msg_hello_verify.cpp +++ b/src/lib/tls/msg_hello_verify.cpp @@ -28,7 +28,7 @@ Hello_Verify_Request::Hello_Verify_Request(const std::vector<byte>& buf) if(static_cast<size_t>(buf[2]) + 3 != buf.size()) throw Decoding_Error("Bad length in hello verify request"); - m_cookie.assign(&buf[3], &buf[buf.size()]); + m_cookie.assign(buf.begin() + 3, buf.end()); } Hello_Verify_Request::Hello_Verify_Request(const std::vector<byte>& client_hello_bits, |