Closed ZoltanFridrich closed 5 months ago
Should we try to avoid integer overflow (wrap around this case) at multiplication? Maybe adding a check like
ULONG_MAX / length < sizeof (CK_ATTRIBUTE)
might help.
I think you meant ULONG_MAX / n_array < sizeof (CK_ATTRIBUTE)
. Thats a good idea. Fixed.
Return an error when
parsed_array_size < actual_array_size
rather then crashing with assert inproto_read_attribute_buffer_array
.