Add nonce option for secure headers
This commit is contained in:
parent
c0c47cc83b
commit
065da9bc6e
@ -1,5 +1,9 @@
|
||||
<% if with_swf? %>
|
||||
<% if defined?(SecureHeaders) %>
|
||||
<script type="text/javascript" nonce="<%= content_security_policy_script_nonce %>">
|
||||
<% else %>
|
||||
<script type="text/javascript">
|
||||
<% end %>
|
||||
WEB_SOCKET_SWF_LOCATION = "/__rack/WebSocketMain.swf";
|
||||
<% if force_swf? %>
|
||||
WEB_SOCKET_FORCE_FLASH = true;
|
||||
@ -8,7 +12,11 @@
|
||||
<script type="text/javascript" src="<%= app_root %>/__rack/swfobject.js"></script>
|
||||
<script type="text/javascript" src="<%= app_root %>/__rack/web_socket.js"></script>
|
||||
<% end %>
|
||||
<% if defined?(SecureHeaders) %>
|
||||
<script type="text/javascript" nonce="<%= content_security_policy_script_nonce %>">
|
||||
<% else %>
|
||||
<script type="text/javascript">
|
||||
<% end %>
|
||||
RACK_LIVERELOAD_PORT = <%= @options[:live_reload_port] %>;
|
||||
</script>
|
||||
<script type="text/javascript" src="<%= livereload_source %>"></script>
|
||||
|
Loading…
Reference in New Issue
Block a user