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

Encrypt and decrypt a project change the special chars #550

Open
stefv opened this issue Nov 16, 2020 · 1 comment
Open

Encrypt and decrypt a project change the special chars #550

stefv opened this issue Nov 16, 2020 · 1 comment

Comments

@stefv
Copy link

stefv commented Nov 16, 2020

Hi,

I'm trying to use the feature to encrypt and decrypt a project but during my tests, I realized when the project is decrypted, the special chars (chars like éçà) are becoming unknown chars (���).

@stefv
Copy link
Author

stefv commented Nov 17, 2020

I checked the source code and the String#getByte() doesn't use "UTF-8" charset:

byte[] encrypted = OpenSSL.encrypt(encryptionAlgorithm, passwordForEncryption.toCharArray(), data.getBytes());

But the decrypt uses it:

String decryptedData = new String(data, "UTF-8");

The solution to fix temporary (without to change the code) is to set the charset in the soapui starting script adding that on the JAVA_OPTS:

-Dfile.encoding=UTF-8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant