StackStorm / StackStorm/st2

st2 whoami to be reinvented

Open
#3,832 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

CLI stale
Dominant language
Python
Stars
6.5k
Forks
787
PR merge metrics
No merged PRs in 30d

Description

I installed st2. I never ran st2 login. st2 whoami says I am logged in as st2admin.
https://gist.github.com/lakshmi-kannan/2c791a6a3d8a02e699f03c289e79e83e

st2 whoami doesn't add much value. st2 whoami if it reads from st2 config should say “Current username is st2admin”. It never bothered to know if a login was actually done meaning it didn’t audit the login part.

At this point, I could cat ~/.st2/config

If I had something that tracked when last login was made, when last auth token was vended, when it expires and I include that info, then it’s different. In fact, this is useful along with rbac roles. See PR https://github.com/StackStorm/st2/pull/3831.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the st2 whoami entry point and inspect how it reads ~/.st2/config. Review PR 3831 for the related authentication context and determine the intended distinction between configured username and actual login or token state. Done should be defined for both the reported username and any requested login, token, expiry, or RBAC information.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
authentication, cli
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.