diff options
author | Andy Polyakov <appro@openssl.org> | 2016-07-26 16:42:41 +0200 |
---|---|---|
committer | Andy Polyakov <appro@openssl.org> | 2016-08-22 13:52:59 +0200 |
commit | 1194ea8dc3b51a35c9947ed276f38436abee5743 (patch) | |
tree | 3019d2d78ff46aea68ab706720222268d91bda6a /test/recipes | |
parent | b799aef863a81c9a9d5dbffae12cca912ae348b2 (diff) |
crypto/pkcs12: facilitate accessing data with non-interoperable password.
Originally PKCS#12 subroutines treated password strings as ASCII.
It worked as long as they were pure ASCII, but if there were some
none-ASCII characters result was non-interoperable. But fixing it
poses problem accessing data protected with broken password. In
order to make asscess to old data possible add retry with old-style
password.
Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'test/recipes')
-rw-r--r-- | test/recipes/80-test_pkcs12.t | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/recipes/80-test_pkcs12.t b/test/recipes/80-test_pkcs12.t index 681ce45fcb..bb3e0c84ee 100644 --- a/test/recipes/80-test_pkcs12.t +++ b/test/recipes/80-test_pkcs12.t @@ -20,6 +20,17 @@ if (eval { require Win32::Console; 1; }) { $savedcp = Win32::Console::OutputCP(); Win32::Console::OutputCP(1253); $pass = Encode::encode("cp1253",Encode::decode("utf-8",$pass)); +} else { + # Running MinGW tests transparenly under Wine apparently requires + # UTF-8 locale... + + foreach(`locale -a`) { + s/\R$//; + if ($_ =~ m/^C\.UTF\-?8/i) { + $ENV{LC_ALL} = $_; + last; + } + } } # just see that we can read shibboleth.pfx protected with $pass |