You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 21, 2023. It is now read-only.
It looks great! I'm not sure why Microsoft hasn't supported it in their fork, but I think Always Encrypted is a great security feature.
I've been trying to get the PR and this external mssql-always-encrypted lib to work in my repos. I am wondering if you came across an error with pkcs12: unknown digest algorithm when trying to use the PFX certs.
Here's what I have checked so far.
I can read the PFX keystore w/ password. When I have a user that doesn't match it gives me the correct error about wrong cert.
error while scanning | invalid certificate being used to decrypt: currentuser/my/05c365ad6afaf88c598d85a5f137951e04c0906b requested but db5da876586e9949c0ac5fa5e772e24adbaac0e9 provided
When I use the correct user and the key is in the PFX file, it gives me this error:
error while running query | pkcs12: unknown digest algorithm: 2.16.840.1.101.3.4.2.1
Sadly I'm not propagating the error from this method (sorry!) and thus you can't see why the verification fails.
I checked the PFX file and able to read it with openssl, extract the key and certs. And since I know #1 is not an issue, it seems to be with what the algo.
Hi @denysvitali
I followed your PR from the go-mssqldb project
denisenkom/go-mssqldb#637
It looks great! I'm not sure why Microsoft hasn't supported it in their fork, but I think Always Encrypted is a great security feature.
I've been trying to get the PR and this external mssql-always-encrypted lib to work in my repos. I am wondering if you came across an error with
pkcs12: unknown digest algorithm
when trying to use the PFX certs.Here's what I have checked so far.
I checked the PFX file and able to read it with openssl, extract the key and certs. And since I know pkcs12: unknown digest algorithm: 2.16.840.1.101.3.4.2.1 #1 is not an issue, it seems to be with what the algo.
Googling around I found that that OID maps to a SHA-256 Message Digest. Does the PFX file have to be created from the SQL Server in a specific format?
The current algo to encrypt on our end is the standard:
AEAD_AES_256_CBC_HMAC_SHA_256
This looks similar to what is supported by the msqql-always-encrypted library. https://github.com/swisscom/mssql-always-encrypted/tree/master/pkg/algorithms
Any help you can provide would be greatly appreciated.
Thanks so much for your contributions.
The text was updated successfully, but these errors were encountered: