ThingWorx Model Definition and Composer > Things > Thing Services > Encryption
  
Encryption
ThingWorx provides some out of the box encryption services and functions that you can use in your custom services. Encryption and decryption methods are not interchangeable because of the keys used for encryption or decryption; therefore, you must use the correct methods. The following table shows which encryption methods can be used with which decryption methods.
Encrypt/Decrypt API
Opposing Compatible API
EncryptionServices.Encrypt
EncryptionFunctions.encryptString
NONE
EncryptionServices.EncryptPropertyValue
EncryptionFunctions.encryptPropertyValue
None directly; however, you can use the following from the Extension SDK: BaseTypes.ConvertToPrimitive, PasswordPrimitive.convertFromObject, PasswordPrimitive.getDecryptedValue
EncryptionServices.EncryptWithKey
EncryptionServices.DecryptWithKey
EncryptionServices.DecryptWithKey
EncryptionServices.EncryptWithKey
EncryptionFunctions.encryptStringWithKey
EncryptionFunctions.decryptStringWithKey
EncryptionFunctions.decryptStringWithKey
EncryptionFunctions.encryptStringWithKey
EncryptionFunctions.base64EncodeString
EncryptionFunctions.base64DecodeString
EncryptionFunctions.base64DecodeString
EncryptionFunctions.base64EncodeString
EncryptionFunctions.base64EncodeBytes
EncryptionFunctions.base64DecodeBytes
EncryptionFunctions.base64DecodeBytes
EncryptionFunctions.base64EncodeBytes