Codeunit 1266 "Cryptography Management"
System Application · System.Security.Encryption
Across versions
- BC23present
- BC246 procedures changed, 6 procedures added
- BC251 procedures added
- BC26unchanged
- BC276 procedures removed
- BC289 procedures added
- BC292 procedures changed
- BC30unchanged
Neighbourhood 14 connected objects and pages
System Application · System.Security.Encryption · BC23-30 · source at ea08af5e · facts from BC29
Properties
| Property | Value |
|---|---|
| Access | Public |
Events published
OnBeforeEnableEncryptionOnPrem()(integration): Publishes an event that allows subscription when enabling encryption.OnBeforeDisableEncryptionOnPrem()(integration): Publishes an event that allows subscription when disabling encryption.
Procedures
EncryptText(InputString: Text[215]): TextΔ BC29: Returns plain text as an encrypted value.Decrypt(EncryptedString: Text): TextΔ BC29: Returns encrypted text as plain text.IsEncryptionEnabled(): Boolean: Checks if Encryption is enabled.IsEncryptionPossible(): Boolean: Checks whether the encryption key is present, which only works if encryption is enabled.GetEncryptionIsNotActivatedQst(): Text: Gets the recommended question to activate encryption.EnableEncryption(Silent: Boolean): Enables encryption.DisableEncryption(Silent: Boolean): Disables encryption.GenerateHash(InputString: SecretText; HashAlgorithmType: Option MD5,SHA1,SHA256,SHA384,SHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a hash from a string based on the provided hash algorithm.GenerateHash(InputString: Text; HashAlgorithmType: Option MD5,SHA1,SHA256,SHA384,SHA512): TextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a hash from a string based on the provided hash algorithm.GenerateHash(InputString: SecretText; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a keyed hash from a string based on provided hash algorithm and key.GenerateHash(InputString: Text; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): TextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a keyed hash from a string based on provided hash algorithm and key.GenerateHash(InputInStream: InStream; HashAlgorithmType: Option MD5,SHA1,SHA256,SHA384,SHA512): TextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a hash from a stream based on the provided hash algorithm.GenerateHashAsBase64String(InputString: SecretText; HashAlgorithmType: Option MD5,SHA1,SHA256,SHA384,SHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a base64 encoded hash from a string based on provided hash algorithm.GenerateHashAsBase64String(InputString: Text; HashAlgorithmType: Option MD5,SHA1,SHA256,SHA384,SHA512): TextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a base64 encoded hash from a string based on provided hash algorithm.GenerateHashAsBase64String(InputString: SecretText; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a keyed base64 encoded hash from a string based on provided hash algorithm and key.GenerateHashAsBase64String(InputString: Text; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): TextΔ BC24 + BC24 − BC27 + BC28 + BC28: Generates a keyed base64 encoded hash from a string based on provided hash algorithm and key.GenerateBase64KeyedHashAsBase64String(InputString: SecretText; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28: Generates keyed base64 encoded hash from provided string based on provided hash algorithm and base64 key.GenerateBase64KeyedHashAsBase64String(InputString: Text; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): TextΔ BC24 + BC24 − BC27 + BC28: Generates keyed base64 encoded hash from provided string based on provided hash algorithm and base64 key.GenerateBase64KeyedHash(InputString: SecretText; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): SecretTextΔ BC24 + BC24 − BC27 + BC28: Generates keyed base64 encoded hash from provided string based on provided hash algorithm and base64 key.GenerateBase64KeyedHash(InputString: Text; Key: SecretText; HashAlgorithmType: Option HMACMD5,HMACSHA1,HMACSHA256,HMACSHA384,HMACSHA512): TextΔ BC24 + BC24 − BC27 + BC28: Generates keyed base64 encoded hash from provided string based on provided hash algorithm and base64 key.SignData(InputString: Text; XmlString: SecretText; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified string and signs it.SignData(InputString: SecretText; XmlString: SecretText; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified string and signs it.SignData(DataInStream: InStream; XmlString: SecretText; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified data and signs it.SignData(InputString: Text; SignatureKey: Codeunit "Signature Key"; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified string and signs it.SignData(InputString: SecretText; SignatureKey: Codeunit "Signature Key"; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified string and signs it.SignData(DataInStream: InStream; SignatureKey: Codeunit "Signature Key"; HashAlgorithm: Enum "Hash Algorithm"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified data and signs it.SignData(InputString: Text; XmlString: SecretText; HashAlgorithm: Enum "Hash Algorithm"; RSASignaturePadding: Enum "RSA Signature Padding"; SignatureOutStream: OutStream)Δ BC24 + BC24 Δ BC24 + BC24 + BC25 − BC27 − BC27 + BC28 + BC28: Computes the hash value of the specified string and signs it.VerifyData(InputString: Text; XmlString: Text; HashAlgorithm: Enum "Hash Algorithm"; SignatureInStream: InStream): Boolean+ BC28: Verifies that a digital signature is valid.VerifyData(DataInStream: InStream; XmlString: Text; HashAlgorithm: Enum "Hash Algorithm"; SignatureInStream: InStream): Boolean+ BC28: Verifies that a digital signature is valid.VerifyData(InputString: Text; SignatureKey: Codeunit "Signature Key"; HashAlgorithm: Enum "Hash Algorithm"; SignatureInStream: InStream): Boolean+ BC28: Verifies that a digital signature is valid.VerifyData(InputString: SecretText; XmlString: Text; HashAlgorithm: Enum "Hash Algorithm"; SignatureInStream: InStream): Boolean+ BC28: Verifies that a digital signature is valid.VerifyData(DataInStream: InStream; SignatureKey: Codeunit "Signature Key"; HashAlgorithm: Enum "Hash Algorithm"; SignatureInStream: InStream): Boolean+ BC28: Verifies that a digital signature is valid.
Calls
From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an Object::"Name" argument. Interface dispatch and calls through events are not counted, so the list is not complete.
- Codeunit 1279 “Cryptography Management Impl.” (13 calls:
Decrypt → Decrypt,DisableEncryption → DisableEncryption,EnableEncryption → EnableEncryption, …)
Called by
- Codeunit 1279 “Cryptography Management Impl.” (2 calls:
CreateEncryptionKeys → OnBeforeEnableEncryptionOnPrem,DisableEncryption → OnBeforeDisableEncryptionOnPrem) - Page 1263 “Certificate” (2 calls:
CheckEncryption → GetEncryptionIsNotActivatedQst,CheckEncryption → IsEncryptionEnabled) - Table 1853 “MS - Sales Forecast Setup” (2 calls:
EnableEncryption → EnableEncryption,EnableEncryption → IsEncryptionEnabled) - Table 843 “Cash Flow Setup” (2 calls:
EnableEncryption → EnableEncryption,EnableEncryption → IsEncryptionEnabled) - Codeunit 1140 “OAuth 2.0 Mgt.” (1 call:
GenerateCodeChallenge → GenerateHashAsBase64String) - Codeunit 1259 “Certificate Management” (1 call:
SavePasswordToIsolatedStorage → IsEncryptionEnabled) - Codeunit 3307 “Payables Agent Setup” (1 call:
GetInstructionsConfigHash → GenerateHash) - Codeunit 6989 “Expense Attachment Mgt.” (1 call:
UpdateContentHash → GenerateHash) - Codeunit 7297 “Mapping Cache Management” (1 call:
GenerateFileHashInHex → GenerateHash) - Codeunit 7333 “Search” (1 call:
SearchMultiple → GenerateHash) - Codeunit 8751 “DA External Storage Impl.” (1 call:
GetCurrentEnvironmentHash → GenerateHash) - Codeunit 9002 “Permission Manager” (1 call:
GenerateHashForPermissionSet → GenerateHash) - Codeunit 9060 “Auth. Format Helper” (1 call:
GetAccessKeyHashCode → GenerateBase64KeyedHashAsBase64String) - Codeunit 9510 “Document Service Management” (1 call:
InvokeDocumentSharingFlowFromMedia → GenerateHash)
Recent changes
- 2026-07-10 #9291 Add [NonDebuggable] to Cryptography Management encrypt/decrypt procedures (main, BC30, fix)
Ask your agent
Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: bcatlas_resolve_node(object_type: "codeunit", object_name: "Cryptography Management"), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.