Commit 372aa8f
committed
Use usermod(8) on OpenBSD to unbreak password management
f1e77c2 "(PUP-3634) Hide password hash from process list for useradd"
introduced `chpasswd -e` which does not exist on OpenBSD, thus `user`
resources managing `password` would always fail:
```
Notice: Compiled catalog for atar in environment production in 0.02 seconds
rror: Could not set password on user[test]: No command chpasswd defined for provider openbsd
Error: /Stage[main]/Main/User[test]/password: change from [redacted] to [redacted] failed: Could not set password on user[test]: No command chpasswd defined for provider openbsd
Notice: Applied catalog in 0.01 seconds
```
Use https://man.openbsd.org/usermod.8#p instead:
```
Notice: Compiled catalog for atar in environment production in 0.01 seconds
Notice: /Stage[main]/Main/User[test]/password: changed [redacted] to [redacted]
Notice: Applied catalog in 0.21 seconds
```
`password` values now do show up briefly in the process list, but given
they must be encrypted in order to work, this does not seem critical.1 parent 9336df1 commit 372aa8f
1 file changed
+15
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
79 | 94 | | |
0 commit comments