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

Sudo Mode Improvements #787

Closed
Sumukh opened this issue Aug 11, 2016 · 1 comment · Fixed by #808
Closed

Sudo Mode Improvements #787

Sumukh opened this issue Aug 11, 2016 · 1 comment · Fixed by #808
Labels

Comments

@Sumukh
Copy link
Member

Sumukh commented Aug 11, 2016

  1. Exiting sudo mode should take you back to your account.

Currently sudo actually replaces your current login - so when you are done you have logout and login again as an admin.

Logging out while in sudo mode should return you to the admin account you were in.

Ideally the login link text would indicate "Exit sudo mode", but that's not a must have.

Implementation wise this easy enough to add, but I want to make sure it's secure.

def logout():
  # logout behavior
  if session['sudo-user']: 
     login(User.get_by_email(session['sudo-user']))
     return redirect('admin.index') 
  return redirect('index') 
  1. sudo logins should be logged.

New Table? A generic event log might be useful.

  1. Use a form for entering sudo mode.

Not really required, but probably a better experience than having a secret URL.

@knrafto
Copy link
Contributor

knrafto commented Aug 15, 2016

We shouldn't have sudo mode at all: we'd be able to just use the admin interface to do whatever we need. I view sudo mode as a temporary workaround while we whip the admin interface into shape, so I wouldn't prioritize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants