6.0.0-RC7
6/30/26

[#6396] ssh2 fails for non EN locale
Summary ssh2 fails for non EN locale
Queue Horde Framework Packages
Queue Version HEAD
Type Bug
State Resolved
Priority 2. Medium
Owners chuck (at) horde (dot) org
Requester michael-dev (at) fami-braun (dot) de
Created 3/7/08 (6689 days ago)
Due
Updated 3/7/08 (6689 days ago)
Assigned 3/7/08 (6689 days ago)
Resolved 3/7/08 (6689 days ago)
Github Issue Link
Github Pull Request
Milestone 3.2
Patch No

History
1110 Chuck Hagenbuch Comment #3
Assigned to Chuck Hagenbuch
Taken from Horde DevelopersHorde Developers
State ⇒ Resolved
Reply to this comment
Looks okay to me - committed, thanks!
341 Jan Schneider Assigned to Horde DevelopersHorde Developers
Milestone ⇒ 3.2
State ⇒ Assigned
 
2712 michael-dev (at) fami-braun (dot) de Comment #2 Reply to this comment
LC_TIME instead of LC_ALL would be sufficient.
3912 michael-dev (at) fami-braun (dot) de Comment #1
Priority ⇒ 2. Medium
Type ⇒ Bug
Summary ⇒ ssh2 fails for non EN locale
Queue ⇒ Horde Framework Packages
State ⇒ Unconfirmed
Reply to this comment
My server has got an non-us locale and ls therefore does not print the 
expected date format in VFS/ssh2.php.

Solution: Change

$stream = @ssh2_exec($this->_stream, "ls -al ".escapeshellarg($path));

and

$stream = @ssh2_exec($this->_stream, "ls -l ".escapeshellarg($path));



into



$stream = @ssh2_exec($this->_stream, "LC_ALL=C ls -al 
".escapeshellarg($path));

and

$stream = @ssh2_exec($this->_stream, "LC_ALL=C ls -l ".escapeshellarg($path));



This sets the locale to the default and works for me.

Saved Queries