summaryrefslogtreecommitdiffstats
path: root/netwerk/protocol/http/nsHttpConnectionMgr.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-19 01:13:27 +0000
commit40a355a42d4a9444dc753c04c6608dade2f06a23 (patch)
tree871fc667d2de662f171103ce5ec067014ef85e61 /netwerk/protocol/http/nsHttpConnectionMgr.h
parentAdding upstream version 124.0.1. (diff)
downloadfirefox-40a355a42d4a9444dc753c04c6608dade2f06a23.tar.xz
firefox-40a355a42d4a9444dc753c04c6608dade2f06a23.zip
Adding upstream version 125.0.1.upstream/125.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'netwerk/protocol/http/nsHttpConnectionMgr.h')
-rw-r--r--netwerk/protocol/http/nsHttpConnectionMgr.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/netwerk/protocol/http/nsHttpConnectionMgr.h b/netwerk/protocol/http/nsHttpConnectionMgr.h
index 2cf4ab7568..3be6b01689 100644
--- a/netwerk/protocol/http/nsHttpConnectionMgr.h
+++ b/netwerk/protocol/http/nsHttpConnectionMgr.h
@@ -60,6 +60,12 @@ class nsHttpConnectionMgr final : public HttpConnectionMgrShell,
[[nodiscard]] nsresult CancelTransactions(nsHttpConnectionInfo*,
nsresult code);
+ // The connection manager needs to know the hashes used for a WebTransport
+ // connection authenticated with serverCertHashes
+ nsresult StoreServerCertHashes(
+ nsHttpConnectionInfo* aConnInfo, bool aNoSpdy, bool aNoHttp3,
+ nsTArray<RefPtr<nsIWebTransportHash>>&& aServerCertHashes);
+
//-------------------------------------------------------------------------
// NOTE: functions below may be called only on the socket thread.
//-------------------------------------------------------------------------
@@ -143,6 +149,11 @@ class nsHttpConnectionMgr final : public HttpConnectionMgrShell,
void NewIdleConnectionAdded(uint32_t timeToLive);
void DecrementNumIdleConns();
+ const nsTArray<RefPtr<nsIWebTransportHash>>* GetServerCertHashes(
+ nsHttpConnectionInfo* aConnInfo);
+
+ uint64_t GenerateNewWebTransportId() { return mMaxWebTransportId++; }
+
private:
virtual ~nsHttpConnectionMgr();
@@ -334,6 +345,7 @@ class nsHttpConnectionMgr final : public HttpConnectionMgrShell,
void OnMsgPruneNoTraffic(int32_t, ARefBase*);
void OnMsgUpdateCurrentBrowserId(int32_t, ARefBase*);
void OnMsgClearConnectionHistory(int32_t, ARefBase*);
+ void OnMsgStoreServerCertHashes(int32_t, ARefBase*);
// Total number of active connections in all of the ConnectionEntry objects
// that are accessed from mCT connection table.
@@ -462,6 +474,10 @@ class nsHttpConnectionMgr final : public HttpConnectionMgrShell,
void NotifyConnectionOfBrowserIdChange(uint64_t previousId);
void CheckTransInPendingQueue(nsHttpTransaction* aTrans);
+
+ // Used for generating unique IDSs for dedicated connections, currently used
+ // by WebTransport
+ Atomic<uint64_t> mMaxWebTransportId{1};
};
} // namespace mozilla::net