These are chat archives for nightscout/beta

Feb 2015
I took drywall, bolted this little snippet onto as middleware
the effect is roughly to say: "when user is logged in, send to proxy, otherwise handle here in our auth UI'
@jasoncalabrese ^^^ might be an easier way to deal with user auth issues
doing things this way might help pave way towards some kind of hosted version also
Ben West
Feb 21 2015 20:18
there are two problems with above attempt: the bodyParser middleware mucks with the proxy's ability to send the body to the proxy
and the csrf is detecting forgery on POST to proxy target
range of techniques to handle this
Ben West
Feb 21 2015 23:17
ok, it's actually not bodyParser
it's actually csrf token is getting mucked with somehow on POST
don't quite get it
but stripping out all the session stuff and using the raw proxy does work with the POST
it's only when running it with drywall's session management, something is invalidating the session
Ben West
Feb 21 2015 23:22
it definitely is working fairly easily to switch between: a.) logged in is allowed to use/see NS, b.) not logged in is forced to the login UI screens