Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 47503 - passwd segfault, when cracklib is emerge with some locales like cs_CZ
Summary: passwd segfault, when cracklib is emerge with some locales like cs_CZ
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-04-11 05:38 UTC by athli
Modified: 2005-03-13 01:17 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description athli 2004-04-11 05:38:53 UTC
When I try change password, it segfault with some passwords:
example:
#passwd
New UNIX password: thisispassword
(index fread failed): Success
zsh: segmentation fault  passwd

When I set LANG and LC_ALL from cs_CZ to en_US and remerge cracklib, then it works OK.

I am not alone - http://forums.gentoo.org/viewtopic.php?p=1033416

Reproducible: Always
Steps to Reproduce:
1.
2.
3.
Comment 1 Andrej Kacian (RETIRED) gentoo-dev 2004-09-09 12:33:01 UTC
Same here, for sk_SK locale
Comment 2 SpanKY gentoo-dev 2004-10-09 23:25:14 UTC
please re-open if cracklib-2.7-r9+ and 4.0.4.1-r4+ dont resolve this for you
Comment 3 athli 2004-10-11 13:38:48 UTC
still the same problem
Comment 4 SpanKY gentoo-dev 2004-10-31 19:53:43 UTC
i'm unable to reproduce this with shadow-4.0.4.1-r4 or shadow-4.0.5 :/

unless someone tracks this down themselves with gdb, i cant really help

root@vapier 0 ~ # export LC_ALL="sk" LC_CTYPE="sk" LINGUAS="sk"
root@vapier 0 ~ # emerge cracklib
< snip >
>>> sys-libs/cracklib-2.7-r10 merged.
< snip >
root@vapier 0 ~ # emerge shadow
< snip >
>>> sys-apps/shadow-4.0.4.1-r4 merged.
< snip >
root@vapier 0 ~ # passwd
New UNIX password: 
BAD PASSWORD: it is too short
Retype new UNIX password: 
passwd: password updated successfully
Comment 5 athli 2004-11-02 10:40:32 UTC
Seems that it works OK with cs or sk locale (LC_ALL=cs), but it segfaults when cracklib is emerge with cs_CZ or sk_SK locales (LC_ALL=cs_CZ). 

When I have set cs or sk locales, then command   locale   show error:

 `--# locale
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=sk
LC_CTYPE="sk"
LC_NUMERIC="sk"
LC_TIME="sk"
LC_COLLATE="sk"
LC_MONETARY="sk"
LC_MESSAGES="sk"
LC_PAPER="sk"
LC_NAME="sk"
LC_ADDRESS="sk"
LC_TELEPHONE="sk"
LC_MEASUREMENT="sk"
LC_IDENTIFICATION="sk"
LC_ALL=sk

It segfaults only with some specific passwords, for example    "thisispassword"

LC_ALL=cs_CZ emerge cracklib
`--# passwd                      
New UNIX password:thisispassword 
(index fread failed): Success
zsh: segmentation fault  passwd


I have tested it with shadow 4.0.4.1-r4 and 4.0.5 - it is the same.
Comment 6 SpanKY gentoo-dev 2004-11-03 20:17:33 UTC
ah ok now i can reproduce :)

root@vapier 0 ~ # export LC_ALL=sk_SK
root@vapier 0 ~ # emerge cracklib
< snip >
>>> sys-libs/cracklib-2.7-r10 merged.
< snip >
root@vapier 0 ~ # passwd
New UNIX password:thisispassword
(index fread failed): Success
Segmentation fault
Comment 7 SpanKY gentoo-dev 2005-02-12 12:21:45 UTC
could you please try emerging cracklib-2.8_pre1 and re-emerging shadow after that ?

2.8_pre1 is KEYWORDS=-* so you'll have to emerge it manually ...
Comment 8 athli 2005-02-12 13:47:23 UTC
I've tried it (shadow-4.0.5-r3). passwd doesn't work.

#passwd
passwd: Critical error - immediate abort
Comment 9 SpanKY gentoo-dev 2005-03-12 14:13:43 UTC
did you try emerging cracklib-2.8_pre1 and then re-emerging shadow ?
Comment 10 athli 2005-03-12 14:43:43 UTC
Yes, I tried.

I try it now with cracklib-2.8_pre1-r1 and it works OK. It's not necessary to remererging shadow after upgrade cracklib-2.8_pre1-r1.

Thanks very much

Comment 11 Martin Schlemmer (RETIRED) gentoo-dev 2005-03-13 01:17:36 UTC
You might have to remerge pam - happened here ...