Fix handling of -offset and -length in asn1parse tool.
authorDr. Stephen Henson <steve@openssl.org>
Sun, 8 Feb 2004 13:31:06 +0000 (13:31 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Sun, 8 Feb 2004 13:31:06 +0000 (13:31 +0000)
commitfcc7c0a7bf8214f5338d0543d1ad4c992d5e9da1
treea6ffa67f727b220fcda9f37ed4e87e905961162a
parent0faa9d290f38dd487ef0de9beca16dddcd466083
Fix handling of -offset and -length in asn1parse tool.

If -offset exceeds -length of data available exit with an error.

Don't read past end of total data available when -offset supplied.

If -length exceeds total available truncate it.
apps/asn1pars.c