commit | c8a7fa4a04aecb884f9dc5e88b714df9b715eb9e | [log] [tgz] |
---|---|---|
author | Adam Vartanian <flooey@google.com> | Fri Feb 23 14:34:25 2018 +0000 |
committer | Adam Vartanian <flooey@google.com> | Mon Feb 26 12:24:58 2018 +0000 |
tree | d6db32035fe9d548125e59d189a0cb6752964171 | |
parent | e729a2877c7f8d8aac573e185a98af93c2e8f745 [diff] |
Limit cert file reading to 10MiB. We read the entire cert file into memory when installing it, so reading without a limit will cause OutOfMemoryErrors if the file is sufficiently large. This is not a security problem (if someone can trick the user into installing new certificates, crashing the cert installer dialog is by far the least impactful thing they could do), but it's nice to not crash. Bug: 32320490 Test: manual testing Change-Id: Ib8dbfe06304481fd682297c680841705b8c4ad7c