openshift / openshift/origin

Accepting a password on the command line is unsafe

Open
#22,997 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

lifecycle/frozen
Dominant language
Go
Stars
8.7k
Forks
4.8k
Avg merge
4d 10h
Merged PRs (30d)
53

Description

https://github.com/openshift/origin/blob/e5c7d40ea37921b02438787c1f28c79f844d1faf/pkg/oc/cli/login/login.go#L44

This ought to be removed or at the least there should to be a warning here that this is unsafe. Command line arguments are not protected from sniffing by other users (say, with ps). Environment variables are not exposed in the same way.

Contributor guide

No contributing guide indexed for this repository

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 at pkg/oc/cli/login/login.go#L44 and inspect how the login command receives password arguments. Determine whether the unsafe command-line password path should be removed or warned about, then verify that the resulting behavior no longer silently accepts an unsafe password argument.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
authentication, cli, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.