nlcurl 0.13.0 → 0.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (72) hide show
  1. package/README.md +3 -2
  2. package/dist/cookies/psl-data.d.ts +2 -2
  3. package/dist/cookies/psl-data.d.ts.map +1 -1
  4. package/dist/cookies/psl-data.js +81 -11
  5. package/dist/cookies/psl-data.js.map +1 -1
  6. package/dist/cookies/public-suffix.d.ts.map +1 -1
  7. package/dist/cookies/public-suffix.js +41 -33
  8. package/dist/cookies/public-suffix.js.map +1 -1
  9. package/dist/core/session.d.ts.map +1 -1
  10. package/dist/core/session.js +2 -0
  11. package/dist/core/session.js.map +1 -1
  12. package/dist/core/validation.d.ts +9 -0
  13. package/dist/core/validation.d.ts.map +1 -1
  14. package/dist/core/validation.js +18 -5
  15. package/dist/core/validation.js.map +1 -1
  16. package/dist/dns/types.d.ts +0 -2
  17. package/dist/dns/types.d.ts.map +1 -1
  18. package/dist/dns/types.js.map +1 -1
  19. package/dist/fingerprints/extensions.d.ts +0 -6
  20. package/dist/fingerprints/extensions.d.ts.map +1 -1
  21. package/dist/fingerprints/extensions.js +0 -8
  22. package/dist/fingerprints/extensions.js.map +1 -1
  23. package/dist/fingerprints/ja3.d.ts +0 -14
  24. package/dist/fingerprints/ja3.d.ts.map +1 -1
  25. package/dist/fingerprints/ja3.js +0 -35
  26. package/dist/fingerprints/ja3.js.map +1 -1
  27. package/dist/http/h1/encoder.d.ts +0 -11
  28. package/dist/http/h1/encoder.d.ts.map +1 -1
  29. package/dist/http/h1/encoder.js +6 -51
  30. package/dist/http/h1/encoder.js.map +1 -1
  31. package/dist/http/h2/client.d.ts.map +1 -1
  32. package/dist/http/h2/client.js +6 -1
  33. package/dist/http/h2/client.js.map +1 -1
  34. package/dist/http/h2/frames.d.ts +0 -19
  35. package/dist/http/h2/frames.d.ts.map +1 -1
  36. package/dist/http/h2/frames.js +0 -32
  37. package/dist/http/h2/frames.js.map +1 -1
  38. package/dist/http/h2/hpack.d.ts.map +1 -1
  39. package/dist/http/h2/hpack.js +51 -31
  40. package/dist/http/h2/hpack.js.map +1 -1
  41. package/dist/http/negotiator.d.ts.map +1 -1
  42. package/dist/http/negotiator.js +1 -0
  43. package/dist/http/negotiator.js.map +1 -1
  44. package/dist/tls/constants.d.ts +0 -7
  45. package/dist/tls/constants.d.ts.map +1 -1
  46. package/dist/tls/constants.js +0 -9
  47. package/dist/tls/constants.js.map +1 -1
  48. package/dist/tls/ech.d.ts.map +1 -1
  49. package/dist/tls/ech.js +0 -1
  50. package/dist/tls/ech.js.map +1 -1
  51. package/dist/tls/keylog.d.ts +0 -15
  52. package/dist/tls/keylog.d.ts.map +1 -1
  53. package/dist/tls/keylog.js +0 -19
  54. package/dist/tls/keylog.js.map +1 -1
  55. package/dist/tls/stealth/handshake.d.ts +0 -11
  56. package/dist/tls/stealth/handshake.d.ts.map +1 -1
  57. package/dist/tls/stealth/handshake.js +6 -17
  58. package/dist/tls/stealth/handshake.js.map +1 -1
  59. package/dist/tls/stealth/tls12-handshake.d.ts.map +1 -1
  60. package/dist/tls/stealth/tls12-handshake.js +4 -0
  61. package/dist/tls/stealth/tls12-handshake.js.map +1 -1
  62. package/dist/utils/encoding.d.ts.map +1 -1
  63. package/dist/utils/encoding.js +11 -3
  64. package/dist/utils/encoding.js.map +1 -1
  65. package/dist/utils/happy-eyeballs.d.ts +7 -0
  66. package/dist/utils/happy-eyeballs.d.ts.map +1 -1
  67. package/dist/utils/happy-eyeballs.js +17 -1
  68. package/dist/utils/happy-eyeballs.js.map +1 -1
  69. package/dist/ws/frame.d.ts.map +1 -1
  70. package/dist/ws/frame.js +38 -3
  71. package/dist/ws/frame.js.map +1 -1
  72. package/package.json +6 -6
