maintain user TLS context selection after faas-cli login
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 816
- Forks
- 230
- Avg merge
- 6h 4m
- Merged PRs (30d)
- 1
Description
Expected Behavior
I've got an OpenFaaS deployment which uses a custom self-sign certificate. When logging into the OpenFaas endpoint via faas-cli, I need to use --tls-no-verify flag as expected. However, upon a successful login, I would not expect to need to pass this argument again as that user selection should be part of the login operation and stored.
Below is an example of logging and specify no TLS verify and then following operation is to create a secret and I would not expect to provide the no TLS verify argument again.
faas-cli login --username admin --password-stdin --tls-no-verify
faas-cli secret create vcconfig --from-file=vcconfig.toml
Current Behaviour
Since the no TLS verify argument is not persisted upon successful login, all CLI operations must have this additional flag appended which is a bit cumbersome.
faas-cli login --username admin --password-stdin --tls-no-verify
faas-cli secret create vcconfig --from-file=vcconfig.toml --tls-no-verify
Possible Solution
Persist the TLS context as part of the initial login and not require that upon subsequent CLI operations until session has either expired or user has logged out
Steps to Reproduce (for bugs)
Step 1 - Configure OpenFaaS w/self-sign certificate
Step 2 - Login via the CLI and specify --tls-no-verify
Step 3 - Perform operation afterwards like creating a secret without specifying --tls-no-verify
Your Environment
-
FaaS-CLI version ( Full output from:
faas-cli version): 0.8.4 -
Docker version
docker version(e.g. Docker 17.0.05 ): 19.03.2 -
Are you using Docker Swarm or Kubernetes (FaaS-netes)? FaaS-netes
-
Operating System and version (e.g. Linux, Windows, MacOS): VMware PhotonOS
-
Code example or link to GitHub repo or gist to reproduce problem: N/A
-
Other diagnostic information / logs from troubleshooting guide: N/A
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the faas-cli login entry point and trace how --tls-no-verify is handled for login and for the secret create operation. Inspect the existing session or configuration handling and tests; done means a successful login preserves the TLS choice so later commands do not need the flag again.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- authentication, cli, security
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100