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

Missing resource bundle in the bcjmail-jdk18on artifact since version 1.78 #1660

Open
vegamime opened this issue May 13, 2024 · 10 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@vegamime
Copy link

vegamime commented May 13, 2024

We have identified that since version 1.78, the resource bundle 'org.bouncycastle.mail.smime.validator.SignedMailValidatorMessages' is missing from the bcjmail-jdk18on artifact (but not from bcmail-jdk18on) .

This resource bundle is required by the class 'org.bouncycastle.mail.smime.validator.SignedMailValidator'.

Reading an entry from the ErrorBundle results in an exception. Example Stacktrace:
org.bouncycastle.pkix.util.MissingEntryException: Can't find entry SignedMailValidator.certPathInvalid.details in resource file org.bouncycastle.mail.smime.validator.SignedMailValidatorMessages. at org.bouncycastle.pkix.util.LocalizedMessage.getEntry(Unknown Source) at org.bouncycastle.pkix.util.ErrorBundle.getDetail(Unknown Source)

Could you please make this resource bundle available again?

Affected versions: 1.78 and 1.78.1

@vegamime
Copy link
Author

Upon reviewing the current SNAPSHOT version of bcjmail-jdk18on-1.79, it has been discovered that the mentioned resource files - SignedMailValidatorMessages.properties and SignedMailValidatorMessages_de.properties - are currently missing. Could you please provide them again? Thank you in advance!

@vegamime
Copy link
Author

Upon reviewing the current version of bcjmail-jdk18on-1.79, we have been discovered that the mentioned resource files - SignedMailValidatorMessages.properties and SignedMailValidatorMessages_de.properties - are still missing. Could you please provide them again? Thank you in advance!

@dghgit
Copy link
Contributor

dghgit commented Dec 22, 2024

Thanks for the report. Apologies for the delay... try what's in the current SNAPSHOT for 1.80 on https://downloads.bouncycastle.org/betas this should now be fixed.

@dghgit dghgit self-assigned this Dec 22, 2024
@dghgit dghgit added the bug Something isn't working label Dec 26, 2024
@vegamime
Copy link
Author

vegamime commented Jan 7, 2025

Hello David,

Thank you very much for the feedback and the provided SNAPSHOT for 1.80.

During the verification I noticed the following: In the resource file for the German language SignedMailValidatorMessages_de.properties there is probably an incorrect conversion from ISO-8859-1 to UTF-8. Instead of spezial characters like ü or ö, there is the replacement character EF BF BD encoded in UTF-8.

Could you please look at this again and correct the text entries?

Thank you in advance!

@dghgit
Copy link
Contributor

dghgit commented Jan 7, 2025

Would you be able to submit the corrected file as a pull request? I hate to admit to this, but we'll probably get a much better result if it we do - a lot of people think Australians don't speak English properly, I'm not sure it will end well if we try to correct UTF-8 conversions for German...

@vegamime
Copy link
Author

vegamime commented Jan 8, 2025

Hello David,

would it be possible to deliver the affected files in the ISO-8859-1 encoding as before and not perform a UTF-8 conversion?

In bcmail-jdk18on-1.80-SNAPSHOT, the message resources are also encoded in ISO-8859-1. Maybe in our case the conversion was done automatically by an IDE?

Best regards & thank you!

PS
It looks like the class org.bouncycastle.pkix.util.LocalizedMessage also assumes that the message resources are in ISO-8859-1.

@dghgit
Copy link
Contributor

dghgit commented Jan 8, 2025

Sure, let's give it a go. I'll put together a beta as soon as I get the files so it can be tested properly.

@vegamime
Copy link
Author

Hello David,

great! I think you can use the file SignedMailValidatorMessages_de.properties from bcjmail-jdk18on-1.77 or from bcmail-jdk18on-1.80-SNAPSHOT as a source.

Apart from the encoding, these files are identical to the corresponding file from bcjmail-jdk18on-1.80-SNAPSHOT.

Best regards & many thanks!

@dghgit
Copy link
Contributor

dghgit commented Jan 11, 2025

Ah... okay, it looks like the gradle copy was corrupting the files. I've added the files explicitly under jmail and pushed up a new beta, let me know how it goes.

@vegamime
Copy link
Author

Hello David, great, that looks good! I also tested it successfully. Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants