[oe-commits] [openembedded-core] 27/61: useradd_base: avoid unintended expansion for useradd parameters
git at git.openembedded.org
git at git.openembedded.org
Fri Sep 23 14:28:34 UTC 2016
rpurdie pushed a commit to branch krogoth
in repository openembedded-core.
commit 42a0d59d5923fb43882d8e60f6973b45b263e262
Author: Maxin B. John <maxin.john at intel.com>
AuthorDate: Tue Aug 16 14:12:03 2016 +0300
useradd_base: avoid unintended expansion for useradd parameters
Now, useradd dollar sign requires three prepending backslash characters to
avoid unintended expansion. It used to be just one prepending backslash
character before Krogoth. Restore that behaviour.
[YOCTO #10062]
(From OE-Core rev: 9e43a73c7ad576666d53c8c9e0283bc6bb9087a8)
Signed-off-by: Niko Mauno <niko.mauno at vaisala.com>
Signed-off-by: Maxin B. John <maxin.john at intel.com>
Signed-off-by: Ross Burton <ross.burton at intel.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
Signed-off-by: Armin Kuster <akuster808 at gmail.com>
---
meta/classes/useradd_base.bbclass | 2 --
1 file changed, 2 deletions(-)
diff --git a/meta/classes/useradd_base.bbclass b/meta/classes/useradd_base.bbclass
index 0d81acc..f4dc713 100644
--- a/meta/classes/useradd_base.bbclass
+++ b/meta/classes/useradd_base.bbclass
@@ -17,7 +17,6 @@ perform_groupadd () {
local groupname=`echo "$opts" | awk '{ print $NF }'`
local group_exists="`grep "^$groupname:" $rootdir/etc/group || true`"
if test "x$group_exists" = "x"; then
- opts=`echo $opts | sed s/\'/\"/g`
eval flock -x $rootdir${sysconfdir} -c \"$PSEUDO groupadd \$opts\" || true
group_exists="`grep "^$groupname:" $rootdir/etc/group || true`"
if test "x$group_exists" = "x"; then
@@ -35,7 +34,6 @@ perform_useradd () {
local username=`echo "$opts" | awk '{ print $NF }'`
local user_exists="`grep "^$username:" $rootdir/etc/passwd || true`"
if test "x$user_exists" = "x"; then
- opts=`echo $opts | sed s/\'/\"/g`
eval flock -x $rootdir${sysconfdir} -c \"$PSEUDO useradd \$opts\" || true
user_exists="`grep "^$username:" $rootdir/etc/passwd || true`"
if test "x$user_exists" = "x"; then
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list