Search results for query: *

  • Users: TyMac
  • Order by date
  1. T

    declare on secure strings

    Yes: static class Extensions { public static SecureString DecryptString(this string source) { if (source == null) return null; SecureString result = new SecureString(); try { var decrypted = ProtectedData.Unprotect(Convert.FromBase64String(source), entropy...
  2. T

    declare on secure strings

    Well I can tell you that I'm doing it wrong here: namespace DecryptStrg { class Program { static void Main(string[] args) { FileInfo file = new FileInfo("C:\\path\to\\password\\file\\here\\textfile.txt"); if (!file.Exists) {...
  3. T

    declare on secure strings

    I need to declare a secure string a variable that is located in a text file. In Powershell this is easy: $password = Get-content "C:\text_file_with_secure_string_in_it.txt" | convertto-securestring How would I declare this variable correctly in C#?
  4. T

    Question debugging a simple test console app.

    Sorry about that - here it is: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using VMware.Vim; namespace vmwaretest { class Program { static void Main(string[] args) { VimClient c = new...
  5. T

    Question debugging a simple test console app.

    I found a simple test template on the web to get started learning C# / .NET but I have run in to a few errors when I try to execute the program. "An unhandled exception of type 'System.UriFormatException' occurred in System.dll Additional information: Invalid URI: The format of the URI could...
Back
Top Bottom