Page MenuHomePhabricator

Investigate whether admin privileges on Jupyter are correct
Closed, ResolvedPublic1 Estimated Story Points

Description

From T321088#8431760 :

It turns out that all analytics-admins can now access the Admin tab. This was already in the config, but may not have been working in a previous version.

# If set, JupyterHub admin access will be enabled for users in these groups.
'admin_posix_groups': ['ops', 'analytics-admins'],

We will double check to see if this level of access is correct, or whether it should be modified

To illustrate this, below is a redacted screenshot from a jupyterhub instance started by @BTullis, who is in the ops group.
The view was similar for @xcollazo whoc is in the analytics-admins group.

image.png (678×1 px, 111 KB)

Given that this might have only recently started working, the purpose of this ticket is just to:

  • check that this level of access to start/stop others' servers is desirable
  • check that users outside of these groups do not have access to do so

Event Timeline

Yes, I think it is fine for analytics-admins to have this privilege.

Adding steps for a non-admin user to verify that they do not see the 'Admin' tab:

  1. Connect to JupyterHub in the usual way, say: ssh -N stat1007.eqiad.wmnet -L 8880:127.0.0.1:8880
  2. On a browser, go to http://localhost:8880/hub/home
  3. Confirm whether the 'Admin' tab is there or not
  4. Force the system to show the Admin screen by going directly to http://localhost:8880/hub/admin

The expected outcome is step (3) is for there to be no 'Admin' tab. For step (4), the expected outcome is an error page and/or HTTP 401 Unauthorized.

Adding steps for a non-admin user to verify that they do not see the 'Admin' tab:

  1. Connect to JupyterHub in the usual way, say: ssh -N stat1007.eqiad.wmnet -L 8880:127.0.0.1:8880
  2. On a browser, go to http://localhost:8880/hub/home
  3. Confirm whether the 'Admin' tab is there or not

I don't see an "Admin" tab.

Screenshot 2022-11-30 at 11.23.01.png (572×2 px, 87 KB)

  1. Force the system to show the Admin screen by going directly to http://localhost:8880/hub/admin

The expected outcome is step (3) is for there to be no 'Admin' tab. For step (4), the expected outcome is an error page and/or HTTP 401 Unauthorized.

I get a 403 Forbidden error.

Screenshot 2022-11-30 at 11.22.44.png (612×2 px, 90 KB)

xcollazo set the point value for this task to 1.
xcollazo moved this task from Ready to In Progress on the Data Pipelines (Sprint 05-06) board.

All right, @Ottomata agrees these admin privileges are reasonable, and @nshahquinn-wmf confirms that as a non-admin user he cannot access this page.

I'm good to close this. You good @BTullis ?

Synced with @BTullis, he's ok to close. Closing.