Story #14964
closed
Port arvados-pam to Python 3
Added by Tom Morris almost 6 years ago.
Updated over 4 years ago.
Description
source:sdk/pam provides a PAM module that allows users to authenticate (e.g., to an SSH service on a shell node) using an Arvados token. It checks the same login permissions as source:services/login-sync. It makes it possible to provide a login service like shellinabox that doesn't have SSH private keys or tunnel options.
Currently it requires Python 2.7.
- Parent task deleted (
#14532)
- Tracker changed from Task to Story
- Target version changed from Arvados Future Sprints to To Be Groomed
- Blocks Story #14532: [Epic] Port to Python 3 to for Python 2 sunset in December 2019 added
- Subject changed from Port PAM to Python 3 to Port arvados-pam to Python 3
- Description updated (diff)
Pam-python is a PAM Module that runs the Python interpreter, thus allowing PAM Modules to be written in Python.
arvados-pam is one such "PAM module written in Python." We can make have made the arvados_pam module python3-compatible enough to pass its unit tests, but it can't be shown to work in real life (and can't eliminate the python2.7 dependency) until pam-python itself is updated to work with python3. The author hasn't done this yet, but plans to.
Debian ships pam-python as libpam-python. Even in buster, it still requires python2.7.
https://packages.debian.org/buster/libpam-python
If we can't wait for an upstream fix (or fork pam-python and do it ourselves) another approach would be to start fresh and implement a PAM module in Go, using someone else's example like https://github.com/uber/pam-ussh. This might be a better long term solution anyway -- it looks like we never even found a way to test the libpam-python solution without hitting segfaults.
- Description updated (diff)
- Description updated (diff)
(from discussion offline) having a PAM module is worthwhile (still the best way to enable shell-over-https for CLI/browser use) but the Python solution is looking like a dead end -- it's never been stable and the connector shim isn't even aimed at production use. Porting to Go seems like the least-effort long term solution.
- Status changed from New to Rejected
- Target version deleted (
To Be Groomed)
Also available in: Atom
PDF