summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/x509/x509_internal.h
diff options
context:
space:
mode:
authorbeck <>2022-11-11 12:02:34 +0000
committerbeck <>2022-11-11 12:02:34 +0000
commitfadbfece8693f0ef4e461242a68e499a8580c324 (patch)
tree0a9a1c7b34e523947e5dbb8897374c8c5c2fec2d /src/lib/libcrypto/x509/x509_internal.h
parentfd62f2b8865d2908f2ef9a53dcd73faa76f153c3 (diff)
downloadopenbsd-fadbfece8693f0ef4e461242a68e499a8580c324.tar.gz
openbsd-fadbfece8693f0ef4e461242a68e499a8580c324.tar.bz2
openbsd-fadbfece8693f0ef4e461242a68e499a8580c324.zip
Start CBS-ifying the name constraints code.
ok jsing@ tb@
Diffstat (limited to 'src/lib/libcrypto/x509/x509_internal.h')
-rw-r--r--src/lib/libcrypto/x509/x509_internal.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/libcrypto/x509/x509_internal.h b/src/lib/libcrypto/x509/x509_internal.h
index 030f24c470..beafd365ed 100644
--- a/src/lib/libcrypto/x509/x509_internal.h
+++ b/src/lib/libcrypto/x509/x509_internal.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: x509_internal.h,v 1.19 2022/06/27 14:10:22 tb Exp $ */ 1/* $OpenBSD: x509_internal.h,v 1.20 2022/11/11 12:02:34 beck Exp $ */
2/* 2/*
3 * Copyright (c) 2020 Bob Beck <beck@openbsd.org> 3 * Copyright (c) 2020 Bob Beck <beck@openbsd.org>
4 * 4 *
@@ -22,6 +22,7 @@
22 22
23#include <openssl/x509_verify.h> 23#include <openssl/x509_verify.h>
24 24
25#include "bytestring.h"
25#include "x509_lcl.h" 26#include "x509_lcl.h"
26 27
27/* Hard limits on structure size and number of signature checks. */ 28/* Hard limits on structure size and number of signature checks. */
@@ -111,14 +112,13 @@ struct x509_constraints_names *x509_constraints_names_new(size_t names_max);
111int x509_constraints_general_to_bytes(GENERAL_NAME *name, uint8_t **bytes, 112int x509_constraints_general_to_bytes(GENERAL_NAME *name, uint8_t **bytes,
112 size_t *len); 113 size_t *len);
113void x509_constraints_names_free(struct x509_constraints_names *names); 114void x509_constraints_names_free(struct x509_constraints_names *names);
114int x509_constraints_valid_host(uint8_t *name, size_t len); 115int x509_constraints_valid_host(CBS *cbs);
115int x509_constraints_valid_sandns(uint8_t *name, size_t len); 116int x509_constraints_valid_sandns(CBS *cbs);
116int x509_constraints_domain(char *domain, size_t dlen, char *constraint, 117int x509_constraints_domain(char *domain, size_t dlen, char *constraint,
117 size_t len); 118 size_t len);
118int x509_constraints_parse_mailbox(uint8_t *candidate, size_t len, 119int x509_constraints_parse_mailbox(CBS *candidate,
119 struct x509_constraints_name *name); 120 struct x509_constraints_name *name);
120int x509_constraints_valid_domain_constraint(uint8_t *constraint, 121int x509_constraints_valid_domain_constraint(CBS *cbs);
121 size_t len);
122int x509_constraints_uri_host(uint8_t *uri, size_t len, char **hostp); 122int x509_constraints_uri_host(uint8_t *uri, size_t len, char **hostp);
123int x509_constraints_uri(uint8_t *uri, size_t ulen, uint8_t *constraint, 123int x509_constraints_uri(uint8_t *uri, size_t ulen, uint8_t *constraint,
124 size_t len, int *error); 124 size_t len, int *error);