Blowfish and Base64 discrepancies

Hi guys,

I’m reworking some parts of our licenser and I noticed that Blowfish and MemoryBlock’s base64 encoding/decoding are different from the ones implemented in php and openssl libs.

Is there a reason for that? What are the alternatives?

Thanks,
Luca

Not sure about Blowfish, but for the base64 there is the juce::Base64 namespace with static funtions.
The docs to MemoryBlock.toBase64Encoding() mentions the fact that it is non-standard (but easy to miss, I learned it the hard way) and links the Base64 namespace:

This uses a JUCE-specific (i.e. not standard!) 64-bit encoding system to convert binary data into a string of ASCII characters for purposes like storage in XML. Note that this proprietary format is mainly kept here for backwards-compatibility, and you may prefer to use the Base64::toBase64() method if you want to use the standard base-64 encoding.

Thanks Daniel. I missed that too! ok, having a standard implementation for Base64 will help for sure. I’ll if I can find a compatible implementation of Blowfish or a super small and fast crypto library.

Thanks,
Luca