OCLOperators StringToBase64
(Created page with "Will convert the string to an UTF8 encoded string stored in Base64 format.")
 
(Automatically adding template at the end of the page.)
 
(8 intermediate revisions by 3 users not shown)
Line 1: Line 1:
Will convert the string to an UTF8 encoded string stored in Base64 format.
Will convert the string to a UTF8 encoded string stored in Base64 format.
 
When sending Base64 as URL parameter, / and + will not survive - it is common to go like this: StringToBase64.Replace('/','_').Replace('+','-')
 
Chances are that the receiver will use this frequently used replacement pattern and understand the data - [https://stackoverflow.com/questions/1228701/code-for-decoding-encoding-a-modified-base64-url-in-asp-net-framework See this SO-article for background]
 
If you have a string in clear text and want it as a byte array (BLOB), do this 'My clear text string'.StringToBase64.[[OCLOperators Base64ToBlob|Base64ToBlob]]
 
When sending SAML tokens - and possibly other things - you are expected to compress the data with Deflate. You can follow a pattern to access the Deflate mechanism in Turnkey. Read more here: [[SysSingleton.Deflate]]
 
[[Category:OCLOperators]]
{{Edited|July|12|2024}}

Latest revision as of 15:40, 10 February 2024

Will convert the string to a UTF8 encoded string stored in Base64 format.

When sending Base64 as URL parameter, / and + will not survive - it is common to go like this: StringToBase64.Replace('/','_').Replace('+','-')

Chances are that the receiver will use this frequently used replacement pattern and understand the data - See this SO-article for background

If you have a string in clear text and want it as a byte array (BLOB), do this 'My clear text string'.StringToBase64.Base64ToBlob

When sending SAML tokens - and possibly other things - you are expected to compress the data with Deflate. You can follow a pattern to access the Deflate mechanism in Turnkey. Read more here: SysSingleton.Deflate

This page was edited more than 11 months ago on 02/10/2024. What links here