sockopt.test.ts.snap 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. // Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html
  2. exports[`SockoptStreamSettingsSchema fixtures > parses defaults byte-stably 1`] = `
  3. {
  4. "V6Only": false,
  5. "acceptProxyProtocol": false,
  6. "addressPortStrategy": "none",
  7. "customSockopt": [],
  8. "dialerProxy": "",
  9. "domainStrategy": "AsIs",
  10. "interfaceName": "",
  11. "mark": 0,
  12. "penetrate": false,
  13. "tcpFastOpen": false,
  14. "tcpKeepAliveIdle": 45,
  15. "tcpKeepAliveInterval": 45,
  16. "tcpMaxSeg": 1440,
  17. "tcpMptcp": false,
  18. "tcpUserTimeout": 10000,
  19. "tcpWindowClamp": 600,
  20. "tcpcongestion": "bbr",
  21. "tproxy": "off",
  22. "trustedXForwardedFor": [],
  23. }
  24. `;
  25. exports[`SockoptStreamSettingsSchema fixtures > parses full byte-stably 1`] = `
  26. {
  27. "V6Only": false,
  28. "acceptProxyProtocol": true,
  29. "addressPortStrategy": "none",
  30. "customSockopt": [],
  31. "dialerProxy": "out-proxy-tag",
  32. "domainStrategy": "UseIP",
  33. "interfaceName": "eth0",
  34. "mark": 100,
  35. "penetrate": false,
  36. "tcpFastOpen": true,
  37. "tcpKeepAliveIdle": 300,
  38. "tcpKeepAliveInterval": 15,
  39. "tcpMaxSeg": 1440,
  40. "tcpMptcp": true,
  41. "tcpUserTimeout": 10000,
  42. "tcpWindowClamp": 600,
  43. "tcpcongestion": "cubic",
  44. "tproxy": "redirect",
  45. "trustedXForwardedFor": [
  46. "10.0.0.0/8",
  47. "192.168.0.0/16",
  48. ],
  49. }
  50. `;
  51. exports[`SockoptStreamSettingsSchema fixtures > parses tcp-tuning byte-stably 1`] = `
  52. {
  53. "V6Only": false,
  54. "acceptProxyProtocol": false,
  55. "addressPortStrategy": "none",
  56. "customSockopt": [],
  57. "dialerProxy": "",
  58. "domainStrategy": "AsIs",
  59. "interfaceName": "",
  60. "mark": 0,
  61. "penetrate": false,
  62. "tcpFastOpen": true,
  63. "tcpKeepAliveIdle": 120,
  64. "tcpKeepAliveInterval": 30,
  65. "tcpMaxSeg": 1440,
  66. "tcpMptcp": true,
  67. "tcpUserTimeout": 5000,
  68. "tcpWindowClamp": 600,
  69. "tcpcongestion": "bbr",
  70. "tproxy": "off",
  71. "trustedXForwardedFor": [],
  72. }
  73. `;
  74. exports[`SockoptStreamSettingsSchema fixtures > parses tproxy byte-stably 1`] = `
  75. {
  76. "V6Only": false,
  77. "acceptProxyProtocol": false,
  78. "addressPortStrategy": "none",
  79. "customSockopt": [],
  80. "dialerProxy": "",
  81. "domainStrategy": "ForceIPv4",
  82. "interfaceName": "",
  83. "mark": 255,
  84. "penetrate": true,
  85. "tcpFastOpen": false,
  86. "tcpKeepAliveIdle": 45,
  87. "tcpKeepAliveInterval": 45,
  88. "tcpMaxSeg": 1440,
  89. "tcpMptcp": false,
  90. "tcpUserTimeout": 10000,
  91. "tcpWindowClamp": 600,
  92. "tcpcongestion": "bbr",
  93. "tproxy": "tproxy",
  94. "trustedXForwardedFor": [],
  95. }
  96. `;