Bug 112518 - If an application whose name includes non ascii characters is executed on ja_JP.UTF-8 locale, ps(1) cannot output the application name correctly.
If an application whose name includes non ascii characters is executed on ja_...
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: procps (Show other bugs)
3.0
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Karel Zak
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-12-21 21:34 EST by L3support
Modified: 2007-11-30 17:06 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-11-18 03:31:24 EST
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 L3support 2003-12-21 21:34:00 EST
Description of problem:
If an application whose name or path includes multibyte characters is
executed on ja_JP.UTF-8 locale, ps(1) cannot output the application name 
correctly.


Version-Release number of selected component (if applicable):
2.0.13-9.2E


How reproducible:
・always


Steps to Reproduce:
1. $ echo $LANG
2. $ ./テスト
3. $ ps -al

  
Actual results:
  $ echo $LANG
  ja_JP.UTF-8
  $ ./テスト &
  [1] 18904
  $ ps -af
  UID        PID  PPID  C STIME TTY          TIME CMD
     .
     .
  root     18795     1  0 12:38 tty1     00:00:00 /usr/libexec/gconfd-2 5
  root     18904 18876  0 15:59 pts/5    00:00:00 ./?????
  root     19148  2893  0 15:59 pts/0    00:00:00 ps -af
  $


Expected results:
ps(1) output application name correctly

  $ ./テスト &
  [1] 18904
  $ ps -af
  UID        PID  PPID  C STIME TTY          TIME CMD
     .
     .
  root     18795     1  0 12:38 tty1     00:00:00 /usr/libexec/gconfd-2 5
  root     18904 18876  0 15:59 pts/5    00:00:00 ./テスト
  root     19148  2893  0 15:59 pts/0    00:00:00 ps -af
  $


Additional info:
Comment 1 Alexander Larsson 2004-02-05 05:28:58 EST
Mass reassign to new owner
Comment 2 Daniel Walsh 2004-02-11 09:10:32 EST
Could you try this with procps 3.1.15
Comment 3 Daniel Walsh 2004-03-29 07:54:53 EST
Comments from Upstream Maintainer.

Fixing this is somewhat dangerous. Process names are
untrusted data. If they contain escape codes, they could
reprogram the terminal's keys!

The byte (0x80|'\e') must NEVER be printed. If the terminal
is not really in UTF-8 mode, all sorts of mayhem can occur.

Beyond that... sure, something could be done. Troublesome
characters should be filtered out. These include:

* major UTF-8 encoding violations (0x88 0x88 0x88 0x88)
* minor UTF-8 encoding violations (non-canonical form)
* anything else likely to confuse a terminal

Comment 4 Karel Zak 2004-11-18 03:31:24 EST
The problem with UTF-8 cannot be fixed in RHEL3 / RHEL4. It require
rewrite a lot of code in "ps". This is done in version 3.2.4 that is
avaiable for FC4 and probably will in new RHEL (>4) versions.

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