Debian Codegraph @

debian/rust-vendor/openssl-src/openssl/include/crypto/x509_acert.h

raw
1 /*
2 * Copyright 2021-2024 The OpenSSL Project Authors. All Rights Reserved.
3 *
4 * Licensed under the Apache License 2.0 (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
8 */
9
10 #ifndef OSSL_CRYPTO_X509_ACERT_H
11 #define OSSL_CRYPTO_X509_ACERT_H
12 #pragma once
13
14 #include <openssl/x509_acert.h>
15
16 #define OSSL_ODI_TYPE_PUBLIC_KEY 0
17 #define OSSL_ODI_TYPE_PUBLIC_KEY_CERT 1
18 #define OSSL_ODI_TYPE_OTHER 2
19
20 struct ossl_object_digest_info_st {
21 ASN1_ENUMERATED digestedObjectType;
22 ASN1_OBJECT *otherObjectTypeID;
23 X509_ALGOR digestAlgorithm;
24 ASN1_BIT_STRING objectDigest;
25 };
26
27 struct ossl_issuer_serial_st {
28 STACK_OF(GENERAL_NAME) *issuer;
29 ASN1_INTEGER serial;
30 ASN1_BIT_STRING *issuerUID;
31 };
32
33 struct X509_acert_issuer_v2form_st {
34 STACK_OF(GENERAL_NAME) *issuerName;
35 OSSL_ISSUER_SERIAL *baseCertificateId;
36 OSSL_OBJECT_DIGEST_INFO *objectDigestInfo;
37 };
38
39 typedef struct X509_acert_issuer_st {
40 int type;
41 union {
42 STACK_OF(GENERAL_NAME) *v1Form;
43 X509_ACERT_ISSUER_V2FORM *v2Form;
44 } u;
45 } X509_ACERT_ISSUER;
46
47 typedef struct X509_holder_st {
48 OSSL_ISSUER_SERIAL *baseCertificateID;
49 STACK_OF(GENERAL_NAME) *entityName;
50 OSSL_OBJECT_DIGEST_INFO *objectDigestInfo;
51 } X509_HOLDER;
52
53 struct X509_acert_info_st {
54 ASN1_INTEGER version; /* default of v2 */
55 X509_HOLDER holder;
56 X509_ACERT_ISSUER issuer;
57 X509_ALGOR signature;
58 ASN1_INTEGER serialNumber;
59 X509_VAL validityPeriod;
60 STACK_OF(X509_ATTRIBUTE) *attributes;
61 ASN1_BIT_STRING *issuerUID;
62 X509_EXTENSIONS *extensions;
63 };
64
65 struct X509_acert_st {
66 X509_ACERT_INFO *acinfo;
67 X509_ALGOR sig_alg;
68 ASN1_BIT_STRING signature;
69 };
70 #endif