Bug 456719 - -p option doesn't work when the current locale is not english
-p option doesn't work when the current locale is not english
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: sudo (Show other bugs)
8
i386 Linux
low Severity low
: ---
: ---
Assigned To: Peter Vrabec
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-07-25 15:32 EDT by Miguel Angel Perez
Modified: 2008-07-31 09:19 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-07-31 09:19:24 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Miguel Angel Perez 2008-07-25 15:32:08 EDT
Description of problem:

Using -p option doesn't work if the locale is not english. Instead of the custom
prompt text it shows the translation of the default prompt.

Version-Release number of selected component (if applicable):
sudo-1.6.9p4-6.fc8

How reproducible:
Always

Steps to Reproduce:
1. Configure sudoers file to give you permission to use sudo to execute whoami
as root or all commands.
3. Change your locale to a non-english one like es_ES.utf8 or it_IT.utf8
  # export LC_ALL="es_ES.utf8"
2. Call sudo with a custom prompt. 
  # sudo -p "[MyCustomPrompt]: " whoami
  
Actual results:
In each case it shows the translated default prompt message except in english
locales.

 - For the es_ES.utf8:
     Contraseña: 
 - For the it_IT.utf8:
     Parola d'ordine:
 - For the en_US.utf8:
      [MyCustomPrompt]:
 - For the en_GB.utf8:
      [MyCustomPrompt]:

Expected results:
In every case it should output the prompt: 
  [MyCustomPrompt]:

Additional info:
# uname -a
  Linux hyperion.hegemony 2.6.25.10-47.fc8 #1 SMP Mon Jul 7 18:39:51 EDT 2008
i686 i686 i386 GNU/Linux

# locale
LANG=es_ES.UTF-8
LC_CTYPE="es_ES.UTF-8"
LC_NUMERIC="es_ES.UTF-8"
LC_TIME="es_ES.UTF-8"
LC_COLLATE="es_ES.UTF-8"
LC_MONETARY="es_ES.UTF-8"
LC_MESSAGES="es_ES.UTF-8"
LC_PAPER="es_ES.UTF-8"
LC_NAME="es_ES.UTF-8"
LC_ADDRESS="es_ES.UTF-8"
LC_TELEPHONE="es_ES.UTF-8"
LC_MEASUREMENT="es_ES.UTF-8"
LC_IDENTIFICATION="es_ES.UTF-8"
LC_ALL=
Comment 1 Lukas Kuklinek 2008-07-31 07:20:49 EDT
This is already fixed in Fedora 9.

Note You need to log in before you can comment on or make changes to this bug.