Skip to main content

Questions tagged [dpapi]

DPAPI is the API in Windows that allows a program to store "secrets", like passwords. It is used by Microsoft in IE and storing WiFi passwords and private keys for EFS, and also by Chrome for Windows and Safari for Windows, to store website credentials.

0 votes
1 answer
361 views

Decrypt & Re-Encrypt Chrome cookies

I'm trying to decrypt Chrome's cookie SQLite DB, and move the decrypted cookies to another computer (browser), and re-encrypt the DB, and replicate sessions. Here is what I plan: Decrypt AES key from ...
TaihouKai's user avatar
  • 301
0 votes
1 answer
66 views

How can my web api decrypt a password, that was prevously encrypted in a console application, using DPAPI?

I have to store user credentials in a web api somewhere. I decided I create a console application in the solution, next to the Web API, that encrypts the data, and writes it to the web api's ...
dezox's user avatar
  • 179
0 votes
0 answers
56 views

Access violation reading location : CryptProtectData

I'm trying to call CryptProtectData from the Data Protection API (DPAPI): DATA_BLOB dataIn; DATA_BLOB dataEncrypted; BYTE *phrase = (BYTE *)plain.c_str(); DWORD length = strlen((char *)phrase) + 1; ...
Gokul's user avatar
  • 1
0 votes
0 answers
41 views

How to use CryptUnprotectData to decrypt data encrypted by other users

I want to decrypt the wireless network password, it's in the of the xml file, how can I decrypt it in another user environment in the same computer. Sorry for my bad English. I have implemented ...
orange's user avatar
  • 1
2 votes
0 answers
166 views

Using Services.AddAuthentication() causes application to stop on startup

In a basic Asp Net Core web API project ( dotnet new webapi, SDK 7.0 ) adding an authentication handler via builder.Services.AddAuthentication() .AddScheme<AuthenticationSchemeOptions, ...
Pietro di Caprio's user avatar
0 votes
1 answer
190 views

Decrypting Data with CryptUnprotectData in Rust Leads to STATUS_HEAP_CORRUPTION Error

I'm working on a Rust function that receives a &[u8] and decrypts it using CryptUnprotectData from the WinAPI. Here's the function in question: fn decrypt(data: &[u8]) -> Result<Vec<...
anonymous's user avatar
0 votes
1 answer
366 views

Powershell Base64 Decode to bytes hex

i'm trying to get the hex binary (\x**) of a base64 decode result from the Local State of chrome. When i decode the base64 of my encrypted key using [System.Convert]::FromBase64String($local_state....
Dapkz's user avatar
  • 13
0 votes
2 answers
74 views

I am trying to compare two strings but they are only different when I run repr on them in python3

I have two strings in python stored in variables a and b. a is an argument passed to the script and b is the result from decoding the result of win32crypt. I've finally used repr to compare them and ...
Dihmz's user avatar
  • 1
0 votes
1 answer
459 views

Calling CryptProtectData in Python, then Calling CryptUnprotectData in C++ returns error 87 (and visa versa)

Using Python 3.11.0 and C++ in Unreal Engine 5.1 I'm encrypting user input using DPAPI in Python (3.11.0), and decrypting it through C++ (UE 5.1), but I get error 87 (which i think is a invalid ...
MashedPotato6587's user avatar
2 votes
1 answer
788 views

Protecting encryption key with TPM when using DPAPI

DPAPI on Windows provides functions to encrypt and decrypt arbitrary data. Functions provided by DPAPI include CryptProtectMemory, CryptUnprotectMemory, CryptProtectData and CryptUnprotectData. I ...
MartinS's user avatar
  • 21
0 votes
0 answers
35 views

Decrypt cookies from Google Chrome [duplicate]

Hello I hope you can help me, I am trying to decrypt Google Chrome cookies, I know that they are in a Cookies file and that in version 80, I need to get a key of the Local State file. My code is as ...
David's user avatar
  • 33
0 votes
0 answers
75 views

Using DPAPI in unreal to encrypt and decrypt user input, but the decryption doesn't match the original input

I'm prompting the user for input (a security token in this case). Then I'm encrypting it using DPAPI, and storing it in a text file for later use. The issue I'm having is that when I decrypt the file, ...
MashedPotato6587's user avatar
0 votes
1 answer
101 views

Using CryptDataProtect to output encrypted password for use in RDP file generates the incorrect hash

I am trying to generate an RDP file in C++ to automatically log on to a remote machine. I am using the CryptProtectData function to generate an encrypted string which can then be written to the ...
PenguinKenny's user avatar
1 vote
1 answer
776 views

How can I decrypt a string using CryptUnprotectData

I have been trying to decrypt some encrypted data (AES key encrypting chrome cookies) via the c++ CryptUnprotectData function for a short while now, but I cant seem to get it working. Currently the ...
rando314's user avatar
0 votes
1 answer
1k views

Windows 11 - Windows Data Protection API (DPAPI) not supported

ProtectedData.Protect gives me the error "Windows Data Protection API (DPAPI) is not supported on this platform". Using Visual Studio 2022, .Net 5.0, C# console application, and Windows 11. ...
Meneghini's user avatar
  • 187

15 30 50 per page
1
2 3 4 5
11