jpillora / jpillora/chisel

Intermittent Authentication Failure with Chisel Server After Updating users.json

Open
#493 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
16.6k
Forks
1.6k
PR merge metrics
No merged PRs in 30d

Description

Description

We are experiencing intermittent authentication failures with our Chisel server, specifically after updating the users.json file to add new users. This issue causes all clients to be unable to authenticate, displaying the error: "ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain."

Steps to Reproduce
  1. Run Chisel server with authentication enabled, using a users.json file for user management.
  2. Update users.json by adding new user credentials.
  3. After updating, Chisel clients experience authentication failures with the above error message.
  4. Restarting the Chisel server resolves the issue temporarily.
Expected Behavior

Updating the users.json file should not disrupt the ongoing authentication process, and new users should be able to authenticate without requiring a server restart.

Actual Behavior

Upon updating the users.json file, all clients, including those with existing valid credentials, are unable to authenticate until the Chisel server is restarted.

Additional Information
  • Chisel server and client versions: 1.9.1
  • Server OS: Kubernetes Cluster in GCP (linux) (Kernel Version: 5.15.133+)
  • Client OS: Ubuntu 20.04.6 LTS
  • Frequency of the issue: Occurs randomly upon updating users.json.
  • Any patterns noticed: Issue persists even after reverting the users.json file to its previous state.

I am seeking guidance on why this issue occurs and how to prevent it from happening in the future. Any insights or suggestions from the community would be greatly appreciated.

Thank you!

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 by tracing how the Chisel server loads users.json and how authentication state is used after a file update; reproduce the update while clients connect and inspect the reported SSH handshake error. Done means existing clients continue authenticating and newly added users work without a restart, with regression coverage for updating and reverting the file.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
authentication, backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.