Преглед на файлове

Fix #457 - escape JSON in INITIAL_STATE (this bug only ever allowed a user to xss themselves rather than anyone else)

master
Eugen Rochko преди 7 години
родител
ревизия
4a2ee43e80
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. +1
    -1
      app/views/home/index.html.haml

+ 1
- 1
app/views/home/index.html.haml Целия файл

@@ -1,6 +1,6 @@
- content_for :header_tags do
:javascript
window.INITIAL_STATE = #{render(file: 'home/initial_state', formats: :json)}
window.INITIAL_STATE = #{json_escape(render(file: 'home/initial_state', formats: :json))}

= javascript_include_tag 'application'



Зареждане…
Отказ
Запис