vslepakov / keyvault-ca Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
Hi sir,
I am working on a 802.1AR root CA project which will be based on Azure key vault. By accident I came across this project and went through the project with a limited knowledge of Azure key vault and dotnet.
I roughly understand how a self-signed root CA is created in the project:
I am wondering how the two certificates ( the temporary self-signed certificate in step 1 and the self-signed root CA certificate in step2) have the same key pairs? Do I miss some point in the use of Azure key vault?
thanks
Tim
Hi Sir,
Once again thank you for the amazing project, which has already lightened the path I should go with my project.
I have a question about the C# code. Sorry for my limited knowledge of .net and C#.
The code snippet below encodes an OID to a byte array. I could not get the encoding method. if I have an oid=1.2.840.10045.4.3.2 (ecdsa-with-sha256), what will be the encoded value--oidSequence?
Thanks!
Tim
public override byte[] GetSignatureAlgorithmIdentifier(HashAlgorithmName hashAlgorithm)
{
byte[] oidSequence;
if (hashAlgorithm == HashAlgorithmName.SHA256)
{
//const string RsaPkcs1Sha256 = "1.2.840.113549.1.1.11";
oidSequence = new byte[] { 48, 13, 6, 9, 42, 134, 72, 134, 247, 13, 1, 1, 11, 5, 0 };
}
else if (hashAlgorithm == HashAlgorithmName.SHA384)
{
//const string RsaPkcs1Sha384 = "1.2.840.113549.1.1.12";
oidSequence = new byte[] { 48, 13, 6, 9, 42, 134, 72, 134, 247, 13, 1, 1, 12, 5, 0 };
}
else if (hashAlgorithm == HashAlgorithmName.SHA512)
{
//const string RsaPkcs1Sha512 = "1.2.840.113549.1.1.13";
oidSequence = new byte[] { 48, 13, 6, 9, 42, 134, 72, 134, 247, 13, 1, 1, 13, 5, 0 };
}
else
{
throw new ArgumentOutOfRangeException(nameof(hashAlgorithm), "The hash algorithm " + hashAlgorithm.Name + " is not supported.");
}
return oidSequence;
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.