{"_id":"tunnel","maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"keywords":["http","https","agent","proxy","tunnel"],"dist-tags":{"latest":"0.0.6"},"author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"description":"Node HTTP/HTTPS Agents for tunneling proxies","readme":"# node-tunnel - HTTP/HTTPS Agents for tunneling proxies\n\n[![Build Status](https://img.shields.io/travis/koichik/node-tunnel.svg?style=flat)](https://travis-ci.org/koichik/node-tunnel)\n[![Dependency Status](http://img.shields.io/david/koichik/node-tunnel.svg?style=flat)](https://david-dm.org/koichik/node-tunnel#info=dependencies)\n[![DevDependency Status](http://img.shields.io/david/dev/koichik/node-tunnel.svg?style=flat)](https://david-dm.org/koichik/node-tunnel#info=devDependencies)\n\n## Example\n\n```javascript\nvar tunnel = require('tunnel');\n\nvar tunnelingAgent = tunnel.httpsOverHttp({\n  proxy: {\n    host: 'localhost',\n    port: 3128\n  }\n});\n\nvar req = https.request({\n  host: 'example.com',\n  port: 443,\n  agent: tunnelingAgent\n});\n```\n\n## Installation\n\n    $ npm install tunnel\n\n## Usages\n\n### HTTP over HTTP tunneling\n\n```javascript\nvar tunnelingAgent = tunnel.httpOverHttp({\n  maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets\n\n  proxy: { // Proxy settings\n    host: proxyHost, // Defaults to 'localhost'\n    port: proxyPort, // Defaults to 80\n    localAddress: localAddress, // Local interface if necessary\n\n    // Basic authorization for proxy server if necessary\n    proxyAuth: 'user:password',\n\n    // Header fields for proxy server if necessary\n    headers: {\n      'User-Agent': 'Node'\n    }\n  }\n});\n\nvar req = http.request({\n  host: 'example.com',\n  port: 80,\n  agent: tunnelingAgent\n});\n```\n\n### HTTPS over HTTP tunneling\n\n```javascript\nvar tunnelingAgent = tunnel.httpsOverHttp({\n  maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets\n\n  // CA for origin server if necessary\n  ca: [ fs.readFileSync('origin-server-ca.pem')],\n\n  // Client certification for origin server if necessary\n  key: fs.readFileSync('origin-server-key.pem'),\n  cert: fs.readFileSync('origin-server-cert.pem'),\n\n  proxy: { // Proxy settings\n    host: proxyHost, // Defaults to 'localhost'\n    port: proxyPort, // Defaults to 80\n    localAddress: localAddress, // Local interface if necessary\n\n    // Basic authorization for proxy server if necessary\n    proxyAuth: 'user:password',\n\n    // Header fields for proxy server if necessary\n    headers: {\n      'User-Agent': 'Node'\n    },\n  }\n});\n\nvar req = https.request({\n  host: 'example.com',\n  port: 443,\n  agent: tunnelingAgent\n});\n```\n\n### HTTP over HTTPS tunneling\n\n```javascript\nvar tunnelingAgent = tunnel.httpOverHttps({\n  maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets\n\n  proxy: { // Proxy settings\n    host: proxyHost, // Defaults to 'localhost'\n    port: proxyPort, // Defaults to 443\n    localAddress: localAddress, // Local interface if necessary\n\n    // Basic authorization for proxy server if necessary\n    proxyAuth: 'user:password',\n\n    // Header fields for proxy server if necessary\n    headers: {\n      'User-Agent': 'Node'\n    },\n\n    // CA for proxy server if necessary\n    ca: [ fs.readFileSync('origin-server-ca.pem')],\n\n    // Server name for verification if necessary\n    servername: 'example.com',\n\n    // Client certification for proxy server if necessary\n    key: fs.readFileSync('origin-server-key.pem'),\n    cert: fs.readFileSync('origin-server-cert.pem'),\n  }\n});\n\nvar req = http.request({\n  host: 'example.com',\n  port: 80,\n  agent: tunnelingAgent\n});\n```\n\n### HTTPS over HTTPS tunneling\n\n```javascript\nvar tunnelingAgent = tunnel.httpsOverHttps({\n  maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets\n\n  // CA for origin server if necessary\n  ca: [ fs.readFileSync('origin-server-ca.pem')],\n\n  // Client certification for origin server if necessary\n  key: fs.readFileSync('origin-server-key.pem'),\n  cert: fs.readFileSync('origin-server-cert.pem'),\n\n  proxy: { // Proxy settings\n    host: proxyHost, // Defaults to 'localhost'\n    port: proxyPort, // Defaults to 443\n    localAddress: localAddress, // Local interface if necessary\n\n    // Basic authorization for proxy server if necessary\n    proxyAuth: 'user:password',\n\n    // Header fields for proxy server if necessary\n    headers: {\n      'User-Agent': 'Node'\n    }\n\n    // CA for proxy server if necessary\n    ca: [ fs.readFileSync('origin-server-ca.pem')],\n\n    // Server name for verification if necessary\n    servername: 'example.com',\n\n    // Client certification for proxy server if necessary\n    key: fs.readFileSync('origin-server-key.pem'),\n    cert: fs.readFileSync('origin-server-cert.pem'),\n  }\n});\n\nvar req = https.request({\n  host: 'example.com',\n  port: 443,\n  agent: tunnelingAgent\n});\n```\n\n## CONTRIBUTORS\n* [Aleksis Brezas (abresas)](https://github.com/abresas)\n* [Jackson Tian (JacksonTian)](https://github.com/JacksonTian)\n* [Dmitry Sorin (1999)](https://github.com/1999)\n\n## License\n\nLicensed under the [MIT](https://github.com/koichik/node-tunnel/blob/master/LICENSE) license.\n","repository":{"type":"git","url":"git+https://github.com/koichik/node-tunnel.git"},"users":{"goinstant":true,"nex":true,"eijs":true,"ethanliew":true,"fedor":true,"mikestaub":true,"garenyondem":true,"itskdk":true,"zhangyaochun":true,"bouchezb":true,"wfcookie":true,"flumpus-dev":true,"matiasmarani":true,"nachbar90":true},"bugs":{"url":"https://github.com/koichik/node-tunnel/issues"},"license":"MIT","versions":{"0.0.6":{"name":"tunnel","version":"0.0.6","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy","tunnel"],"homepage":"https://github.com/koichik/node-tunnel/","bugs":{"url":"https://github.com/koichik/node-tunnel/issues"},"license":"MIT","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","directories":{"lib":"./lib"},"repository":{"type":"git","url":"git+https://github.com/koichik/node-tunnel.git"},"scripts":{"test":"mocha"},"devDependencies":{"mocha":"^5.2.0","should":"^13.2.3"},"engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"gitHead":"5fb2fb424788597146b7be6729006cad1cf9e9a8","_id":"tunnel@0.0.6","_npmVersion":"5.6.0","_nodeVersion":"8.9.4","_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"dist":{"integrity":"sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==","shasum":"72f1314b34a5b192db012324df2cc587ca47f92c","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.6.tgz","fileCount":12,"unpackedSize":64886,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbl2MUCRA9TVsSAnZWagAAqrEP/R0MbYv1F8/sAQjUUaoN\n0pGj5gt19rpoAEFzYHLI7mYC+AwmNgDrptMbmbFTNbLNGBpV6jt3QguQgaaK\nnS4MgcdNVEQwCtibXqSLYDn39MIOspxlKK8Z+aquc53A77AyM1aZcmnmm59G\nb6JmKNBBvzrJtcwWjdk4RQbkL+KKXLjNNIe0wPTWnZx9Rk142M1/Vbhqyp5r\nqLYnu7vih+S9g4RHKLH+Invwil5se06B6c0Tp75tGN2EyenRdPJFiy5qVuVh\nyJmuvOJNLmw3+FHPuU4uEH3cjLyXY34zsrjvn8g9jVqdrkY/ZKKcw76cQgT5\nmCuWRh9t3bHeMD9o2qlaxKJTKk2NAVDUdu6Q+RdcuMMyoepi5fiYZjRtFTYp\nIO0co1wuYuNNVbigi/V4/QCKOXC5NRWkbbbR6qQOGHNJ0GEQQVmvyraRNQRJ\nJHvqzn8EQnXRwVZJ6zdM0/bAh6LanitSYs4OEh8Nk7+CMVm/ZkHpV0IpCW1/\njBaOHBHrCH9TaeVNDc17o56JkFPhQSU8WqKv6tMLTc7N8+CuEHX/11I5YGTC\nqa//6tZRlWU80Os0YtA78QgonrOzbP7bQvO+k/JMdDzfOykCllmF254ns5Su\nly617muU1zQqlB9FHFIdGGvaStPUKz2IJgYlC0J6JylVtnChnKX0I220VcsP\nQbyz\r\n=EsRp\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA4Upd38q0KQPQg+rGJaM2AY71uAeJSvi1+4G6ZmFF/WAiEAxgVDFKREr5ToDtMpT6kq2B1z4jvt1/83kBwIoIC/4is="}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/tunnel_0.0.6_1536647955409_0.11793783349404907"},"_hasShrinkwrap":false},"0.0.4":{"name":"tunnel","version":"0.0.4","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy","tunnel"],"homepage":"https://github.com/koichik/node-tunnel/","bugs":{"url":"https://github.com/koichik/node-tunnel/issues"},"license":"MIT","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","directories":{"lib":"./lib"},"repository":{"type":"git","url":"git+https://github.com/koichik/node-tunnel.git"},"scripts":{"test":"./node_modules/mocha/bin/mocha"},"devDependencies":{"mocha":"*","should":"*"},"engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"gitHead":"f2dfda3c8df1f75c62ab410d239f70b73aa3145b","_id":"tunnel@0.0.4","_shasum":"2d3785a158c174c9a16dc2c046ec5fc5f1742213","_from":".","_npmVersion":"2.14.12","_nodeVersion":"4.2.5","_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"dist":{"shasum":"2d3785a158c174c9a16dc2c046ec5fc5f1742213","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.4.tgz","integrity":"sha512-o9QYRJN5WgS8oCtqvwzzcfnzaTnDPr7HpUsQdSXscTyzXbjvl4wSHPTUKOKzEaDeQvOuyRtt3ui+ujM7x7TReQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCuDIFrWaod8HqKgHgxT3WmzBeXruGnxPj8TI+AZZ0DTAIhANPJF4H4PdhYXvprScIv1LprQDzqSeEcKvR8T5uGZVbc"}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}]},"0.0.5":{"name":"tunnel","version":"0.0.5","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy","tunnel"],"homepage":"https://github.com/koichik/node-tunnel/","bugs":{"url":"https://github.com/koichik/node-tunnel/issues"},"license":"MIT","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","directories":{"lib":"./lib"},"repository":{"type":"git","url":"git+https://github.com/koichik/node-tunnel.git"},"scripts":{"test":"mocha"},"devDependencies":{"mocha":"*","should":"*"},"engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"gitHead":"556aa7ec925bd9b9bb9c011bd82b6a27a191bc7e","_id":"tunnel@0.0.5","_npmVersion":"5.0.0","_nodeVersion":"8.0.0","_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"dist":{"integrity":"sha512-gj5sdqherx4VZKMcBA4vewER7zdK25Td+z1npBqpbDys4eJrLx+SlYjJvq1bDXs2irkuJM5pf8ktaEQVipkrbA==","shasum":"d1532254749ed36620fcd1010865495a1fa9d0ae","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.5.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF5XTgpTjhP/TVs6xVA+cYxIBZCU4EQ2I8IKOhH6KX8HAiAVHnSRa3xR+6mwg+2zGLCi0OqZzRww92UDkDFktLzmLA=="}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/tunnel-0.0.5.tgz_1497274058509_0.5598482107743621"}},"0.0.2":{"name":"tunnel","version":"0.0.2","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy"],"homepage":"https://github.com/koichik/node-tunnel/","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","licenses":{"type":"The MIT License","url":"http://www.opensource.org/licenses/mit-license.php"},"repositories":"https://github.com/koichik/node-tunnel.git","engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"devDependencies":{"mocha":"*","should":"*"},"scripts":{"test":"./node_modules/mocha/bin/mocha"},"_id":"tunnel@0.0.2","dist":{"shasum":"f23bcd8b7a7b8a864261b2084f66f93193396334","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.2.tgz","integrity":"sha512-PjBRT+4Y/UH3q/lnjXosoaB+hY1yNH2TXWMjPSF1bAIdZmUDAJ2lBPt5s8jTH1e7sgb3nleK889E9vyY4NXpYw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEictT9nST25NEcsDscO3VUnxd5C1xSIuBC8tKaGCw2MAiAzk/xuOIjP60giM28JUREjW3VO+VfggKUFpg1GdE+4WQ=="}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"directories":{}},"0.0.3":{"name":"tunnel","version":"0.0.3","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy"],"homepage":"https://github.com/koichik/node-tunnel/","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","licenses":{"type":"The MIT License","url":"http://www.opensource.org/licenses/mit-license.php"},"repository":{"type":"git","url":"https://github.com/koichik/node-tunnel"},"engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"devDependencies":{"mocha":"*","should":"*"},"scripts":{"test":"./node_modules/mocha/bin/mocha"},"bugs":{"url":"https://github.com/koichik/node-tunnel/issues"},"_id":"tunnel@0.0.3","dist":{"shasum":"e8f988115ca7be9d076c7a1fae4788be708f0cf1","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.3.tgz","integrity":"sha512-YohLhrnpZrbzloZ4AOHh+zKgGrkNO5LDw72UMhfGPC4ccHnNAyimzEb0RMZgqAIuR+PqXO4BzRhaqsv8UBw13Q==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCaWIBdfXecSq1yxf05A/O/spvQWyZMVomYe2JJ2qliagIhANw10n5F3wsQ7vsPvinAXBzN3hdRxE0cW4SJ8WdXcsqO"}]},"_from":".","_npmVersion":"1.2.30","_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"directories":{}},"0.0.0":{"name":"tunnel","version":"0.0.0","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy"],"homepage":"http://github.com/koichik/node-tunnel/","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","licenses":{"type":"The MIT License","url":"http://www.opensource.org/licenses/mit-license.php"},"repositories":"https://github.com/koichik/node-tunnel.git","engines":{"node":"0.7.0 || >=0.7.3"},"devDependencies":{"mocha":"*","should":"*"},"scripts":{"test":"./node_modules/mocha/bin/mocha"},"_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"_id":"tunnel@0.0.0","dependencies":{},"optionalDependencies":{},"_engineSupported":true,"_npmVersion":"1.1.0-3","_nodeVersion":"v0.7.3","_defaultsLoaded":true,"dist":{"shasum":"cf498d7b47520fd7f3dad732e7d6eb18f7e91229","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.0.tgz","integrity":"sha512-JGPrBZfbquchR1SAsj7J4N02tkOh7uUeHaLlTmG/hg7H02K725ozmfuA45qfXePr2K89IpZg5QNDxwoJpKApWw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCADlT6LvuEo9BNhGjJwKoA7/G8iOfS9FPhTp6NESvzIwIhANl7FO4/U2lo7FqW1MF9W+z+cD4GswUxOq4TqA2/C2Cf"}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"directories":{}},"0.0.1":{"name":"tunnel","version":"0.0.1","description":"Node HTTP/HTTPS Agents for tunneling proxies","keywords":["http","https","agent","proxy"],"homepage":"https://github.com/koichik/node-tunnel/","author":{"name":"Koichi Kobayashi","email":"koichik@improvement.jp"},"main":"./index.js","licenses":{"type":"The MIT License","url":"http://www.opensource.org/licenses/mit-license.php"},"repositories":"https://github.com/koichik/node-tunnel.git","engines":{"node":">=0.6.11 <=0.7.0 || >=0.7.3"},"devDependencies":{"mocha":"*","should":"*"},"scripts":{"test":"./node_modules/mocha/bin/mocha"},"_npmUser":{"name":"koichik","email":"koichik@improvement.jp"},"_id":"tunnel@0.0.1","dependencies":{},"optionalDependencies":{},"_engineSupported":true,"_npmVersion":"1.1.1","_nodeVersion":"v0.7.4","_defaultsLoaded":true,"dist":{"shasum":"ff4e8b109432b41b5b4992587f8d053cc5e5e058","tarball":"https://devel.data-in-motion.biz/nexus/repository/npm-group/tunnel/-/tunnel-0.0.1.tgz","integrity":"sha512-V7AD5hA0v2o99C6OIyNnuskd854Bm4JTgJntk8DXkr7NowYnz3FCInkof3DWTcepLz+18fyNrAR0b8dzNNvsUw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDIXuYl63nHNBuyKqVf6ct0gJycJUS0caeGUtqHoG8TTwIgf0+jfgNAsXMW6hxzracZpw1JoCRL3L/syMoCNMmS14c="}]},"maintainers":[{"name":"koichik","email":"koichik@improvement.jp"}],"directories":{}}},"name":"tunnel","time":{"0.0.6":"2018-09-11T06:39:15.596Z","0.0.4":"2016-01-22T16:45:22.020Z","0.0.5":"2017-06-12T13:27:38.716Z","created":"2012-02-11T17:22:49.174Z","modified":"2025-05-13T07:35:36.249Z","0.0.2":"2012-08-04T14:08:54.973Z","0.0.3":"2014-01-20T09:53:22.299Z","0.0.0":"2012-02-11T17:22:52.172Z","0.0.1":"2012-02-18T07:35:24.487Z"},"readmeFilename":"README.md","homepage":"https://github.com/koichik/node-tunnel/"}