Security: UAF in CFFL_InteractiveFormFiller::OnBeforeKeyStroke
Reported by
manhluat...@gmail.com,
Sep 14 2017
|
|||||||||||||||||||||
Issue descriptionNotice: this PoC works on stable chrome (XFA disabled) To repro, open pdf file on Chromium ASAN then click anywhere on page 0. It even crash on Stable Chrome (MacOS) since I'm using gc(); https://cs.chromium.org/chromium/src/third_party/pdfium/fpdfsdk/formfiller/cffl_interactiveformfiller.cpp?q=CFFL_InteractiveFormFiller::OnBeforeKeyStroke&sq=package:chromium&l=909 std::pair<bool, bool> CFFL_InteractiveFormFiller::OnBeforeKeyStroke( [...] CPDFSDK_Annot::ObservedPtr pObserved(pData->pWidget); if (!pData->pWidget->OnAAction(CPDF_AAction::KeyStroke, fa, pData->pPageView)) { <---- run JS script here if (!IsValidAnnot(pData->pPageView, pData->pWidget)) bExit = true; return {bRC, bExit}; } if (!pObserved || !IsValidAnnot(pData->pPageView, pData->pWidget)) return {bRC, true}; if (nAge != pData->pWidget->GetAppearanceAge()) { CPWL_Wnd* pWnd = pFormFiller->ResetPDFWindow( pData->pPageView, nValueAge == pData->pWidget->GetValueAge()); pData = reinterpret_cast<CFFL_PrivateData*>(pWnd->GetAttachedData()); bExit = true; } [...] Root cause: We can run JS script at 909th line, we can destroy this widget's pdf window, later it uses |pData| (which is element in PDFWindow class |CPWL_Listbox|) UAF occurs. To destroy pdf window: I killfocus on this annot, then setfocus again (with m_Age has been changed), it will invoke |ResetPDFWindow| afterwards.
,
Sep 14 2017
Thanks for the report, I can reproduce the crash. Chrome doesn't have a builtin way of recording windows, but your PoC video is very clear. Tom: Can you please take a look? Thanks.
,
Sep 14 2017
,
Sep 14 2017
,
Sep 15 2017
,
Sep 15 2017
,
Sep 15 2017
,
Sep 16 2017
,
Sep 18 2017
,
Sep 18 2017
This bug requires manual review: M62 has already been promoted to the beta branch, so this requires manual review Please contact the milestone owner if you have questions. Owners: amineer@(Android), cmasso@(iOS), bhthompson@(ChromeOS), abdulsyed@(Desktop) For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 18 2017
+awhalley@ I'm approving merge to M62. Branch:3202
,
Sep 18 2017
,
Sep 22 2017
*** Boilerplate reminders! *** Please do NOT publicly disclose details until a fix has been released to all our users. Early public disclosure may cancel the provisional reward. Also, please be considerate about disclosure when the bug affects a core library that may be used by other products. Please do NOT share this information with third parties who are not directly involved in fixing the bug. Doing so may cancel the provisional reward. Please be honest if you have already disclosed anything publicly or to third parties. Lastly, we understand that some of you are not interested in money. We offer the option to donate your reward to an eligible charity. If you prefer this option, let us know and we will also match your donation - subject to our discretion. Any rewards that are unclaimed after 12 months will be donated to a charity of our choosing. *********************************
,
Sep 22 2017
Nice one! The VRP panel decided to award $3,000 for this report!
,
Sep 22 2017
,
Sep 22 2017
This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible! If all merges have been completed, please remove any remaining Merge-Approved labels from this issue. Thanks for your time! To disable nags, add the Disable-Nags label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 25 2017
This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible! If all merges have been completed, please remove any remaining Merge-Approved labels from this issue. Thanks for your time! To disable nags, add the Disable-Nags label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Sep 29 2017
Reminder to please merge to M62 branch 3202.
,
Sep 29 2017
Will merge.
,
Sep 29 2017
https://pdfium.googlesource.com/pdfium/+/effa1b15ae2ab34ae15892787d5c1caa015bd2d4
,
Oct 16 2017
,
Oct 16 2017
,
Oct 18 2017
,
Dec 23 2017
This bug has been closed for more than 14 weeks. Removing security view restrictions. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jan 4 2018
The following revision refers to this bug: https://pdfium.googlesource.com/pdfium/+/df0a749452d933e4f434e2a33112667f1880db34 commit df0a749452d933e4f434e2a33112667f1880db34 Author: Dan Sinclair <dsinclair@chromium.org> Date: Thu Jan 04 20:19:21 2018 Remove allocations from JS test This CL removes the millions of allocations from the test case for bug 765384. This takes the test execution from ~20s to ~400ms when run in Debug. Bug: chromium:765384 Change-Id: Ib1e9d3c6fb9853e541189e1a16f765d05202cdcc Reviewed-on: https://pdfium-review.googlesource.com/22011 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org> [modify] https://crrev.com/df0a749452d933e4f434e2a33112667f1880db34/testing/resources/bug_765384.in [modify] https://crrev.com/df0a749452d933e4f434e2a33112667f1880db34/testing/resources/bug_765384.pdf
,
Mar 27 2018
,
Apr 25 2018
|
|||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||
Comment 1 by manhluat...@gmail.com
, Sep 14 2017