summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorHugo Landau <hlandau@openssl.org>2023-04-18 19:30:55 +0100
committerHugo Landau <hlandau@openssl.org>2023-05-12 14:47:12 +0100
commit5bd9ddd86e714705840215b8d2bbb0aedc598e96 (patch)
treefcd10c51b0ee7ed96038b44c3c4b11c04d28d1c9 /include
parent999e13f40eda5a2ca39d1efb407b96f81d2b9535 (diff)
downloadopenssl-new-5bd9ddd86e714705840215b8d2bbb0aedc598e96.tar.gz
QUIC FC: Modify RXFC to support use for enforcing MAX_STREAMS
Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/20765)
Diffstat (limited to 'include')
-rw-r--r--include/internal/quic_fc.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/include/internal/quic_fc.h b/include/internal/quic_fc.h
index b07326ddf4..78398c7242 100644
--- a/include/internal/quic_fc.h
+++ b/include/internal/quic_fc.h
@@ -137,7 +137,7 @@ struct quic_rxfc_st {
OSSL_TIME (*now)(void *arg);
void *now_arg;
QUIC_RXFC *parent;
- unsigned char error_code, has_cwm_changed, is_fin;
+ unsigned char error_code, has_cwm_changed, is_fin, stream_count_mode;
};
/*
@@ -147,6 +147,9 @@ struct quic_rxfc_st {
* and absolute maximum window sizes, respectively. Window size values are
* expressed in bytes and determine how much credit the RXFC extends to the peer
* to transmit more data at a time.
+ *
+ * If stream_count_mode is 1, this RXFC is for use tracking maximum stream count
+ * enforcement. In this case conn_rxfc must be NULL.
*/
int ossl_quic_rxfc_init(QUIC_RXFC *rxfc, QUIC_RXFC *conn_rxfc,
uint64_t initial_window_size,
@@ -155,6 +158,14 @@ int ossl_quic_rxfc_init(QUIC_RXFC *rxfc, QUIC_RXFC *conn_rxfc,
void *now_arg);
/*
+ * Initialises an RX flow controller for stream count enforcement.
+ */
+int ossl_quic_rxfc_init_for_stream_count(QUIC_RXFC *rxfc,
+ uint64_t initial_window_size,
+ OSSL_TIME (*now)(void *arg),
+ void *now_arg);
+
+/*
* Gets the parent (i.e., connection-level) RXFC. Returns NULL if called on a
* connection-level RXFC.
*/