package/README.md CHANGED
@@ -21,6 +21,7 @@ For full API reference, configuration options, and advanced usage examples, plea
21
21
  - **HSTS (RFC 6797)** — Automatic `http://` to `https://` upgrading with `includeSubDomains` support and configurable preload lists.
22
22
  - **DNS-over-HTTPS (RFC 8484)** — Wire-format DoH with GET/POST methods, EDNS(0) with padding (RFC 6891/7830), bootstrap resolution, and integrated DNS caching.
23
23
  - **HTTPS Resource Records (RFC 9460)** — SVCB/HTTPS DNS record resolution for ALPN hints, ECH config delivery, and address hints.
24
+ - **SSRF Protection** — Optional private/reserved IP and dangerous-port blocking, including redirect validation and DNS-resolved address filtering.
24
25
  - **Proxy Support** — HTTP CONNECT tunneling, HTTPS proxies, SOCKS4/4a, and SOCKS5 with optional username/password authentication. Environment variable resolution (`HTTP_PROXY`, `HTTPS_PROXY`, `NO_PROXY`).
25
26
  - **WebSocket (RFC 6455)** — Full WebSocket client with TLS fingerprinting, per-message deflate compression (RFC 7692), control frame validation (≤125 bytes), ping/pong, and binary/text framing.
26
27
  - **Server-Sent Events** — W3C EventSource-compliant SSE parser with streaming async generator interface, UTF-8 BOM stripping, and cross-chunk CRLF handling.
@@ -28,7 +29,7 @@ For full API reference, configuration options, and advanced usage examples, plea
28
29
  - **Retry with Backoff** — Configurable automatic retry with linear or exponential backoff, jitter, `Retry-After` header respect, and custom retry predicates.
29
30
  - **Rate Limiting** — Token-bucket rate limiter with configurable request quotas and automatic queuing.
30
31
  - **Request Body Compression** — Outgoing body compression with gzip, deflate, and Brotli.
31
- - **Response Decompression** — Automatic decompression of gzip, deflate, Brotli, and zstd (Node.js 20.10+) with multi-layer encoding support.
32
+ - **Response Decompression** — Automatic decompression of gzip, deflate, Brotli, and zstd (Node.js 20.10+) with multi-layer encoding support, ratio checks, and buffered output limits.
32
33
  - **Happy Eyeballs v2 (RFC 8305)** — Dual-stack connection racing with 250ms stagger for optimal latency.
33
34
  - **Alt-Svc (RFC 7838)** — HTTP Alternative Services tracking with automatic protocol upgrade preference.
34
35
  - **FormData (RFC 7578)** — Multipart form-data encoding with file upload support.
@@ -183,4 +184,4 @@ NLcURL implements or references the following RFCs and standards:
183
184
 
184
185
  ## License
185
186
 
186
- MIT
187
+ MIT
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Complete Mozilla Public Suffix List rules.
5
5
  * Generated from: https://publicsuffix.org/list/public_suffix_list.dat
6
- * Generated on: 2026-04-04T22:04:47.422Z
7
- * Total rules: 10158
6
+ * Generated on: 2026-07-06T00:27:22.467Z
7
+ * Total rules: 10228
8
8
  *
9
9
  * To regenerate: npx tsx scripts/update-psl.ts
10
10
  */
