ComputerScienceHouse / packet

Web packet written in Python for Computer Science House
MIT License
23 stars 26 forks source link

Redirect to the configured host before OIDC if incorrect #346

Closed galenguyer closed 2 years ago

galenguyer commented 2 years ago

If people go to freshman-packet.csh, SSO redirects them to freshmen-packet.csh, as it should, but this means Flask isn't aware of the previous session, leading to a lot of {"error": "unsolicited_response", "error_description": "No initialised user session."}`. This checks that we're on the configured host before the request proceeds, and redirects to the configured host if we're not.