Bug 14605

Summary: usermod -P is not valid anymore and causes build failure
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Vivien Didelot <vivien.didelot>
Component: coreAssignee: Daiane <angolini>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: angolini, meta.mr.watcher, meta.watcher, randy.macleod
Version: unspecified   
Target Milestone: Future   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Yes (doc changes required)

Description Vivien Didelot 2021-10-15 21:23:38 UTC
Using usermod -P in EXTRA_USERS_PARAMS as stated in the documentation [1] causes a "usermod: prefix must be an absolute path" build error.

The -P option was being added by an OE-specific patch to shadow that was dropped when it was last upgraded. Now -P corresponds to the usermod prefix option. Plain password cannot be provided via -P anymore and must be provided via -p with a hashed value computed for example with mkpasswd -m sha512crypt (making sure $ is escaped).

[1] https://docs.yoctoproject.org/singleindex.html#extrausers-bbclass
Comment 1 Randy MacLeod 2021-10-21 14:41:39 UTC
Diane will submit a patch for this.
Comment 3 Daiane 2021-11-23 18:16:20 UTC
Since [1] a clear password cannot be set any longer.


[1] http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/meta/recipes-extended/shadow?id=087070bf2156681bd6a5b3bac89f9712545a6768