BuildDocsReferenceGuidesBlogDiscordnode:tlsBunConnectionOptionsALPNCallbackBuildDocsReferenceGuidesBlogDiscordnode:tlsBunConnectionOptionsALPNCallbacktls.BunConnectionOptions.ALPNCallbackALPNCallbackReferenceDocsGuidesDiscordMerch StoreGitHubBlogRuntimePackage managerTest runnerBundlerPackage runnerBun 1.0Bun 1.1Bun 1.2Bun 1.3RoadmapContributingLicenseWe're hiring →
property ALPNCallback | Node.js tls module | Bun,AI智能索引,全网链接索引,智能导航,网页索引
- If set, this will be called when a client opens a connection using the ALPN extension.
One argument will be passed to the callback: an object containing `servername` and `protocols` fields,
respectively containing the server name from the SNI extension (if any) and an array of
ALPN protocol name strings. The callback must return either one of the strings listed in `protocols`,
which will be returned to the client as the selected ALPN protocol, or `undefined`,
to reject the connection with a fatal alert. If a string is returned that does not match one of
the client