LibWeb/CSP: Implement the webrtc directive

This commit is contained in:
Luke Wilde 2024-12-04 15:45:24 +00:00 committed by Alexander Kalenik
commit a5e2fd2e12
Notes: github-actions[bot] 2025-08-07 17:26:43 +00:00
5 changed files with 64 additions and 0 deletions

View file

@ -28,6 +28,7 @@
#include <LibWeb/ContentSecurityPolicy/Directives/StyleSourceAttributeDirective.h>
#include <LibWeb/ContentSecurityPolicy/Directives/StyleSourceDirective.h>
#include <LibWeb/ContentSecurityPolicy/Directives/StyleSourceElementDirective.h>
#include <LibWeb/ContentSecurityPolicy/Directives/WebRTCDirective.h>
#include <LibWeb/ContentSecurityPolicy/Directives/WorkerSourceDirective.h>
namespace Web::ContentSecurityPolicy::Directives {
@ -94,6 +95,9 @@ GC::Ref<Directive> create_directive(GC::Heap& heap, String name, Vector<String>
if (name == Names::StyleSrcElem)
return heap.allocate<StyleSourceElementDirective>(move(name), move(value));
if (name == Names::WebRTC)
return heap.allocate<WebRTCDirective>(move(name), move(value));
if (name == Names::WorkerSrc)
return heap.allocate<WorkerSourceDirective>(move(name), move(value));