Samba Fails to Split GECOS on Comma

Bug #182572 reported by Richard Laager
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Server papercuts
Fix Released
Medium
Chuck Short
samba
Fix Released
Medium
samba (Debian)
Fix Released
Unknown
samba (Ubuntu)
Fix Released
Low
Unassigned
Declined for Lucid by Thierry Carrez

Bug Description

Pulling up the Start Menu on a Windows XP machine joined to a Samba PDC
shows, for example, "Richard Laager,,," as the full name. This is
because the GECOS field on the server contains commas, apparently added
by chfn(1). Samba should stop at the first comma.

Changed in samba:
status: Unknown → New
Changed in samba:
status: New → Confirmed
Changed in samba:
status: Unknown → Confirmed
Revision history for this message
Chuck Short (zulcss) wrote :

Thanks for the bug report.

Changed in samba:
status: New → Confirmed
Chuck Short (zulcss)
Changed in samba:
importance: Undecided → Low
Revision history for this message
Richard Laager (rlaager) wrote :

I don't know why you think this is a duplicate of bug #289299. That sounds like a completely separate issue. This bug here is about how Samba does not properly parse the GECOS field that it gets (perhaps indirectly) from /etc/passwd.

Revision history for this message
Dave Gomboc (davegomboc) wrote :

I wouldn't want to cause a worse problem than the annoyance I'd be solving. Would editing /etc/passwd to remove the three commas be an effective workaround for this problem?

If not, what would be an effective workaround?

Revision history for this message
Richard Laager (rlaager) wrote :

semi-newbie: Yes, just delete the commas. They'll come back when you use certain tools to make certain edits, but you can just remove them again.

Thierry Carrez (ttx)
Changed in samba (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Dave Gomboc (davegomboc) wrote :

I attempted to use the prescribed workaround (editing /etc/passwd to remove the ,,, after the name), but this did not work for me. I don't see any change (I still get "User Name,,," in the Start Menu under Windows XP.

Revision history for this message
JMalone (jmalone) wrote :

I've noticed this issue as well. There is a bug report on samba's bugzilla: http://www.samba.org/samba/docs/man/manpages-3/smbd.8.html

Looks pretty stagnant. I'm trying my hand at solving this and proposed a possible solution there. Please look at it and let me know if you have any comment/suggestions or if I'm way off base. I don't have a good environment to test it out either so if you're able to try it (not in a production environment) please do.

Revision history for this message
JMalone (jmalone) wrote :

Oops....the url I posted above is dead wrong. The samba bug report is at https://bugzilla.samba.org/show_bug.cgi?id=5198

Revision history for this message
JMalone (jmalone) wrote :

There is a patch for this bug now available at https://bugzilla.samba.org/show_bug.cgi?id=5198 . Please note that this fix doesn't affect existing samba user accounts, only newly created ones. To fix existing accounts you should use 'pdbedit' to correct the full name fields for existing users.

Thierry Carrez (ttx)
Changed in server-papercuts:
importance: Undecided → Medium
status: New → Confirmed
Thierry Carrez (ttx)
Changed in server-papercuts:
milestone: none → lucid-beta-1
Changed in samba:
status: Confirmed → Fix Released
Thierry Carrez (ttx)
Changed in server-papercuts:
assignee: nobody → Chuck Short (zulcss)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package samba - 2:3.4.5~dfsg-2ubuntu4

---------------
samba (2:3.4.5~dfsg-2ubuntu4) lucid; urgency=low

  * debian/patches/ubuntu-gecos-fix.patch: Fix gecos parsing backported
    from Samba 3.5.x. (LP: #182572)
 -- Chuck Short <email address hidden> Wed, 03 Mar 2010 09:35:26 -0500

Changed in samba (Ubuntu):
status: Triaged → Fix Released
Thierry Carrez (ttx)
Changed in server-papercuts:
status: Confirmed → Fix Released
Changed in samba (Debian):
status: Confirmed → Fix Released
Changed in samba:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.