Limit reads in do_b2i_bio()
authorDr. Stephen Henson <steve@openssl.org>
Mon, 15 Aug 2016 15:52:21 +0000 (16:52 +0100)
committerDr. Stephen Henson <steve@openssl.org>
Mon, 15 Aug 2016 23:28:16 +0000 (00:28 +0100)
commitb552f32dcb9826c7d08980bc1acf52aa52abb8a1
tree91d0fcb25273a3836b16a25f57c723af5f3a2126
parente36f27ddb80a48e579783bc29fb3758988342b71
Limit reads in do_b2i_bio()

Apply a limit to the maximum blob length which can be read in do_d2i_bio()
to avoid excessive allocation.

Thanks to Shi Lei for reporting this.

Reviewed-by: Rich Salz <rsalz@openssl.org>
(cherry picked from commit 66bcba145740e4f1210499ba6e5033035a2a4647)
crypto/pem/pvkfmt.c