@@ -1 +1 @@
1
- {"version":3,"file":"psl-data.d.ts","sourceRoot":"","sources":["../../src/cookies/psl-data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,eAAO,MAAM,SAAS,EAAE,SAAS,MAAM,EA+6TtC,CAAC"}
1
+ {"version":3,"file":"psl-data.d.ts","sourceRoot":"","sources":["../../src/cookies/psl-data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,eAAO,MAAM,SAAS,EAAE,SAAS,MAAM,EAq/TtC,CAAC"}
@@ -3,8 +3,8 @@
3
3
  *
4
4
  * Complete Mozilla Public Suffix List rules.
5
5
  * Generated from: https://publicsuffix.org/list/public_suffix_list.dat
6
- * Generated on: 2026-04-04T22:04:47.422Z
7
- * Total rules: 10158
6
+ * Generated on: 2026-07-06T00:27:22.467Z
7
+ * Total rules: 10228
8
8
  *
9
9
  * To regenerate: npx tsx scripts/update-psl.ts
10
10
  */
@@ -1093,6 +1093,7 @@ export const PSL_RULES = [
1093
1093
  "video.hu",
1094
1094
  "id",
1095
1095
  "ac.id",
1096
+ "ai.id",
1096
1097
  "biz.id",
1097
1098
  "co.id",
1098
1099
  "desa.id",
@@ -5501,8 +5502,6 @@ export const PSL_RULES = [
5501
5502
  "lib.mt.us",
5502
5503
  "cc.nc.us",
5503
5504
  "lib.nc.us",
5504
- "cc.nd.us",
5505
- "lib.nd.us",
5506
5505
  "cc.ne.us",
5507
5506
  "lib.ne.us",
5508
5507
  "cc.nh.us",
@@ -7852,7 +7851,9 @@ export const PSL_RULES = [
7852
7851
  "transfer-webapp.cn-northwest-1.on.amazonwebservices.com.cn",
7853
7852
  "eero.online",
7854
7853
  "eero-stage.online",
7854
+ "opentunnel.xyz",
7855
7855
  "antagonist.cloud",
7856
+ "claude.app",
7856
7857
  "apigee.io",
7857
7858
  "panel.dev",
7858
7859
  "siiites.com",
@@ -7889,6 +7890,9 @@ export const PSL_RULES = [
7889
7890
  "potager.org",
7890
7891
  "sweetpepper.org",
7891
7892
  "myasustor.com",
7893
+ "*.atlassian-3p.com",
7894
+ "*.atlassian-3p-us-gov-mod.com",
7895
+ "*.atlassian-isolated-3p.com",
7892
7896
  "cdn.prod.atlassian-dev.net",
7893
7897
  "myfritz.link",
7894
7898
  "myfritz.net",
@@ -7948,10 +7952,12 @@ export const PSL_RULES = [
7948
7952
  "cafjs.com",
7949
7953
  "canva-apps.cn",
7950
7954
  "my.canvasite.cn",
7955
+ "khsj.cn",
7951
7956
  "canva-apps.com",
7952
7957
  "canva-hosted-embed.com",
7953
7958
  "canvacode.com",
7954
7959
  "rice-labs.com",
7960
+ "canva.link",
7955
7961
  "canva.run",
7956
7962
  "my.canva.site",
7957
7963
  "drr.ac",
@@ -8093,7 +8099,6 @@ export const PSL_RULES = [
8093
8099
  "static-access.net",
8094
8100
  "craft.me",
8095
8101
  "realm.cz",
8096
- "on.crisp.email",
8097
8102
  "*.cryptonomic.net",
8098
8103
  "cfolks.pl",
8099
8104
  "cyon.link",
@@ -8131,6 +8136,9 @@ export const PSL_RULES = [
8131
8136
  "deno-staging.dev",
8132
8137
  "deno.net",
8133
8138
  "sandbox.deno.net",
8139
+ "deployagent.com",
8140
+ "piebox.site",
8141
+ "deployagent.space",
8134
8142
  "dedyn.io",
8135
8143
  "deta.app",
8136
8144
  "deta.dev",
@@ -8169,7 +8177,20 @@ export const PSL_RULES = [
8169
8177
  "cc.cd",
8170
8178
  "us.ci",
8171
8179
  "de5.net",
8180
+ "dnshome.at",
8181
+ "resolve.bar",
8182
+ "ddns.berlin",
8183
+ "dnshome.cloud",
8184
+ "ddnssec.de",
8172
8185
  "dnshome.de",
8186
+ "dyndnssec.de",
8187
+ "heimdns.de",
8188
+ "srvdns.de",
8189
+ "dnshome.eu",
8190
+ "dnshome.it",
8191
+ "dyn.now",
8192
+ "heimdns.online",
8193
+ "ddns.wtf",
8173
8194
  "online.th",
8174
8195
  "shop.th",
8175
8196
  "co.scot",
@@ -8585,6 +8606,7 @@ export const PSL_RULES = [
8585
8606
  "staging.expo.app",
8586
8607
  "on.staging.expo.app",
8587
8608
  "onfabrica.com",
8609
+ "fspages.org",
8588
8610
  "ru.net",
8589
8611
  "adygeya.ru",
8590
8612
  "bashkiria.ru",
@@ -8876,6 +8898,7 @@ export const PSL_RULES = [
8876
8898
  "whitesnow.jp",
8877
8899
  "zombie.jp",
8878
8900
  "heteml.net",
8901
+ "vibehost.space",
8879
8902
  "graphic.design",
8880
8903
  "goip.de",
8881
8904
  "*.hosted.app",
@@ -8899,8 +8922,6 @@ export const PSL_RULES = [
8899
8922
  "cloudfunctions.net",
8900
8923
  "goupile.fr",
8901
8924
  "pymnt.uk",
8902
- "cloudapps.digital",
8903
- "london.cloudapps.digital",
8904
8925
  "gov.nl",
8905
8926
  "grafana-dev.net",
8906
8927
  "grayjayleagues.com",
@@ -8941,6 +8962,7 @@ export const PSL_RULES = [
8941
8962
  "*.kin.one",
8942
8963
  "*.id.pub",
8943
8964
  "*.kin.pub",
8965
+ "seprox.hooc.me",
8944
8966
  "hoplix.shop",
8945
8967
  "orx.biz",
8946
8968
  "biz.ng",
@@ -8955,6 +8977,7 @@ export const PSL_RULES = [
8955
8977
  "ltd.ng",
8956
8978
  "ngo.ng",
8957
8979
  "plc.ng",
8980
+ "hstgr.cloud",
8958
8981
  "hostyhosting.io",
8959
8982
  "hf.space",
8960
8983
  "static.hf.space",
@@ -9128,6 +9151,15 @@ export const PSL_RULES = [
9128
9151
  "webadorsite.com",
9129
9152
  "jouwweb.site",
9130
9153
  "js.org",
9154
+ "elastic.k2.cloud",
9155
+ "lb.ru-msk.k2.cloud",
9156
+ "s3.ru-msk.k2.cloud",
9157
+ "website.ru-msk.k2.cloud",
9158
+ "lb.ru-spb.k2.cloud",
9159
+ "s3.ru-spb.k2.cloud",
9160
+ "website.ru-spb.k2.cloud",
9161
+ "s3.k2.cloud",
9162
+ "website.k2.cloud",
9131
9163
  "kaas.gg",
9132
9164
  "khplay.nl",
9133
9165
  "kapsi.fi",
@@ -9254,7 +9286,6 @@ export const PSL_RULES = [
9254
9286
  "mwcloudnonprod.com",
9255
9287
  "polyspace.com",
9256
9288
  "mayfirst.info",
9257
- "mayfirst.org",
9258
9289
  "mcdir.me",
9259
9290
  "mcdir.ru",
9260
9291
  "vps.mcdir.ru",
@@ -9268,6 +9299,7 @@ export const PSL_RULES = [
9268
9299
  "messerli.app",
9269
9300
  "atmeta.com",
9270
9301
  "apps.fbsbx.com",
9302
+ "*.metaaiusercontent.com",
9271
9303
  "*.cloud.metacentrum.cz",
9272
9304
  "custom.metacentrum.cz",
9273
9305
  "flt.cloud.muni.cz",
@@ -9323,6 +9355,7 @@ export const PSL_RULES = [
9323
9355
  "mittwaldserver.info",
9324
9356
  "typo3server.info",
9325
9357
  "project.space",
9358
+ "mkm.fan",
9326
9359
  "mocha.app",
9327
9360
  "mochausercontent.com",
9328
9361
  "mocha-sandbox.dev",
@@ -9466,6 +9499,31 @@ export const PSL_RULES = [
9466
9499
  "*.code.run",
9467
9500
  "*.database.run",
9468
9501
  "*.migration.run",
9502
+ "aberdeen.wa.us",
9503
+ "bainbridge-isl.wa.us",
9504
+ "bellevue.wa.us",
9505
+ "bremerton.wa.us",
9506
+ "centralia.wa.us",
9507
+ "chehalis.wa.us",
9508
+ "forks.wa.us",
9509
+ "gig-harbor.wa.us",
9510
+ "hoquiam.wa.us",
9511
+ "keyport.wa.us",
9512
+ "kingston.wa.us",
9513
+ "olympia.wa.us",
9514
+ "port-angeles.wa.us",
9515
+ "port-ludlow.wa.us",
9516
+ "port-orchard.wa.us",
9517
+ "port-townsend.wa.us",
9518
+ "poulsbo.wa.us",
9519
+ "redmond.wa.us",
9520
+ "renton.wa.us",
9521
+ "sea.wa.us",
9522
+ "seattle.wa.us",
9523
+ "sequim.wa.us",
9524
+ "shelton.wa.us",
9525
+ "silverdale.wa.us",
9526
+ "yarrow-point.wa.us",
9469
9527
  "noticeable.news",
9470
9528
  "notion.site",
9471
9529
  "dnsking.ch",
@@ -9520,6 +9578,7 @@ export const PSL_RULES = [
9520
9578
  "is-local.org",
9521
9579
  "opensocial.site",
9522
9580
  "*.oaiusercontent.com",
9581
+ "chatgpt.site",
9523
9582
  "opencraft.hosting",
9524
9583
  "16-b.it",
9525
9584
  "32-b.it",
@@ -9546,7 +9605,6 @@ export const PSL_RULES = [
9546
9605
  "ox.rs",
9547
9606
  "oy.lc",
9548
9607
  "pgfog.com",
9549
- "pagexl.com",
9550
9608
  "gotpantheon.com",
9551
9609
  "pantheonsite.io",
9552
9610
  "*.paywhirl.com",
@@ -9595,6 +9653,9 @@ export const PSL_RULES = [
9595
9653
  "nyc.mn",
9596
9654
  "*.cn.st",
9597
9655
  "pubtls.org",
9656
+ "puter.app",
9657
+ "puter.site",
9658
+ "puter.work",
9598
9659
  "pythonanywhere.com",
9599
9660
  "eu.pythonanywhere.com",
9600
9661
  "qa2.com",
@@ -9846,6 +9907,9 @@ export const PSL_RULES = [
9846
9907
  "co.ua",
9847
9908
  "pp.ua",
9848
9909
  "as.sh.cn",
9910
+ "vicp.fun",
9911
+ "yicp.fun",
9912
+ "zicp.fun",
9849
9913
  "sheezy.games",
9850
9914
  "myshopblocks.com",
9851
9915
  "myshopify.com",
@@ -9918,6 +9982,7 @@ export const PSL_RULES = [
9918
9982
  "stackit.rocks",
9919
9983
  "stackit.run",
9920
9984
  "stackit.zone",
9985
+ "sryze.cc",
9921
9986
  "indevs.in",
9922
9987
  "musician.io",
9923
9988
  "novecore.site",
@@ -10014,6 +10079,8 @@ export const PSL_RULES = [
10014
10079
  "cust.testing.thingdust.io",
10015
10080
  "reservd.testing.thingdust.io",
10016
10081
  "tickets.io",
10082
+ "t3.storage.dev",
10083
+ "t3.storageapi.dev",
10017
10084
  "arvo.network",
10018
10085
  "azimuth.network",
10019
10086
  "tlon.network",
@@ -10082,6 +10149,8 @@ export const PSL_RULES = [
10082
10149
  "v-info.info",
10083
10150
  "vistablog.ir",
10084
10151
  "deus-canvas.com",
10152
+ "vivenushop.com",
10153
+ "vivenushop.dev",
10085
10154
  "voorloper.cloud",
10086
10155
  "*.vultrobjects.com",
10087
10156
  "wafflecell.com",
@@ -10090,10 +10159,9 @@ export const PSL_RULES = [
10090
10159
  "webflow.io",
10091
10160
  "webflowtest.io",
10092
10161
  "*.webhare.dev",
10093
- "bookonline.app",
10094
10162
  "hotelwithflight.com",
10095
- "reserve-online.com",
10096
10163
  "reserve-online.net",
10164
+ "book.online",
10097
10165
  "cprapid.com",
10098
10166
  "pleskns.com",
10099
10167
  "wp2.host",
@@ -10161,6 +10229,8 @@ export const PSL_RULES = [
10161
10229
  "zap.cloud",
10162
10230
  "zeabur.app",
10163
10231
  "*.zerops.app",
10232
+ "prg1-zerops.zone",
10233
+ "*.zerops.zone",
10164
10234
  "bss.design",
10165
10235
  "basicserver.io",
10166
10236
  "virtualserver.io",