2022-07-12 20:42:19 +01:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								/*
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								 *  Copyright  ( c )  2022 ,  Linus  Groh  < linusg @ serenityos . org > 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								 * 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								 *  SPDX - License - Identifier :  BSD - 2 - Clause 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								 */ 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								# pragma once 
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2024-03-05 09:29:14 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								# include  <LibIPC/Forward.h> 
 
							 
						 
					
						
							
								
									
										
										
										
											2024-07-08 22:54:49 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								# include  <LibWeb/HTML/EmbedderPolicy.h> 
 
							 
						 
					
						
							
								
									
										
										
										
											2022-10-13 18:23:10 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								# include  <LibWeb/ReferrerPolicy/ReferrerPolicy.h> 
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
									
										
										
										
											2022-07-12 20:42:19 +01:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								namespace  Web : : HTML  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								// https://html.spec.whatwg.org/multipage/origin.html#policy-container
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								// A policy container is a struct containing policies that apply to a Document, a WorkerGlobalScope, or a WorkletGlobalScope. It has the following items:
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								struct  PolicyContainer  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // https://html.spec.whatwg.org/multipage/origin.html#policy-container-csp-list
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // FIXME: A CSP list, which is a CSP list. It is initially empty.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // https://html.spec.whatwg.org/multipage/origin.html#policy-container-embedder-policy
 
							 
						 
					
						
							
								
									
										
										
										
											2024-07-08 22:54:49 +01:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // An embedder policy, which is an embedder policy. It is initially a new embedder policy.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    EmbedderPolicy  embedder_policy  { } ; 
							 
						 
					
						
							
								
									
										
										
										
											2022-07-12 20:42:19 +01:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    // https://html.spec.whatwg.org/multipage/origin.html#policy-container-referrer-policy
 
							 
						 
					
						
							
								
									
										
										
										
											2022-10-13 18:23:10 +02:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								    // A referrer policy, which is a referrer policy. It is initially the default referrer policy.
 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								    ReferrerPolicy : : ReferrerPolicy  referrer_policy  {  ReferrerPolicy : : DEFAULT_REFERRER_POLICY  } ; 
							 
						 
					
						
							
								
									
										
										
										
											2022-07-12 20:42:19 +01:00 
										
									 
								 
							 
							
								
							 
							
								 
							 
							
							
								} ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								} 
							 
						 
					
						
							
								
									
										
										
										
											2024-03-05 09:29:14 -07:00 
										
									 
								 
							 
							
								
									
										 
									 
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								namespace  IPC  { 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								template < > 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								ErrorOr < void >  encode ( IPC : : Encoder & ,  Web : : HTML : : PolicyContainer  const & ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								template < > 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								ErrorOr < Web : : HTML : : PolicyContainer >  decode ( IPC : : Decoder & ) ; 
							 
						 
					
						
							
								
							 
							
								
							 
							
								 
							 
							
							
								}