Package com.thingworx.resources.admin
Class EncryptionServices
- java.lang.Object
-
- All Implemented Interfaces:
IConfigurableObject
,INotScriptFriendly
,ISupportsDeprecation
,IDiffableObject
,IAvatar
,IEntityLifeCycleEvent
,IPersistable
,IServiceProvider
,ITaggableObject
,IDependencyScannableObject
,IEntityDefinition
,IPersistableObject<java.lang.String>
,IDesignTimeSecurable
,IDesignTimeSecurableEntity
,IRunTimeSecurable
,IRunTimeSecurableEntity
,ISecurable
,IVisibilitySecurable
,IVisibilitySecurableEntity
,IAspectContainer
,INamedObject
,java.io.Serializable
@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public class EncryptionServices extends Resource
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.thingworx.entities.RootEntity
BASIC_PROPERTY_DEFINITIONS, EXCLUDED_ENTITY_TYPES_IN_PROJECT
-
Fields inherited from class com.thingworx.types.NamedObject
NAME_COMPARATOR
-
-
Constructor Summary
Constructors Constructor Description EncryptionServices()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.String
DecryptWithCustomKey(java.lang.String key, java.lang.String encryptedData)
Service Category: Encryption Service Description: Returns decrypted data using the Base64 encoded key with valid sizes; 128, 192 or 256 bits.java.lang.String
DecryptWithKey(java.lang.String key, java.lang.String data)
Deprecated.UseDecryptWithCustomKey(String, String)
instead.java.lang.String
Encrypt(java.lang.String data)
Service Category: Encryption Service Description: Returns an encrypted password.java.lang.String
EncryptPropertyValue(java.lang.String data)
Service Category: Encryption Service Description: Returns an encrypted property value.java.lang.String
EncryptWithCustomKey(java.lang.String key, java.lang.String data)
Service Category: Encryption Service Description: Returns an encrypted string using a Base64 encoded key with AES 128 supported key lengths; 128, 192 or 256 bits.java.lang.String
EncryptWithKey(java.lang.String key, java.lang.String data)
Deprecated.UseEncryptWithCustomKey(String, String)
instead.java.lang.String
GenerateKey(java.lang.Integer size)
Service Category: Encryption Service Description: Returns a Base64 encoded AES encryption key.-
Methods inherited from class com.thingworx.resources.Resource
getEntityType
-
Methods inherited from class com.thingworx.entities.ServiceProviderEntity
getInstancePublicServiceDefinitions, getInstanceServiceDefinition, getInstanceServiceDefinitions, initializeEntity, preInitializeEntity, processAPIServiceRequest, processServiceRequest
-
Methods inherited from class com.thingworx.entities.RootEntity
AddConfigurationTableDefinition, AddConfigurationTableDefinition, addDesignTimePermission, AddDesignTimePermission, addRunTimePermission, AddRunTimePermission, AddTags, addVisibilityPermission, AddVisibilityPermission, CheckDesignTimePermission, CheckDesignTimePermissionForGroup, CheckDesignTimePermissionForUser, CheckPermission, CheckPermissionForGroup, CheckPermissionForUser, cleanupEntity, DeleteAllConfigurationTableRows, DeleteConfigurationTable, DeleteConfigurationTableRows, DeleteConfigurationTableRows, deleteDesignTimePermission, DeleteDesignTimePermission, deleteRunTimePermission, DeleteRunTimePermission, deleteVisibilityPermission, DeleteVisibilityPermission, dispose, getAspects, GetAvatar, getAvatarContent, GetAvatarURL, GetConfigurationChangeHistory, getConfigurationSetting, getConfigurationTable, GetConfigurationTable, GetConfigurationTableDefinition, GetConfigurationTableRow, GetConfigurationTables, GetDescription, getDesignTimePermissions, GetDesignTimePermissions, GetDesignTimePermissionsAsJSON, getDocumentationContent, getEntityTypeAsString, GetEventDefinition, GetEventDefinitions, GetHomeMashup, GetIncomingDependencies, GetIncomingDependenciesAsNetwork, GetInstanceMetadataAsJSON, GetInstanceMetadataWithPermissionsAsJSON, GetLastModifiedDate, GetMetadata, GetMetadataAsJSON, GetMetadataWithPermissionsAsJSON, GetOutgoingDependencies, GetOutgoingDependenciesAsNetwork, getOwner, GetOwner, GetPermissionsForCurrentUser, GetPermissionsForGroup, GetPermissionsForUser, GetProjectName, GetPropertyDefinition, GetPropertyDefinitions, getRunTimePermissions, GetRunTimePermissions, GetRunTimePermissionsAsJSON, GetServiceDefinition, GetServiceDefinitions, getStringConfigurationSetting, getStringConfigurationSettingWithDefault, GetSummaryInformation, getTags, GetTags, GetTagsAsInfoTable, getVisibilityPermissions, GetVisibilityPermissions, GetVisibilityPermissionsAsJSON, HasIncomingDependencies, HasOutgoingDependencies, isEditable, isEditableExtensionObject, isEditableSystemObject, isExtensionObject, IsMultiRowTable, isOwner, isSystemObject, isThemeObject, isVisible, isVisible, ListDeprecatedUsage, persistDesignTimePermissions, persistRunTimePermissions, persistVisibilityPermissions, RemoveTags, SaveConfigurationTables, SetAvatar, setConfigurationSetting, SetConfigurationTable, SetConfigurationTableRows, SetDescription, setDesignTimePermissions, SetDesignTimePermissionsAsJSON, setDocumentationContent, setExtensionObject, SetHomeMashup, setLastModifiedDate, SetMultiRowConfigurationTable, setOwner, SetOwner, SetProjectName, setRunTimePermissions, SetRunTimePermissionsAsJSON, setStringConfigurationSetting, SetTags, setVisibilityPermissions, SetVisibilityPermissionsAsJSON, toJSON, toJSONDefinition, UpdateProjectDependencies, validateConfiguration
-
Methods inherited from class com.thingworx.persistence.common.PersistableNamedObject
getID, hasID, isTransient
-
Methods inherited from class com.thingworx.types.NamedObject
getDescription, getName, setDescription, setName, toValueCollection
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.thingworx.types.INamedObject
getDescription, getName
-
Methods inherited from interface com.thingworx.entities.interfaces.IPersistable
getID, hasID
-
Methods inherited from interface com.thingworx.security.permissions.ISecurable
getID, getName
-
Methods inherited from interface com.thingworx.deprecation.ISupportsDeprecation
getDeprecated, isDeprecated, isDeprecatedBefore, since
-
-
-
-
Method Detail
-
Encrypt
@ThingworxExtensionApiMethod(since={6,6}) public java.lang.String Encrypt(java.lang.String data) throws java.lang.Exception
- Service Category:
- Encryption
- Service Description:
- Returns an encrypted password.
- Parameters:
data
- Data to encrypt - STRING- Returns:
- result Encrypted data - STRING
- Throws:
java.lang.Exception
- If an error occurs
-
EncryptPropertyValue
@ThingworxExtensionApiMethod(since={6,6}) public java.lang.String EncryptPropertyValue(java.lang.String data) throws java.lang.Exception
- Service Category:
- Encryption
- Service Description:
- Returns an encrypted property value.
- Parameters:
data
- Data to encrypt - STRING- Returns:
- result Encrypted data - STRING
- Throws:
java.lang.Exception
- If an error occurs
-
EncryptWithKey
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,3}) public java.lang.String EncryptWithKey(java.lang.String key, java.lang.String data) throws java.lang.Exception
Deprecated.UseEncryptWithCustomKey(String, String)
instead.- Service Category:
- Encryption
- Service Description:
- Returns an encrypted string using a specified key. This service is deprecated since release 8.3. Please use EncryptWithCustomKey service instead.
Returns an encrypted string using a specified key, which is a 56 hex characters string.- Parameters:
key
- Encryption key to use (56 hex characters)data
- Data to encrypt- Returns:
- Returns an encrypted string using a specified key
- Throws:
java.lang.Exception
- emit errors
-
DecryptWithKey
@Deprecated @ThingworxExtensionApiMethod(since={6,6}, deprecatedSince={8,3}) public java.lang.String DecryptWithKey(java.lang.String key, java.lang.String data) throws java.lang.Exception
Deprecated.UseDecryptWithCustomKey(String, String)
instead.- Service Category:
- Encryption
- Service Description:
- Returns an decrypted string using a specified key. This service is deprecated since release 8.3. Please use DecryptWithCustomKey service instead.
Returns an decrypted string using a specified key, which is a 56 hex characters string.- Parameters:
key
- Encryption key to use (56 hex characters)data
- Data to decrypt- Returns:
- Returns an decrypted string using a specified key
- Throws:
java.lang.Exception
- emit errors
-
GenerateKey
@ThingworxExtensionApiMethod(since={8,3}) public java.lang.String GenerateKey(java.lang.Integer size) throws java.lang.Exception
- Service Category:
- Encryption
- Service Description:
- Returns a Base64 encoded AES encryption key. Supports AES key sizes, i.e. 128, 192 or 256 bits.
- Parameters:
size
- Size of the key to be generated in bits. Supported key sizes are 128, 192 and 256 bits - INTEGER- Returns:
- key Base64 encoded key - STRING
- Throws:
java.lang.Exception
- If an error occurs
-
EncryptWithCustomKey
@ThingworxExtensionApiMethod(since={8,3}) public java.lang.String EncryptWithCustomKey(java.lang.String key, java.lang.String data) throws java.lang.Exception
- Service Category:
- Encryption
- Service Description:
- Returns an encrypted string using a Base64 encoded key with AES 128 supported key lengths; 128, 192 or 256 bits.
- Parameters:
key
- Based64 encoded key with key size of 128, 192 or 256 bits - STRINGdata
- Plain text data to encrypt - STRING- Returns:
- result Encrypted data - STRING
- Throws:
java.lang.Exception
- If an error occurs
-
DecryptWithCustomKey
@ThingworxExtensionApiMethod(since={8,3}) public java.lang.String DecryptWithCustomKey(java.lang.String key, java.lang.String encryptedData) throws java.lang.Exception
- Service Category:
- Encryption
- Service Description:
- Returns decrypted data using the Base64 encoded key with valid sizes; 128, 192 or 256 bits.
- Parameters:
key
- Based64 encoded key with sizes of 128, 192 or 256 bits - STRINGencryptedData
- Data encrypted using Thingworx EncryptWithCustomKey service - STRING- Returns:
- result Decrypted data - STRING
- Throws:
java.lang.Exception
- If an error occurs
-
-