ConservationMetrics / guardianconnector-views

A Nuxt.js tool that reads data from a SQL database and renders it on different views (map, gallery, alerts dashboard)
MIT License
3 stars 0 forks source link

Make it possible to set an authentication strategy (auth0, password, or none) #17

Closed rudokemper closed 6 months ago

rudokemper commented 6 months ago

Closes https://github.com/ConservationMetrics/guardianconnector-views/issues/15.

This PR is ironing out some past work to support different authentication methods: password with JWT, and auth0.

Instead of supporting one over the other wholesale, we are instead giving the administrator the option to define their authentication strategy: auth0, password, or none.

Depending on which strategy is chosen, the end user will have to log in via Auth0Login.vue, PasswordLogin.vue, or never have to log in (and be redirected away from the /login route if accessed) - respectively.

Authentication middleware has been adapted and streamlined in accordance to the requirements of the three strategies.