<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>22920</bug_id>
          
          <creation_ts>2003-06-16 05:04 0000</creation_ts>
          <short_desc>impossible to create account with period in login name</short_desc>
          <delta_ts>2005-04-04 08:43:19 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Core system</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>anigel@gentoo.org</reporter>
          <assigned_to>base-system@gentoo.org</assigned_to>
          <cc>jbarton@technicalworks.net</cc>
    
    <cc>sascha-gentoo-bugzilla@silbe.org</cc>
    
    <cc>zul@gentoo.org</cc>

      

      
          <long_desc isprivate="0">
            <who>anigel@gentoo.org</who>
            <bug_when>2003-06-16 05:04:22 0000</bug_when>
            <thetext>I need to create accounts whose usernames contain periods (example : 
firstname.name).

adduser firstname.name tells me : adduser: invalid user name &apos;firstname.name&apos;
and so does useradd.
Creating an account using the &apos;-&apos; character works, an i can change it &apos;by 
hand&apos; in the password file. But not easy to script, and sounds dangerous :-P

As i need scripting accounts creation i can&apos;t use interactive tools such as 
superadduser.

Note : on debian, the same problem occurs with adduser, but not with useradd !!
And on Mandrake, no problem at all, the 2 commands accept periods...

Reproducible: Always
Steps to Reproduce:
1. adduser firstname.name
2. useradd firstname.name

Actual Results:  
invalid user name &apos;firstname.name&apos;

And the system refuses to create the account

Expected Results:  
It should have created the account.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>zul@gentoo.org</who>
            <bug_when>2003-06-16 18:28:34 0000</bug_when>
            <thetext>Created an attachment (id=13393)
Patch to allow user to create a username with a &quot;.&quot;

Patch allows users to create a username with a &quot;.&quot;.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>zul@gentoo.org</who>
            <bug_when>2003-06-16 18:29:49 0000</bug_when>
            <thetext>Created an attachment (id=13394)
Patch to add my patch to shadow-4.0.3-r6

This adds an extra two lines to the ebuild so that the
shadow-4.0.3-chkname.patch to be used.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>zul@gentoo.org</who>
            <bug_when>2003-06-16 18:31:35 0000</bug_when>
            <thetext>Hi,


I have verified that you cant add username with a period in it. I get a invalid username error message.

This patch allows the username to have a period. I have tested with bot adduser and useradd. It worked fine when using adduser and useradd.

chuck</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>anigel@gentoo.org</who>
            <bug_when>2003-06-17 02:27:28 0000</bug_when>
            <thetext>OK, works for me too.

But i don&apos;t know how to change the bug status to &apos;solved&apos; (i read the patch, i see no reason to test anymore ;-).

Will it be incorporated to next version of shadow ? I hope so ;-)

Thanks again !

</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>ivan@modulix.org</who>
            <bug_when>2004-07-16 09:22:23 0000</bug_when>
            <thetext>I emerge a new version today (sys-apps/shadow-4.0.4.1-r3) and the bug is still there !</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>phceac@yahoo.com</who>
            <bug_when>2004-08-11 14:29:28 0000</bug_when>
            <thetext>This looks like Bug 37402 - see discussion there.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>anigel@gentoo.org</who>
            <bug_when>2004-09-21 09:11:51 0000</bug_when>
            <thetext>Well, i am still annoyed with this problem, so i was wondering if the patch would be one day incorporated to the gentoo package ?

This is really boring to have to patch every new server I install...

(I now use Gentoo in a professional way, to host several hundreds of users; some of them have the same name, so using firstname.lastname as a login is usefull for me.)

Thanks in advance :)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-09-21 10:51:11 0000</bug_when>
            <thetext>*** Bug 37402 has been marked as a duplicate of this bug. ***</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-09-21 10:54:57 0000</bug_when>
            <thetext>i&apos;ll make you a deal ... update the patch to fail if the _POSIX2_VERSION env var is set to a date less than some target date (i&apos;ll find the target date in a bit, it doesnt matter ...) and i&apos;ll add the patch to our shadow

the only real concern i have is with coreutils&apos; chown ... it checks the _POSIX2_VERSION env var to see if the &apos;.&apos; is a separator</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>anigel@gentoo.org</who>
            <bug_when>2004-09-21 11:41:39 0000</bug_when>
            <thetext>My english isn&apos;t perfect, but I think I understood the problem. In fact, I didn&apos;t matter about the chown problem since I never used this syntax (always used &quot;:&quot; as separator).

So, the problem is to check the _POSIX2_VERSION, to see if it is posterior to a date of your choice, in order to &quot;disable&quot; the old syntax in chown ? Yes / No ? ^^

