chef / chef/chef-web-docs

`user` docs is missing lots about passwords

Open
#2,663 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Aspect: Documentation Component: Chef Infra Client
Dominant language
HTML
Stars
143
Forks
438
Avg merge
1d 10h
Merged PRs (30d)
16

Description

The user resource doc shows an example that implies the password is a salted, hashed value. And in fact, on Linux/Unix it accepts that, but the docs never say that.

The docs do elaborate on the special magic you have to do for MacOSX, which is great.

But now we come to Windows, and there's no guidance on how to use this at all. Passing in a SHA1 salted hash as the docs imply seems to set the password to some un-login-able-state (ouch). That's scary. No combinations of salt and password seem to do better.

Taking a dig through the code, it's not at all clear what it takes.

If you finally go digging at the unit tests you will finally discover that the password seems to want plain text passwords. That's worth calling out, very explicitly.

Also, it'd be really really nice to be able to put hashed values into the repo instead of plain text passwords, but I'll file a non-docs bug on that.

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 user resource documentation and compare its password examples with the linked Windows provider code and spec/unit/provider/user/windows_spec.rb. Document explicitly that Windows expects plain-text passwords, clarify the Unix/Linux behavior, and preserve the existing macOS guidance. Done means the platform-specific password requirements and limitations are clear in the user resource docs.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.