Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1092 fix #1165

Merged
merged 3 commits into from Oct 29, 2013
Merged

Bug 1092 fix #1165

merged 3 commits into from Oct 29, 2013

Conversation

@LarsWestergren
Copy link
Contributor

@LarsWestergren LarsWestergren commented Oct 25, 2013

Behave like MRI - allow for instance UTF8 Strings to PKCS12.create, but coerce them to ASCII_8BIT so BouncyCastle can read them correctly.

@BanzaiMan
Copy link
Member

@BanzaiMan BanzaiMan commented Oct 29, 2013

See #1092.

@@ -31,6 +31,7 @@ def initialize(str = nil, password = '')
@der = file.read
file.close
else
str.force_encoding(Encoding::ASCII_8BIT) unless str.encoding == Encoding::ASCII_8BIT

This comment has been minimized.

@BanzaiMan

BanzaiMan Oct 29, 2013
Member

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.)

@LarsWestergren
Copy link
Contributor Author

@LarsWestergren LarsWestergren commented Oct 29, 2013

You are right. Unnecessary conditional removed.

headius added a commit that referenced this pull request Oct 29, 2013
@headius headius merged commit 8bd991d into jruby:master Oct 29, 2013
1 check passed
1 check passed
@veganstraightedge
default The Travis CI build passed
Details
@headius
Copy link
Member

@headius headius commented Oct 29, 2013

Thank you!

headius added a commit that referenced this pull request Oct 29, 2013
Bug 1092 fix

Signed-off-by: Charles Oliver Nutter <headius@headius.com>

Conflicts:
	test/externals/ruby2.0/openssl/test_pkcs12.rb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants