Behave like MRI - allow for instance UTF8 Strings to PKCS12.create, but coerce them to ASCII_8BIT so BouncyCastle can read them correctly.
Tests for PKCS12 - allow creating from UTF8 strings but coerce to ASC…
…II. Bug 1092.
Coerce PKCS12 init string to ASCII_8BIT if not.
Do we need unless here? Seems to me that if encoding is ASCII_8BIT already, there is no harm in forcing it. (And the code is slightly cleaner as a result.)
Remove unnecessary conditional.
You are right. Unnecessary conditional removed.