| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights |
| 3 * reserved. | 3 * reserved. |
| 4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 4 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| 5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. | 5 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. |
| 6 * (http://www.torchmobile.com/) | 6 * (http://www.torchmobile.com/) |
| 7 * Copyright (C) 2008 Alp Toker <alp@atoker.com> | 7 * Copyright (C) 2008 Alp Toker <alp@atoker.com> |
| 8 * Copyright (C) Research In Motion Limited 2009. All rights reserved. | 8 * Copyright (C) Research In Motion Limited 2009. All rights reserved. |
| 9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> | 9 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> |
| 10 * Copyright (C) 2011 Google Inc. All rights reserved. | 10 * Copyright (C) 2011 Google Inc. All rights reserved. |
| (...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 610 ->parent() | 610 ->parent() |
| 611 ->securityContext() | 611 ->securityContext() |
| 612 ->getFeaturePolicy()); | 612 ->getFeaturePolicy()); |
| 613 const String& featurePolicyHeader = | 613 const String& featurePolicyHeader = |
| 614 m_documentLoader->response().httpHeaderField( | 614 m_documentLoader->response().httpHeaderField( |
| 615 HTTPNames::Feature_Policy); | 615 HTTPNames::Feature_Policy); |
| 616 Vector<String> messages; | 616 Vector<String> messages; |
| 617 const WebParsedFeaturePolicy& parsedHeader = parseFeaturePolicy( | 617 const WebParsedFeaturePolicy& parsedHeader = parseFeaturePolicy( |
| 618 featurePolicyHeader, m_frame->securityContext()->getSecurityOrigin(), | 618 featurePolicyHeader, m_frame->securityContext()->getSecurityOrigin(), |
| 619 &messages); | 619 &messages); |
| 620 m_frame->securityContext()->initializeFeaturePolicy(parsedHeader, | 620 const WebParsedFeaturePolicy& containerPolicy = |
| 621 parentFeaturePolicy); | 621 getContainerPolicyFromAllowedFeatures( |
| 622 m_frame->owner()->allowedFeatures(), |
| 623 m_frame->securityContext()->getSecurityOrigin()); |
| 624 |
| 625 m_frame->securityContext()->initializeFeaturePolicy( |
| 626 parsedHeader, containerPolicy, parentFeaturePolicy); |
| 622 for (auto& message : messages) { | 627 for (auto& message : messages) { |
| 623 m_frame->document()->addConsoleMessage(ConsoleMessage::create( | 628 m_frame->document()->addConsoleMessage(ConsoleMessage::create( |
| 624 OtherMessageSource, ErrorMessageLevel, | 629 OtherMessageSource, ErrorMessageLevel, |
| 625 "Error with Feature-Policy header: " + message)); | 630 "Error with Feature-Policy header: " + message)); |
| 626 } | 631 } |
| 627 if (!parsedHeader.isEmpty()) | 632 if (!parsedHeader.isEmpty()) |
| 628 client()->didSetFeaturePolicyHeader(parsedHeader); | 633 client()->didSetFeaturePolicyHeader(parsedHeader); |
| 629 } | 634 } |
| 630 } | 635 } |
| 631 | 636 |
| (...skipping 1374 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2006 frameLoadRequest.clientRedirect()); | 2011 frameLoadRequest.clientRedirect()); |
| 2007 | 2012 |
| 2008 loader->setLoadType(loadType); | 2013 loader->setLoadType(loadType); |
| 2009 loader->setNavigationType(navigationType); | 2014 loader->setNavigationType(navigationType); |
| 2010 loader->setReplacesCurrentHistoryItem(loadType == | 2015 loader->setReplacesCurrentHistoryItem(loadType == |
| 2011 FrameLoadTypeReplaceCurrentItem); | 2016 FrameLoadTypeReplaceCurrentItem); |
| 2012 return loader; | 2017 return loader; |
| 2013 } | 2018 } |
| 2014 | 2019 |
| 2015 } // namespace blink | 2020 } // namespace blink |
| OLD | NEW |