Sha256: d8ec9e239113b3112b0a46065d920d5f50dcb2b083f9d94e342ee62ae40ecff7

Contents?: true

Size: 1.87 KB

Versions: 76

Compression:

Stored size: 1.87 KB

Contents

/*
 * Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
 *
 * Licensed under the OpenSSL license (the "License").  You may not use
 * this file except in compliance with the License.  You can obtain a copy
 * in the file LICENSE in the source distribution or at
 * https://www.openssl.org/source/license.html
 */

#include <openssl/x509v3.h>

#include <openssl/asn1.h>
#include <openssl/bio.h>
#include <openssl/nid.h>

/*
 * OCSP extensions and a couple of CRL entry extensions
 */

static int i2r_ocsp_acutoff(const X509V3_EXT_METHOD *method, void *nonce,
                            BIO *out, int indent);

static int i2r_ocsp_nocheck(const X509V3_EXT_METHOD *method,
                            void *nocheck, BIO *out, int indent);
static void *s2i_ocsp_nocheck(const X509V3_EXT_METHOD *method,
                              X509V3_CTX *ctx, const char *str);

const X509V3_EXT_METHOD v3_crl_invdate = {
    NID_invalidity_date, 0, ASN1_ITEM_ref(ASN1_GENERALIZEDTIME),
    0, 0, 0, 0,
    0, 0,
    0, 0,
    i2r_ocsp_acutoff, 0,
    NULL
};

const X509V3_EXT_METHOD v3_ocsp_nocheck = {
    NID_id_pkix_OCSP_noCheck, 0, ASN1_ITEM_ref(ASN1_NULL),
    0, 0, 0, 0,
    0, s2i_ocsp_nocheck,
    0, 0,
    i2r_ocsp_nocheck, 0,
    NULL
};

static int i2r_ocsp_acutoff(const X509V3_EXT_METHOD *method, void *cutoff,
                            BIO *bp, int ind)
{
    if (BIO_printf(bp, "%*s", ind, "") <= 0)
        return 0;
    if (!ASN1_GENERALIZEDTIME_print(bp, cutoff))
        return 0;
    return 1;
}

/* Nocheck is just a single NULL. Don't print anything and always set it */

static int i2r_ocsp_nocheck(const X509V3_EXT_METHOD *method, void *nocheck,
                            BIO *out, int indent)
{
    return 1;
}

static void *s2i_ocsp_nocheck(const X509V3_EXT_METHOD *method,
                              X509V3_CTX *ctx, const char *str)
{
    return ASN1_NULL_new();
}

Version data entries

76 entries across 76 versions & 4 rubygems

Version Path
grpc-1.53.2 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
rubypitaya-3.12.5 ./lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/grpc-1.50.0-x86_64-linux/third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.53.1 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.52.2 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.53.0 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.53.0.pre2 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.52.0 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
rubypitaya-3.12.4 ./lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/grpc-1.50.0-x86_64-linux/third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.51.0-x86_64-linux third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.51.0 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.52.0.pre2 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
rubypitaya-3.12.3 ./lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/grpc-1.50.0-x86_64-linux/third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
rubypitaya-3.12.2 ./lib/rubypitaya/app-template/vendor/bundle/ruby/3.1.0/gems/grpc-1.50.0-x86_64-linux/third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.50.0 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.50.0-x86_64-linux third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.50.0.pre1 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.50.0.pre1-x86_64-linux third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.49.1 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.49.1-x86_64-linux third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c
grpc-1.49.0.pre1 third_party/boringssl-with-bazel/src/crypto/x509v3/v3_ocsp.c