mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 04:39:06 +00:00
LibWeb/CSP: Implement the frame-src directive
This commit is contained in:
parent
e899438907
commit
1689353beb
Notes:
github-actions[bot]
2025-07-05 09:23:00 +00:00
Author: https://github.com/Lubrsi
Commit: 1689353beb
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5276
Reviewed-by: https://github.com/shannonbooth ✅
5 changed files with 95 additions and 0 deletions
|
@ -9,6 +9,7 @@
|
|||
#include <LibWeb/ContentSecurityPolicy/Directives/Directive.h>
|
||||
#include <LibWeb/ContentSecurityPolicy/Directives/DirectiveFactory.h>
|
||||
#include <LibWeb/ContentSecurityPolicy/Directives/FontSourceDirective.h>
|
||||
#include <LibWeb/ContentSecurityPolicy/Directives/FrameSourceDirective.h>
|
||||
#include <LibWeb/ContentSecurityPolicy/Directives/Names.h>
|
||||
|
||||
namespace Web::ContentSecurityPolicy::Directives {
|
||||
|
@ -21,6 +22,9 @@ GC::Ref<Directive> create_directive(GC::Heap& heap, String name, Vector<String>
|
|||
if (name == Names::FontSrc)
|
||||
return heap.allocate<FontSourceDirective>(move(name), move(value));
|
||||
|
||||
if (name == Names::FrameSrc)
|
||||
return heap.allocate<FrameSourceDirective>(move(name), move(value));
|
||||
|
||||
return heap.allocate<Directive>(move(name), move(value));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue