Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent login-restricted pages from being accessed by non-logged in users #91

Open
jmmabanta opened this issue Jun 15, 2022 · 0 comments
Labels
bug Something isn't working low priority Nice to have functionality

Comments

@jmmabanta
Copy link
Contributor

Bug Description

Pages like flightschedule, automatedcommandsequence, livecommands, and logs are still accessible without login by going directly to their URL. Though this is not really a security issue as their API calls require an authentication token, they become unresponsive when a user accidentally visits these pages without being logged in.

To Reproduce

Steps to reproduce the behaviour:

  1. Logout of any account
  2. Go to http://localhost:8000/flightschedule or http://localhost:8000/livecommands, etc.
  3. Interacting with the page (eg: send a command, submit a flight schedule, etc.)
  4. Website shows no indication of why it isn't working but the Network tab in DevTools indicates that an authentication token is needed

Expected Behaviour

When these pages are visited without a valid login, it should instead redirect back to the homepage and alert the user that they aren't login (the alert can be done with a Snackbar + Alert component from MaterialUI to keep design consistent).

@jmmabanta jmmabanta added bug Something isn't working low priority Nice to have functionality labels Jun 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working low priority Nice to have functionality
Projects
None yet
Development

No branches or pull requests

1 participant