Skip to content

Commit 44f3cbf

Browse files
committed
feat(tls): implement TLS module for secure connections
Add client-side TLS support with the following features: - tls.connect() for creating secure outbound connections - tls.createSecureContext() for reusable TLS configurations - TLSSocket class with full event support (secureConnect, data, end, close, error, keylog) - Custom CA certificates for private PKI - Client certificate authentication (mTLS) for zero-trust environments - ALPN protocol negotiation for HTTP/2 support - TLS version control (minVersion/maxVersion) - SNI (Server Name Indication) support - keylog event for TLS debugging with Wireshark - getCiphers(), checkServerIdentity(), rootCertificates This implementation focuses on Lambda-relevant client-side functionality. Server-side APIs (createServer, Server class) are intentionally omitted as they are not applicable to serverless environments. Fixes #1 Fixes #1102
1 parent de7a109 commit 44f3cbf

File tree

14 files changed

+2621
-89
lines changed

14 files changed

+2621
-89
lines changed

API.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,29 @@ Everything else inherited from [Uint8Array](https://developer.mozilla.org/en-US/
245245

246246
[createServer](https://nodejs.org/api/net.html#netcreateserveroptions-connectionlistener)
247247

248+
## tls
249+
250+
> [!WARNING]
251+
> These APIs uses native streams that is not 100% compatible with the Node.js Streams API.
252+
253+
[connect](https://nodejs.org/api/tls.html#tlsconnectoptions-callback)
254+
255+
[createSecureContext](https://nodejs.org/api/tls.html#tlscreatesecurecontextoptions)
256+
257+
[getCiphers](https://nodejs.org/api/tls.html#tlsgetciphers)
258+
259+
[rootCertificates](https://nodejs.org/api/tls.html#tlsrootcertificates)
260+
261+
[checkServerIdentity](https://nodejs.org/api/tls.html#tlscheckserveridentityhostname-cert)
262+
263+
[DEFAULT_MIN_VERSION](https://nodejs.org/api/tls.html#tlsdefault_min_version)
264+
265+
[DEFAULT_MAX_VERSION](https://nodejs.org/api/tls.html#tlsdefault_max_version)
266+
267+
[TLSSocket](https://nodejs.org/api/tls.html#class-tlstlssocket)
268+
269+
[SecureContext](https://nodejs.org/api/tls.html#tlscreatesecurecontextoptions)
270+
248271
## os
249272

250273
[arch](https://nodejs.org/api/os.html#osarch)

0 commit comments

Comments
 (0)