diff options
author | ddrinan%netscape.com <devnull@localhost> | 2001-06-21 21:29:30 +0000 |
---|---|---|
committer | ddrinan%netscape.com <devnull@localhost> | 2001-06-21 21:29:30 +0000 |
commit | 794a0941a1119ef135b4e4d7b37f3e962f411faf (patch) | |
tree | b39b9016dfdc35e7f905ffb66107b3cff74b0692 | |
parent | 81aaa52d2ecaa5e43cc27878daa495feda878cdb (diff) | |
download | nss-hg-794a0941a1119ef135b4e4d7b37f3e962f411faf.tar.gz |
Bug 74343. Checkin for relyea. r=ddrinan,mcgreer,sr=blizzard,a=dbaron
-rw-r--r-- | security/nss/lib/certdb/pcertdb.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/security/nss/lib/certdb/pcertdb.c b/security/nss/lib/certdb/pcertdb.c index f4f6d3483..a43ed584a 100644 --- a/security/nss/lib/certdb/pcertdb.c +++ b/security/nss/lib/certdb/pcertdb.c @@ -873,8 +873,14 @@ DecodeDBCrlEntry(certDBEntryRevocation *entry, SECItem *dbentry) nnlen = ( ( dbentry->data[2] << 8 ) | dbentry->data[3] ); if ( ( entry->derCrl.len + nnlen + DB_CRL_ENTRY_HEADER_LEN ) != dbentry->len) { - PORT_SetError(SEC_ERROR_BAD_DATABASE); - goto loser; + /* CRL entry is greater than 64 K. Hack to make this continue to work */ + if (dbentry->len >= (0xffff - DB_CRL_ENTRY_HEADER_LEN) - nnlen) { + entry->derCrl.len = + (dbentry->len - DB_CRL_ENTRY_HEADER_LEN) - nnlen; + } else { + PORT_SetError(SEC_ERROR_BAD_DATABASE); + goto loser; + } } /* copy the dercert */ |