alien Posted February 6, 2012 Report Share Posted February 6, 2012 (edited) As some of you requested, I've added a class to decrypt passwords found in *.rdp files. To work with this class add the DLL to references, include the namespace in you're class "using DataProtection;" and use the two functions provided by DataProtectionWrapper: Encrypt(string) and Decrypt(string)The repository can be found here:hg clone https://bitbucket.org/rokill3r/rdppassworddecrypterDLL can be found here: DataProtection.dllusing System;using System.Collections.Generic;using System.Linq;using System.Text;using DataProtection;namespace RdpPasswordDecrypter{ class Program { static void Main(string[] args) { try { string password = "01000000D08C9DDF0115D1118C7A00C04FC297EB01000000B03D76F7FF29E741AC1991D9E850476500000000080000007000730077000000106600000001000020000000DA8BB4AC41DE92695BF32E8F756F6C7EA1A7D939EE98C99D79740DF7A5DD66B7000000000E8000000002000020000000C1CF8B672062B84AC36624E43D316383B6ADB08D026A9A1C5DF78162C04D421820000000D94E470B71E687C0A4DF24E2800983C7071AAC55B0122FCD8AD7F490F932899B4000000024356DC7D805EEF60CEEB2F3D0D9232CD488C0C2882950B7CE10810480E61997307B6C1DC95C263033178F4272458BA6CCAF8F84487F61677A5A291265582964"; Console.WriteLine("Decrypting ..."); Console.WriteLine("Password: " + DataProtectionWrapper.Decrypt(password)); } catch (Exception ex) { Console.WriteLine(ex.Message); } } }}Log output:Decrypting ...Password: rstcenter.comPress any key to continue . . .Alien Edited February 6, 2012 by alien Quote Link to comment Share on other sites More sharing options...
cmiN Posted February 7, 2012 Report Share Posted February 7, 2012 Si sursa lui DataProtection ? Quote Link to comment Share on other sites More sharing options...
alien Posted February 7, 2012 Author Report Share Posted February 7, 2012 @cmiN: Am pus pe repository si DataProtection Quote Link to comment Share on other sites More sharing options...
darkston3e Posted February 9, 2012 Report Share Posted February 9, 2012 Frumos, frumos ! Felicitarile melenamespace DataProtection{ public class DataProtector { [DllImport("Crypt32.dll", SetLastError = true, CharSet = System.Runtime.InteropServices.CharSet.Auto)] private static extern bool CryptProtectData( ref DATA_BLOB pDataIn, String szDataDescr, ref DATA_BLOB pOptionalEntropy, IntPtr pvReserved, ref CRYPTPROTECT_PROMPTSTRUCT pPromptStruct, int dwFlags, ref DATA_BLOB pDataOut); [DllImport("Crypt32.dll", SetLastError = true, CharSet = System.Runtime.InteropServices.CharSet.Auto)] private static extern bool CryptUnprotectData( Quote Link to comment Share on other sites More sharing options...
jesuli Posted October 21, 2012 Report Share Posted October 21, 2012 Olá é o programa funciona bem para a figura e descrito com DPAPI, entretanto falha ao tentar decifrar a senha armazenada nos perfis das redes Windows wifi.Existe alguma maneira de decifrar a senha armazenada em redes xml perfis do Windows com C#Hello is program works well for figure and described with DPAPI, however fails when I try to decrypt the password stored in the profiles of the Windows wifi networks.Is there any way to decrypt the password stored in xml networking profiles Windows with C# Quote Link to comment Share on other sites More sharing options...