-
Notifications
You must be signed in to change notification settings - Fork 0
StoreSecureString.cs
Avrigeanu Laurian edited this page Apr 14, 2023
·
1 revision
-
name
(string): The name to store the secure string under. -
value
(SecureString): The secure string to be stored.
-
void
: This method does not return any value.
- This method encrypts the given
SecureString
object using theProtectedData
class, and stores the resulting encrypted byte array in a MySQL database table namedassets
. The name of the secure string is also stored in the table for later retrieval. - If an entry with the same
name
already exists in the table, an exception will be thrown with the message "Entry with the same Name already exists." - The
Connection
property of theOrchestrator
class should be set prior to calling this method. - After calling this method, the
SecureString
object passed as a parameter should be disposed of to clear its contents from memory.