Sorry, but I told you in the beginning : english not perfect :( .</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2004-09-21 15:20:30 0000</bug_when>
            <thetext>ah forget about it

i&apos;ll get seemant to remove the &apos;.&apos; compatibility of coreutils and we&apos;ll have the newer shadow DEPEND on it</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>vapier@gentoo.org</who>
            <bug_when>2005-01-09 22:34:39 0000</bug_when>
            <thetext>ok, ive added &apos;.&apos; support to shadow-4.0.6 (no version bump)</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>anigel@gentoo.org</who>
            <bug_when>2005-01-10 01:43:25 0000</bug_when>
            <thetext>Thanks a lot, I thought this bug was left back ;-) !</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>13393</attachid>
            <date>2003-06-16 18:28 0000</date>
            <desc>Patch to allow user to create a username with a &quot;.&quot;</desc>
            <filename>shadow-4.0.3-chkname.patch</filename>
            <type>text/plain</type>
            <data encoding="base64">ZGlmZiAtTmF1ciBzaGFkb3ctNC4wLjMub2xkL2xpYm1pc2MvY2hrbmFtZS5jIHNoYWRvdy00LjAu
My9saWJtaXNjL2Noa25hbWUuYwotLS0gc2hhZG93LTQuMC4zLm9sZC9saWJtaXNjL2Noa25hbWUu
YwkyMDAyLTAxLTEwIDEzOjA0OjM0LjAwMDAwMDAwMCArMDAwMAorKysgc2hhZG93LTQuMC4zL2xp
Ym1pc2MvY2hrbmFtZS5jCTIwMDMtMDYtMTYgMjE6MTk6MTIuMDAwMDAwMDAwICswMDAwCkBAIC0y
MiwxNSArMjIsMTUgQEAKIGdvb2RfbmFtZShjb25zdCBjaGFyICpuYW1lKQogewogCS8qCi0JICog
VXNlci9ncm91cCBuYW1lcyBtdXN0IG1hdGNoIFthLXpfXVthLXowLTlfLV0qCisJICogVXNlci9n
cm91cCBuYW1lcyBtdXN0IG1hdGNoIFthLXpfXVthLXowLTlfLS5dKgogCSAqLwotCWlmICghKm5h
bWUgfHwgISgoKm5hbWUgPj0gJ2EnICYmICpuYW1lIDw9ICd6JykgfHwgKm5hbWUgPT0gJ18nKSkK
KwlpZiAoISpuYW1lIHx8ICEoKCpuYW1lID49ICdhJyAmJiAqbmFtZSA8PSAneicpIHx8ICpuYW1l
ID09ICdfJyB8fCAqbmFtZSA9PSAnLicpKQogCQlyZXR1cm4gMDsKIAogCXdoaWxlICgqKytuYW1l
KSB7CiAJCWlmICghKCgqbmFtZSA+PSAnYScgJiYgKm5hbWUgPD0gJ3onKSB8fAogCQkgICAgKCpu
YW1lID49ICcwJyAmJiAqbmFtZSA8PSAnOScpIHx8Ci0JCSAgICAqbmFtZSA9PSAnXycgfHwgKm5h
bWUgPT0gJy0nIHx8CisJCSAgICAqbmFtZSA9PSAnXycgfHwgKm5hbWUgPT0gJy0nIHx8ICpuYW1l
ID09ICcuJyB8fAogCQkgICAgKCpuYW1lID09ICckJyAmJiAqKG5hbWUrMSkgPT0gTlVMTCkpKQog
CQkJcmV0dXJuIDA7CiAJfQo=
</data>        

          </attachment>
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>13394</attachid>
            <date>2003-06-16 18:29 0000</date>
            <desc>Patch to add my patch to shadow-4.0.3-r6</desc>
            <filename>shadow-4.0.3-r6.ebuild.fix</filename>
            <type>text/plain</type>
            <data encoding="base64">LS0tIC91c3IvcG9ydGFnZS9zeXMtYXBwcy9zaGFkb3cvc2hhZG93LTQuMC4zLXI2LmVidWlsZAky
MDAzLTA1LTE4IDEyOjU0OjAxLjAwMDAwMDAwMCArMDAwMAorKysgc2hhZG93LTQuMC4zLXI2LmVi
dWlsZAkyMDAzLTA2LTE2IDIxOjM1OjQ4LjAwMDAwMDAwMCArMDAwMApAQCAtNTQsNiArNTQsOSBA
QAogCSMgVGhhbmtzIHRvIEd1eSA8Z3V5Y2FkQG1pbmRzcHJpbmcuY29tPi4KIAllcGF0Y2ggJHtG
SUxFU0RJUn0vJHtQfS11c2VyYWRkLW1hbnBhZ2UtdXBkYXRlLnBhdGNoCiAKKyAgICAjIFBhdGNo
IHRvIGFsbG93IGEgdXNlciB0byBhZGQgYSAiLiIgdG8gdGhlIGxvZ2luIG5hbWUsCisJIyBjbG9z
ZXMgYnVnICMgMjI5MjAgLSBDaHVjayBTaG9ydCA8Y2h1Y2tfc2hvcnRAcm9nZXJzLmNvbT4KKwll
cGF0Y2ggJHtGSUxFU0RJUn0vJHtQfS1jaGtuYW1lLnBhdGNoCiAJIyBOZWNlc3Nhcnkgc2VsaW51
eCBwYXRjaAogCXVzZSBzZWxpbnV4ICYmIGVwYXRjaCAke0RJU1RESVJ9LyR7UH0tc2VsaW51eC5w
YXRjaC5iejIKIH0K
</data>        

          </attachment>
    </bug>

</bugzilla>