dpapi

Chrome 80 how to decode cookies

和自甴很熟 提交于 2020-04-28 20:42:21
问题 I had a working script for opening and decrypting Google Chrome cookies which looked like: decrypted = win32crypt.CryptUnprotectData(enctypted_cookie_value, None, None, None, 0) It seems that after update 80 it is no longer a valid solution. According to this blog post https://blog.nirsoft.net/2020/02/19/tools-update-new-encryption-chrome-chromium-version-80/ it seems that i need to CryptUnprotectData on encrypted_key from Local State file, than somehow decrypt cookie, using decrypted key.

DPAPI fails with CryptographicException when trying to decrypt Chrome cookies

时光总嘲笑我的痴心妄想 提交于 2020-02-27 13:00:39
问题 i am trying to get session from my Chrome browser. i can see 2 cookie files in Developer Tools. but this is inconvenient for the user to get cookie values from browser, i would like to do it in code. so i use this code to get Chrome default profile cookie sqlite DB: string local = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData); string path = @"Google\Chrome\User Data\Default\Cookies"; path = Path.Combine(local, path); next i create SQLite connection and request var

Storing sensitive data that is encrypted using Data Protection API with PersistKeysToFileSystem

白昼怎懂夜的黑 提交于 2020-01-16 19:41:32
问题 Folks, I need to encrypt some string data into a SQL database from and MVC Core 2.0 application. I'm thinking of using the Data Protection API with PersistKeysToFileSystem so that I can restore the data to another server and decrypt the data using the same key file. I am impressed with the performance of the DPAPI in Net core and I don't want to fo for any custom crypto solution as its too risky. I would be storing bulk uploads of data to SQL. Strings before encryption would be 200 chars or

Using DPAPI with Python?

大兔子大兔子 提交于 2019-12-29 03:38:05
问题 Is there a way to use the DPAPI (Data Protection Application Programming Interface) on Windows XP with Python? I would prefer to use an existing module if there is one that can do it. Unfortunately I haven't been able to find a way with Google or Stack Overflow. EDIT: I've taken the example code pointed to by "dF" and tweaked it into a standalone library which can be simply used at a high level to crypt and decrypt using DPAPI in user mode. Simply call dpapi.cryptData(text_to_encrypt) which

Decrypt Data which was encrypted with MS DPAPI with JNA

ⅰ亾dé卋堺 提交于 2019-12-25 07:07:12
问题 is it possible to decrypt data which was encrypted with MS DPAPI? For example i want to decrypt a digital certificate from the windows registry. byte[] byteArray = (byte[]) Advapi32Util.registryGetValue(WinReg.HKEY_LOCAL_MACHINE, "SOFTWARE\\Microsoft\\SystemCertificates\\AuthRoot\\Certificates\\02FAF3E291435468607857694DF5E45B68851868", "Blob"); byte[] decrypted = Crypt32Util.cryptUnprotectData(byteArray); String stringDecrypted = new String(decrypted); System.out.println(stringDecrypted);

Can I use DPAPI (or something like it) in VBA?

烈酒焚心 提交于 2019-12-24 02:57:14
问题 another in my beginnerish series of questions about VBA. I am in the process of writing an Excel add-in in VBA, and the add-in uses a local configuration file. This file needs to contain a password for a remote service. Obviously, it is less than ideal to store this password as plaintext. But I am looking for an algorithm that can encode/decode text so it at least doesn't look like plaintext in the configuration file. I came across a reference to Windows DPAPI but I'm not sure whether this is

Can I use DPAPI (or something like it) in VBA?

Deadly 提交于 2019-12-24 02:56:28
问题 another in my beginnerish series of questions about VBA. I am in the process of writing an Excel add-in in VBA, and the add-in uses a local configuration file. This file needs to contain a password for a remote service. Obviously, it is less than ideal to store this password as plaintext. But I am looking for an algorithm that can encode/decode text so it at least doesn't look like plaintext in the configuration file. I came across a reference to Windows DPAPI but I'm not sure whether this is

CryptographicException - Unable to update the password

喜你入骨 提交于 2019-12-21 21:43:07
问题 I have some data I wish to protect, so I am using ProtectedData to encrypt it onto a file. When I am attempting to read and decrypt the data I am getting the strangest exception: CryptographicException - Unable to update the password. The value provided for the new password does not not meet the length, complexity, or history requirements of the domain. This is where it is thrown: byte[] decryptedData = ProtectedData.Unprotect(Encoding.UTF8.GetBytes(fileContent), Encoding.UTF8.GetBytes

information on Data Protection API (DPAPI)

谁都会走 提交于 2019-12-17 20:57:32
问题 I am currently writing a c# mvc web application in which password are being taken from a user and stored in a database - sql server. I need a way of hashing the passwords. It has been recommended to be to use the Data Protection API (DPAPI). I am not familliar with it and from research on the internet, very little information exists on it. Can anyone point in the direction for further information on it? OR give me an overview of how to set it up and work with it etc. 回答1: The Data Protection

Do I need to store key for CryptUnprotectData and CryptProtectData?

梦想与她 提交于 2019-12-13 02:10:01
问题 DPAPI has 2 functions: CryptUnprotectData and CryptProtectData . I read They do the encryption or decryption by using a session key that the function creates by using the user's logon credentials. Does that mean that I do not need store this key anywhere and they will created when I want encrypt or decrypt data? Also I found An important point to remember is that DPAPI merely applies cryptographic protection to the data. It does not store any of the protected data; therefore applications