init commit

This commit is contained in:
2025-10-09 09:57:24 +09:00
commit 4d551bd74f
6636 changed files with 1218703 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
using Org.BouncyCastle.Asn1.X509;
using Org.BouncyCastle.Math;
using Org.BouncyCastle.Utilities;
using Org.BouncyCastle.X509.Store;
namespace Org.BouncyCastle.Cms;
public class OriginatorID : X509CertStoreSelector
{
public override int GetHashCode()
{
int num = Arrays.GetHashCode(base.SubjectKeyIdentifier);
BigInteger bigInteger = base.SerialNumber;
if (bigInteger != null)
{
num ^= bigInteger.GetHashCode();
}
X509Name x509Name = base.Issuer;
if (x509Name != null)
{
num ^= x509Name.GetHashCode();
}
return num;
}
public override bool Equals(object obj)
{
if (obj == this)
{
return false;
}
if (!(obj is OriginatorID originatorID))
{
return false;
}
if (Arrays.AreEqual(base.SubjectKeyIdentifier, originatorID.SubjectKeyIdentifier) && object.Equals(base.SerialNumber, originatorID.SerialNumber))
{
return X509CertStoreSelector.IssuersMatch(base.Issuer, originatorID.Issuer);
}
return false;
}
}