For a while now, the RHEL/FC OpenSSH packages have modified config settings to
pass locale variables between systems. However, the unconditional sourcing of
/etc/sysconfig/i18n overrides this! If a LANG is already set, it can be debated
if the user's ~/.i18n should be sourced, but the system file should not.
One reason that LANG from a remote system should not be changed is that LANG
encodes both a language and a character set. I use en_US, but I am sometimes
logged in from a non-Linux system (Tru64 Unix) that doesn't support UTF-8, so I
use en_US.ISO8859-1. There is no way for me to properly pass this right now
(having language and character set packed into one variable was probably not a
good idea to begin with; some things like man page caching don't really handle
it anyway, but oh well).
Do we send *all* LC_* variables?
SendEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
SendEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
SendEnv LC_IDENTIFICATION LC_ALL
AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
AcceptEnv LC_IDENTIFICATION LC_ALL
Obviously, if they aren't set, they aren't sent, but I think that covers them
all (if not I guess it would be a bug in the RHEL/FC OpenSSH config).
Checking the OpenSSH RPM changelog, this was added about a year ago in bugzilla
Added in CVS, will be in 8.50-1. I suspect *something* will break.