Skip to content
This repository has been archived by the owner on Oct 6, 2021. It is now read-only.

CSRF Array to String Error #208

Open
1 task
ParadiseStudios opened this issue Mar 29, 2019 · 0 comments
Open
1 task

CSRF Array to String Error #208

ParadiseStudios opened this issue Mar 29, 2019 · 0 comments

Comments

@ParadiseStudios
Copy link

ParadiseStudios commented Mar 29, 2019

  • Check this box if this is a security vulnerability.

Summary

CSRF token is to be inserted into <body> instead an error from Twig is displayed.

data-ajaxtoken="<br />
<b>Notice</b>:  Array to string conversion in <b>/home/www/csprng/vendor/twig/twig/lib/Twig/Environment.php(467) : eval()'d code</b> on line <b>57</b><br />Array"

You can fix it by using [0] but this isn't a good fix.
{% if ajax_csrf_token %} data-ajaxtoken="{{ ajax_csrf_token[0] }}"{% endif %}

You can see the error here: https://bridge.cspr.ng/board

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant