wiki.techinc.nl/includes/shell
Tim Starling 65b1b6b56a Remove $wgShellLocale, always use C
$wgShellLocale was a flawed solution to the problem of locale
dependence. MediaWiki has its own concept of locale (the Language
hierarchy) and any kind of dependence on the server's libc locale is
incorrect and harmful, leading to bugs. Developers have an expectation
that functions like strtolower() will work in a certain way, and
respecting the locale set in the environment at install time violates
this expectation.

The problems with using C as a locale, which led to $wgShellLocale, are:

* escapeshellarg() will strip non-ASCII characters. This can be worked
  around by not using it. The security vulnerability it was trying to
  fix can be prevented in another way.
* Shell commands like rsvg will fail to correctly interpret UTF-8
  arguments. This is the reason for the putenv(). On Linux, this can
  be fixed by using C.UTF-8, which we didn't know at the time. On
  Windows, the problem is not relevant (there are unrelated issues
  with UTF-8 arguments).

Bug: T291234
Change-Id: Ib5ac0e7bc720dcc094303a358ee1c7bbdcfc6447
2021-09-24 17:25:01 -07:00
..
Hook
Command.php
CommandFactory.php shell: Fix $wgShellboxUrls by passing service name when creating BoxedCommand 2021-09-01 11:43:22 -07:00
firejail.profile
Result.php
Shell.php Remove $wgShellLocale, always use C 2021-09-24 17:25:01 -07:00
ShellboxClientFactory.php
ShellboxHttpClient.php