1
0
Fork 0
forked from lthn/blockchain

epee: portable_storage_base: implement array_entry_t copyctor (#25)

"Manually initialize the array_entry_t iterator to ensure it points
to the correct m_array, thereby preventing a potential use-after-free
situation."

Credit to Guido Vranken: https://hackerone.com/reports/511317
This commit is contained in:
0x914409F1 2019-05-19 01:09:31 +00:00 committed by cryptozoidberg
parent 4db26f48a5
commit 1c9ae19ec4

View file

@ -80,6 +80,7 @@ namespace epee
struct array_entry_t
{
array_entry_t():m_it(m_array.end()){}
array_entry_t(const array_entry_t& other):m_array(other.m_array), m_it(m_array.end()){}
const t_entry_type* get_first_val() const
{