OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) | 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) |
4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) | 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) |
5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
rights reserved. | 5 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
rights reserved. |
6 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ | 6 Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ |
7 | 7 |
8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 ASSERT(RuntimeEnabledFeatures::xsltEnabled()); | 415 ASSERT(RuntimeEnabledFeatures::xsltEnabled()); |
416 case Resource::Script: | 416 case Resource::Script: |
417 case Resource::SVGDocument: | 417 case Resource::SVGDocument: |
418 case Resource::CSSStyleSheet: | 418 case Resource::CSSStyleSheet: |
419 case Resource::ImportResource: | 419 case Resource::ImportResource: |
420 // These resource can inject script into the current document (Scrip
t, | 420 // These resource can inject script into the current document (Scrip
t, |
421 // XSL) or exfiltrate the content of the current document (CSS). | 421 // XSL) or exfiltrate the content of the current document (CSS). |
422 treatment = TreatAsActiveContent; | 422 treatment = TreatAsActiveContent; |
423 break; | 423 break; |
424 | 424 |
| 425 case Resource::Font: |
| 426 // These resources are passive, but mixed usage is low enough that w
e |
| 427 // can block them in a mixed context. |
| 428 treatment = TreatAsActiveContent; |
| 429 break; |
| 430 |
425 case Resource::TextTrack: | 431 case Resource::TextTrack: |
426 case Resource::Raw: | 432 case Resource::Raw: |
427 case Resource::Image: | 433 case Resource::Image: |
428 case Resource::Font: | |
429 case Resource::Media: | 434 case Resource::Media: |
430 // These resources can corrupt only the frame's pixels. | 435 // These resources can corrupt only the frame's pixels. |
431 treatment = TreatAsPassiveContent; | 436 treatment = TreatAsPassiveContent; |
432 break; | 437 break; |
433 | 438 |
434 case Resource::MainResource: | 439 case Resource::MainResource: |
435 case Resource::LinkPrefetch: | 440 case Resource::LinkPrefetch: |
436 case Resource::LinkSubresource: | 441 case Resource::LinkSubresource: |
437 // These cannot affect the current document. | 442 // These cannot affect the current document. |
438 treatment = TreatAsAlwaysAllowedContent; | 443 treatment = TreatAsAlwaysAllowedContent; |
(...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1468 } | 1473 } |
1469 } | 1474 } |
1470 | 1475 |
1471 void ResourceFetcher::trace(Visitor* visitor) | 1476 void ResourceFetcher::trace(Visitor* visitor) |
1472 { | 1477 { |
1473 visitor->trace(m_document); | 1478 visitor->trace(m_document); |
1474 ResourceLoaderHost::trace(visitor); | 1479 ResourceLoaderHost::trace(visitor); |
1475 } | 1480 } |
1476 | 1481 |
1477 } | 1482 } |
OLD | NEW |