Sign String With SHA256
- 12 Dec 2022
- 1 Minute to read
- Print
- DarkLight
Sign String With SHA256
- Updated on 12 Dec 2022
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Step Details | |
Introduced in Version | 4.0.0 |
Last Modified in Version | 5.0.0 |
Location | Data > Text |
The Sign String With SHA256 will sign a string value using a secret key string and encoding type with SHA256 encryption
Properties
Inputs
Property | Description | Data Type |
---|---|---|
Encoding | Allows the user to select the encoding type | StringEncodingType |
Secret String | Secret string to sign the string | String |
String To Sign | The desired string to sign | String |
Outputs
Property | Description | Data Type |
---|---|---|
Output | Encrypted SHA256 string | String |
Example Inputs and Outputs
String To Sign | Secret String | Encoding | Output |
---|---|---|---|
More Text | scree | Unicode | JKB1ZFahT5PGLP7lQtE5jdzzAiR6aKwYVMrCI7HOYEk= |
More Text | 4n8si3lx8 | UTF8 | qj0C2H6i3ru268w15mJ6GcmKYYW6DlDiaJzX/lcwixM= |
More Text | Null | UTF32 | F5RQb7PeFYVC7vlOOuQoea4ZsYpGkVLorSG7aSmzZZA= |
Null Value | 8dj3ss3s9x | ASCII | EXCEPTION MESSAGE |
Common Errors
String reference not set to an instance of a String
If the String to Sign is null, an error will occur.
To correct this, ensure that the value in String to Sign is not null.
Exception Message:
Exception Stack Trace: DecisionsFramework.Design.Flow.ErrorRunningFlowStep: Error running step Sign String With SHA 256 1[SignStringWithSHA256] in flow [Flow 2]: Exception invoking method SignStringWithSHA256 on class StringEncryption
---> DecisionsFramework.LoggedException: Exception invoking method SignStringWithSHA256 on class StringEncryption
---> System.ArgumentNullException: String reference not set to an instance of a String. (Parameter 's')
at System.Text.Encoding.GetBytes(String s)
at DecisionsFramework.Design.Flow.CoreSteps.StandardSteps.StringEncryption.SignStringWithSHA256(String stringToSign, String secretString, StringEncodingType encoding)
--- End of inner exception stack trace ---
at DecisionsFramework.Design.Flow.StepImplementations.InvokeMethodStep.Run(StepStartData data)
at DecisionsFramework.Design.Flow.FlowStep.RunStepInternal(String flowTrackingID, String stepTrackingID, KeyValuePairDataStructure[] stepRunDataValues, AbstractFlowTrackingData trackingData)
at DecisionsFramework.Design.Flow.FlowStep.Start(String flowTrackingID, String stepTrackingID, FlowStateData data, AbstractFlowTrackingData trackingData, RunningStepData currentStepData) --
Was this article helpful?