[Flask] Flask-Security authentication in JS

Christophe Bal projetmbc at gmail.com
Wed Sep 2 14:48:19 CEST 2015


Hello (sorry Corey Boyle).

Can you give a more concrete example of the thing you want to achieve ?


*Christophe BAL*
*Enseignant de mathématiques en Lycée **et développeur Python amateur*
*---*
*French math teacher in a "Lycée" **and **Python **amateur developer*

2015-09-02 14:10 GMT+02:00 Morgan Connolly <connollymorg at gmail.com>:

> I have a Flask app that uses Flask-Security for authentication, which is
> storing authentication details in cookies on the client side. Currently, it
> is a static app rendered using Jinja templates, but now I want to implement
> some features which require access to protected resources dynamically via
> JavaScript.
>
> If I send a request using JavaScript to a URL, the cookies won't be
> transmitted. If I want to transmit the username/password with each request,
> I will have to pass it to Jinja in cleartext.
>
> I'm at a total loss here, and I do not know what to do. Can somebody point
> me in the right direction?
>
> Cheers
>
> _______________________________________________
> Flask mailing list
> Flask at python.org
> https://mail.python.org/mailman/listinfo/flask
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/flask/attachments/20150902/c62e3fbf/attachment.html>


More information about the Flask mailing list