From 49ff7c051c516a8d190b62787dc46f76275da66a Mon Sep 17 00:00:00 2001 From: kenjiro <> Date: Fri, 31 Jul 2026 03:59:50 +0000 Subject: Make file-local functions static These functions are only used within their implementation files and do not need external linkage. Mark them static. ok tb --- src/lib/libssl/s3_lib.c | 6 +++--- src/lib/libssl/ssl_tlsext.c | 4 ++-- src/lib/libssl/tls13_record_layer.c | 8 ++++---- src/lib/libssl/tls13_server.c | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) (limited to 'src/lib/libssl') diff --git a/src/lib/libssl/s3_lib.c b/src/lib/libssl/s3_lib.c index df45df47fc..929de03a3d 100644 --- a/src/lib/libssl/s3_lib.c +++ b/src/lib/libssl/s3_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: s3_lib.c,v 1.260 2026/06/06 15:22:25 jsing Exp $ */ +/* $OpenBSD: s3_lib.c,v 1.261 2026/07/31 03:59:50 kenjiro Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -1379,7 +1379,7 @@ ssl3_clear(SSL *s) s->s3->hs.state = SSL_ST_BEFORE|((s->server) ? SSL_ST_ACCEPT : SSL_ST_CONNECT); } -long +static long _SSL_get_shared_group(SSL *s, long n) { size_t count; @@ -1412,7 +1412,7 @@ _SSL_get_shared_group(SSL *s, long n) return nid; } -long +static long _SSL_get_peer_tmp_key(SSL *s, EVP_PKEY **key) { EVP_PKEY *pkey = NULL; diff --git a/src/lib/libssl/ssl_tlsext.c b/src/lib/libssl/ssl_tlsext.c index 2755cbc92d..467784da2b 100644 --- a/src/lib/libssl/ssl_tlsext.c +++ b/src/lib/libssl/ssl_tlsext.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_tlsext.c,v 1.163 2026/06/14 15:47:49 jsing Exp $ */ +/* $OpenBSD: ssl_tlsext.c,v 1.164 2026/07/31 03:59:50 kenjiro Exp $ */ /* * Copyright (c) 2016, 2017, 2019 Joel Sing * Copyright (c) 2017 Doug Hogan @@ -2567,7 +2567,7 @@ tlsext_build(SSL *s, int is_server, uint16_t msg_type, CBB *cbb) return 1; } -int +static int tlsext_clienthello_hash_extension(SSL *s, uint16_t type, CBS *cbs) { /* diff --git a/src/lib/libssl/tls13_record_layer.c b/src/lib/libssl/tls13_record_layer.c index f5604adbeb..778356af15 100644 --- a/src/lib/libssl/tls13_record_layer.c +++ b/src/lib/libssl/tls13_record_layer.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_record_layer.c,v 1.74 2024/09/09 03:32:29 tb Exp $ */ +/* $OpenBSD: tls13_record_layer.c,v 1.75 2026/07/31 03:59:50 kenjiro Exp $ */ /* * Copyright (c) 2018, 2019 Joel Sing * @@ -31,13 +31,13 @@ struct tls13_record_protection { uint8_t seq_num[TLS13_RECORD_SEQ_NUM_LEN]; }; -struct tls13_record_protection * +static struct tls13_record_protection * tls13_record_protection_new(void) { return calloc(1, sizeof(struct tls13_record_protection)); } -void +static void tls13_record_protection_clear(struct tls13_record_protection *rp) { EVP_AEAD_CTX_free(rp->aead_ctx); @@ -48,7 +48,7 @@ tls13_record_protection_clear(struct tls13_record_protection *rp) memset(rp, 0, sizeof(*rp)); } -void +static void tls13_record_protection_free(struct tls13_record_protection *rp) { if (rp == NULL) diff --git a/src/lib/libssl/tls13_server.c b/src/lib/libssl/tls13_server.c index 604dab4cba..8ad11c6428 100644 --- a/src/lib/libssl/tls13_server.c +++ b/src/lib/libssl/tls13_server.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tls13_server.c,v 1.112 2025/12/04 21:03:42 beck Exp $ */ +/* $OpenBSD: tls13_server.c,v 1.113 2026/07/31 03:59:50 kenjiro Exp $ */ /* * Copyright (c) 2019, 2020 Joel Sing * Copyright (c) 2020 Bob Beck @@ -96,7 +96,7 @@ tls13_client_hello_is_legacy(CBS *cbs) return (max_version < TLS1_3_VERSION); } -int +static int tls13_client_hello_required_extensions(struct tls13_ctx *ctx) { SSL *s = ctx->ssl; -- cgit v1.2.3-55-g6feb