diff options
Diffstat (limited to 'node_modules/global-agent/dist')
51 files changed, 0 insertions, 1653 deletions
| diff --git a/node_modules/global-agent/dist/Logger.js b/node_modules/global-agent/dist/Logger.js deleted file mode 100644 index a72a177..0000000 --- a/node_modules/global-agent/dist/Logger.js +++ /dev/null @@ -1,18 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _roarr = _interopRequireDefault(require("roarr")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const Logger = _roarr.default.child({ -  package: 'global-agent' -}); - -var _default = Logger; -exports.default = _default; -//# sourceMappingURL=Logger.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/Logger.js.flow b/node_modules/global-agent/dist/Logger.js.flow deleted file mode 100644 index 166f1e4..0000000 --- a/node_modules/global-agent/dist/Logger.js.flow +++ /dev/null @@ -1,10 +0,0 @@ -// @flow - -import Roarr from 'roarr'; - -const Logger = Roarr -  .child({ -    package: 'global-agent', -  }); - -export default Logger; diff --git a/node_modules/global-agent/dist/Logger.js.map b/node_modules/global-agent/dist/Logger.js.map deleted file mode 100644 index e31661f..0000000 --- a/node_modules/global-agent/dist/Logger.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../src/Logger.js"],"names":["Logger","Roarr","child","package"],"mappings":";;;;;;;AAEA;;;;AAEA,MAAMA,MAAM,GAAGC,eACZC,KADY,CACN;AACLC,EAAAA,OAAO,EAAE;AADJ,CADM,CAAf;;eAKeH,M","sourcesContent":["// @flow\n\nimport Roarr from 'roarr';\n\nconst Logger = Roarr\n  .child({\n    package: 'global-agent',\n  });\n\nexport default Logger;\n"],"file":"Logger.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/Agent.js b/node_modules/global-agent/dist/classes/Agent.js deleted file mode 100644 index ba8cc1a..0000000 --- a/node_modules/global-agent/dist/classes/Agent.js +++ /dev/null @@ -1,174 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _serializeError = require("serialize-error"); - -var _boolean = require("boolean"); - -var _Logger = _interopRequireDefault(require("../Logger")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const log = _Logger.default.child({ -  namespace: 'Agent' -}); - -let requestId = 0; - -class Agent { -  constructor(isProxyConfigured, mustUrlUseProxy, getUrlProxy, fallbackAgent, socketConnectionTimeout) { -    this.fallbackAgent = fallbackAgent; -    this.isProxyConfigured = isProxyConfigured; -    this.mustUrlUseProxy = mustUrlUseProxy; -    this.getUrlProxy = getUrlProxy; -    this.socketConnectionTimeout = socketConnectionTimeout; -  } - -  addRequest(request, configuration) { -    let requestUrl; // It is possible that addRequest was constructed for a proxied request already, e.g. -    // "request" package does this when it detects that a proxy should be used -    // https://github.com/request/request/blob/212570b6971a732b8dd9f3c73354bcdda158a737/request.js#L402 -    // https://gist.github.com/gajus/e2074cd3b747864ffeaabbd530d30218 - -    if (request.path.startsWith('http://') || request.path.startsWith('https://')) { -      requestUrl = request.path; -    } else { -      requestUrl = this.protocol + '//' + (configuration.hostname || configuration.host) + (configuration.port === 80 || configuration.port === 443 ? '' : ':' + configuration.port) + request.path; -    } - -    if (!this.isProxyConfigured()) { -      log.trace({ -        destination: requestUrl -      }, 'not proxying request; GLOBAL_AGENT.HTTP_PROXY is not configured'); // $FlowFixMe It appears that Flow is missing the method description. - -      this.fallbackAgent.addRequest(request, configuration); -      return; -    } - -    if (!this.mustUrlUseProxy(requestUrl)) { -      log.trace({ -        destination: requestUrl -      }, 'not proxying request; url matches GLOBAL_AGENT.NO_PROXY'); // $FlowFixMe It appears that Flow is missing the method description. - -      this.fallbackAgent.addRequest(request, configuration); -      return; -    } - -    const currentRequestId = requestId++; -    const proxy = this.getUrlProxy(requestUrl); - -    if (this.protocol === 'http:') { -      request.path = requestUrl; - -      if (proxy.authorization) { -        request.setHeader('proxy-authorization', 'Basic ' + Buffer.from(proxy.authorization).toString('base64')); -      } -    } - -    log.trace({ -      destination: requestUrl, -      proxy: 'http://' + proxy.hostname + ':' + proxy.port, -      requestId: currentRequestId -    }, 'proxying request'); -    request.on('error', error => { -      log.error({ -        error: (0, _serializeError.serializeError)(error) -      }, 'request error'); -    }); -    request.once('response', response => { -      log.trace({ -        headers: response.headers, -        requestId: currentRequestId, -        statusCode: response.statusCode -      }, 'proxying response'); -    }); -    request.shouldKeepAlive = false; -    const connectionConfiguration = { -      host: configuration.hostname || configuration.host, -      port: configuration.port || 80, -      proxy, -      tls: {} -    }; // add optional tls options for https requests. -    // @see https://nodejs.org/docs/latest-v12.x/api/https.html#https_https_request_url_options_callback : -    // > The following additional options from tls.connect() -    // >   - https://nodejs.org/docs/latest-v12.x/api/tls.html#tls_tls_connect_options_callback - -    // > are also accepted: -    // >   ca, cert, ciphers, clientCertEngine, crl, dhparam, ecdhCurve, honorCipherOrder, -    // >   key, passphrase, pfx, rejectUnauthorized, secureOptions, secureProtocol, servername, sessionIdContext. - -    if (this.protocol === 'https:') { -      connectionConfiguration.tls = { -        ca: configuration.ca, -        cert: configuration.cert, -        ciphers: configuration.ciphers, -        clientCertEngine: configuration.clientCertEngine, -        crl: configuration.crl, -        dhparam: configuration.dhparam, -        ecdhCurve: configuration.ecdhCurve, -        honorCipherOrder: configuration.honorCipherOrder, -        key: configuration.key, -        passphrase: configuration.passphrase, -        pfx: configuration.pfx, -        rejectUnauthorized: configuration.rejectUnauthorized, -        secureOptions: configuration.secureOptions, -        secureProtocol: configuration.secureProtocol, -        servername: configuration.servername || connectionConfiguration.host, -        sessionIdContext: configuration.sessionIdContext -      }; // This is not ideal because there is no way to override this setting using `tls` configuration if `NODE_TLS_REJECT_UNAUTHORIZED=0`. -      // However, popular HTTP clients (such as https://github.com/sindresorhus/got) come with pre-configured value for `rejectUnauthorized`, -      // which makes it impossible to override that value globally and respect `rejectUnauthorized` for specific requests only. -      // -      // eslint-disable-next-line no-process-env - -      if (typeof process.env.NODE_TLS_REJECT_UNAUTHORIZED === 'string' && (0, _boolean.boolean)(process.env.NODE_TLS_REJECT_UNAUTHORIZED) === false) { -        connectionConfiguration.tls.rejectUnauthorized = false; -      } -    } // $FlowFixMe It appears that Flow is missing the method description. - - -    this.createConnection(connectionConfiguration, (error, socket) => { -      log.trace({ -        target: connectionConfiguration -      }, 'connecting'); // @see https://github.com/nodejs/node/issues/5757#issuecomment-305969057 - -      if (socket) { -        socket.setTimeout(this.socketConnectionTimeout, () => { -          socket.destroy(); -        }); -        socket.once('connect', () => { -          log.trace({ -            target: connectionConfiguration -          }, 'connected'); -          socket.setTimeout(0); -        }); -        socket.once('secureConnect', () => { -          log.trace({ -            target: connectionConfiguration -          }, 'connected (secure)'); -          socket.setTimeout(0); -        }); -      } - -      if (error) { -        request.emit('error', error); -      } else { -        log.debug('created socket'); -        socket.on('error', socketError => { -          log.error({ -            error: (0, _serializeError.serializeError)(socketError) -          }, 'socket error'); -        }); -        request.onSocket(socket); -      } -    }); -  } - -} - -var _default = Agent; -exports.default = _default; -//# sourceMappingURL=Agent.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/Agent.js.flow b/node_modules/global-agent/dist/classes/Agent.js.flow deleted file mode 100644 index 801dd1f..0000000 --- a/node_modules/global-agent/dist/classes/Agent.js.flow +++ /dev/null @@ -1,212 +0,0 @@ -// @flow - -import { -  serializeError, -} from 'serialize-error'; -import { -  boolean, -} from 'boolean'; -import Logger from '../Logger'; -import type { -  AgentType, -  GetUrlProxyMethodType, -  IsProxyConfiguredMethodType, -  MustUrlUseProxyMethodType, -  ProtocolType, -} from '../types'; - -const log = Logger.child({ -  namespace: 'Agent', -}); - -let requestId = 0; - -class Agent { -  defaultPort: number; - -  protocol: ProtocolType; - -  fallbackAgent: AgentType; - -  isProxyConfigured: IsProxyConfiguredMethodType; - -  mustUrlUseProxy: MustUrlUseProxyMethodType; - -  getUrlProxy: GetUrlProxyMethodType; - -  socketConnectionTimeout: number; - -  constructor ( -    isProxyConfigured: IsProxyConfiguredMethodType, -    mustUrlUseProxy: MustUrlUseProxyMethodType, -    getUrlProxy: GetUrlProxyMethodType, -    fallbackAgent: AgentType, -    socketConnectionTimeout: number, -  ) { -    this.fallbackAgent = fallbackAgent; -    this.isProxyConfigured = isProxyConfigured; -    this.mustUrlUseProxy = mustUrlUseProxy; -    this.getUrlProxy = getUrlProxy; -    this.socketConnectionTimeout = socketConnectionTimeout; -  } - -  addRequest (request: *, configuration: *) { -    let requestUrl; - -    // It is possible that addRequest was constructed for a proxied request already, e.g. -    // "request" package does this when it detects that a proxy should be used -    // https://github.com/request/request/blob/212570b6971a732b8dd9f3c73354bcdda158a737/request.js#L402 -    // https://gist.github.com/gajus/e2074cd3b747864ffeaabbd530d30218 -    if (request.path.startsWith('http://') || request.path.startsWith('https://')) { -      requestUrl = request.path; -    } else { -      requestUrl = this.protocol + '//' + (configuration.hostname || configuration.host) + (configuration.port === 80 || configuration.port === 443 ? '' : ':' + configuration.port) + request.path; -    } - -    if (!this.isProxyConfigured()) { -      log.trace({ -        destination: requestUrl, -      }, 'not proxying request; GLOBAL_AGENT.HTTP_PROXY is not configured'); - -      // $FlowFixMe It appears that Flow is missing the method description. -      this.fallbackAgent.addRequest(request, configuration); - -      return; -    } - -    if (!this.mustUrlUseProxy(requestUrl)) { -      log.trace({ -        destination: requestUrl, -      }, 'not proxying request; url matches GLOBAL_AGENT.NO_PROXY'); - -      // $FlowFixMe It appears that Flow is missing the method description. -      this.fallbackAgent.addRequest(request, configuration); - -      return; -    } - -    const currentRequestId = requestId++; - -    const proxy = this.getUrlProxy(requestUrl); - -    if (this.protocol === 'http:') { -      request.path = requestUrl; - -      if (proxy.authorization) { -        request.setHeader('proxy-authorization', 'Basic ' + Buffer.from(proxy.authorization).toString('base64')); -      } -    } - -    log.trace({ -      destination: requestUrl, -      proxy: 'http://' + proxy.hostname + ':' + proxy.port, -      requestId: currentRequestId, -    }, 'proxying request'); - -    request.on('error', (error) => { -      log.error({ -        error: serializeError(error), -      }, 'request error'); -    }); - -    request.once('response', (response) => { -      log.trace({ -        headers: response.headers, -        requestId: currentRequestId, -        statusCode: response.statusCode, -      }, 'proxying response'); -    }); - -    request.shouldKeepAlive = false; - -    const connectionConfiguration = { -      host: configuration.hostname || configuration.host, -      port: configuration.port || 80, -      proxy, -      tls: {}, -    }; - -    // add optional tls options for https requests. -    // @see https://nodejs.org/docs/latest-v12.x/api/https.html#https_https_request_url_options_callback : -    // > The following additional options from tls.connect() -    // >   - https://nodejs.org/docs/latest-v12.x/api/tls.html#tls_tls_connect_options_callback - -    // > are also accepted: -    // >   ca, cert, ciphers, clientCertEngine, crl, dhparam, ecdhCurve, honorCipherOrder, -    // >   key, passphrase, pfx, rejectUnauthorized, secureOptions, secureProtocol, servername, sessionIdContext. -    if (this.protocol === 'https:') { -      connectionConfiguration.tls = { -        ca: configuration.ca, -        cert: configuration.cert, -        ciphers: configuration.ciphers, -        clientCertEngine: configuration.clientCertEngine, -        crl: configuration.crl, -        dhparam: configuration.dhparam, -        ecdhCurve: configuration.ecdhCurve, -        honorCipherOrder: configuration.honorCipherOrder, -        key: configuration.key, -        passphrase: configuration.passphrase, -        pfx: configuration.pfx, -        rejectUnauthorized: configuration.rejectUnauthorized, -        secureOptions: configuration.secureOptions, -        secureProtocol: configuration.secureProtocol, -        servername: configuration.servername || connectionConfiguration.host, -        sessionIdContext: configuration.sessionIdContext, -      }; - -      // This is not ideal because there is no way to override this setting using `tls` configuration if `NODE_TLS_REJECT_UNAUTHORIZED=0`. -      // However, popular HTTP clients (such as https://github.com/sindresorhus/got) come with pre-configured value for `rejectUnauthorized`, -      // which makes it impossible to override that value globally and respect `rejectUnauthorized` for specific requests only. -      // -      // eslint-disable-next-line no-process-env -      if (typeof process.env.NODE_TLS_REJECT_UNAUTHORIZED === 'string' && boolean(process.env.NODE_TLS_REJECT_UNAUTHORIZED) === false) { -        connectionConfiguration.tls.rejectUnauthorized = false; -      } -    } - -    // $FlowFixMe It appears that Flow is missing the method description. -    this.createConnection(connectionConfiguration, (error, socket) => { -      log.trace({ -        target: connectionConfiguration, -      }, 'connecting'); - -      // @see https://github.com/nodejs/node/issues/5757#issuecomment-305969057 -      if (socket) { -        socket.setTimeout(this.socketConnectionTimeout, () => { -          socket.destroy(); -        }); - -        socket.once('connect', () => { -          log.trace({ -            target: connectionConfiguration, -          }, 'connected'); - -          socket.setTimeout(0); -        }); - -        socket.once('secureConnect', () => { -          log.trace({ -            target: connectionConfiguration, -          }, 'connected (secure)'); - -          socket.setTimeout(0); -        }); -      } - -      if (error) { -        request.emit('error', error); -      } else { -        log.debug('created socket'); - -        socket.on('error', (socketError) => { -          log.error({ -            error: serializeError(socketError), -          }, 'socket error'); -        }); - -        request.onSocket(socket); -      } -    }); -  } -} - -export default Agent; diff --git a/node_modules/global-agent/dist/classes/Agent.js.map b/node_modules/global-agent/dist/classes/Agent.js.map deleted file mode 100644 index af6283e..0000000 --- a/node_modules/global-agent/dist/classes/Agent.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/classes/Agent.js"],"names":["log","Logger","child","namespace","requestId","Agent","constructor","isProxyConfigured","mustUrlUseProxy","getUrlProxy","fallbackAgent","socketConnectionTimeout","addRequest","request","configuration","requestUrl","path","startsWith","protocol","hostname","host","port","trace","destination","currentRequestId","proxy","authorization","setHeader","Buffer","from","toString","on","error","once","response","headers","statusCode","shouldKeepAlive","connectionConfiguration","tls","ca","cert","ciphers","clientCertEngine","crl","dhparam","ecdhCurve","honorCipherOrder","key","passphrase","pfx","rejectUnauthorized","secureOptions","secureProtocol","servername","sessionIdContext","process","env","NODE_TLS_REJECT_UNAUTHORIZED","createConnection","socket","target","setTimeout","destroy","emit","debug","socketError","onSocket"],"mappings":";;;;;;;AAEA;;AAGA;;AAGA;;;;AASA,MAAMA,GAAG,GAAGC,gBAAOC,KAAP,CAAa;AACvBC,EAAAA,SAAS,EAAE;AADY,CAAb,CAAZ;;AAIA,IAAIC,SAAS,GAAG,CAAhB;;AAEA,MAAMC,KAAN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,CAAU;AACRA,YAAAA,KAAK,EAAE,oCAAekC,WAAf;AADC,WAAV,EAEG,cAFH;AAGD,SAJD;AAMArD,QAAAA,OAAO,CAACsD,QAAR,CAAiBP,MAAjB;AACD;AACF,KAzCD;AA0CD;;AAzLS;;eA4LGvD,K","sourcesContent":["// @flow\n\nimport {\n  serializeError,\n} from 'serialize-error';\nimport {\n  boolean,\n} from 'boolean';\nimport Logger from '../Logger';\nimport type {\n  AgentType,\n  GetUrlProxyMethodType,\n  IsProxyConfiguredMethodType,\n  MustUrlUseProxyMethodType,\n  ProtocolType,\n} from '../types';\n\nconst log = Logger.child({\n  namespace: 'Agent',\n});\n\nlet requestId = 0;\n\nclass Agent {\n  defaultPort: number;\n\n  protocol: ProtocolType;\n\n  fallbackAgent: AgentType;\n\n  isProxyConfigured: IsProxyConfiguredMethodType;\n\n  mustUrlUseProxy: MustUrlUseProxyMethodType;\n\n  getUrlProxy: GetUrlProxyMethodType;\n\n  socketConnectionTimeout: number;\n\n  constructor (\n    isProxyConfigured: IsProxyConfiguredMethodType,\n    mustUrlUseProxy: MustUrlUseProxyMethodType,\n    getUrlProxy: GetUrlProxyMethodType,\n    fallbackAgent: AgentType,\n    socketConnectionTimeout: number,\n  ) {\n    this.fallbackAgent = fallbackAgent;\n    this.isProxyConfigured = isProxyConfigured;\n    this.mustUrlUseProxy = mustUrlUseProxy;\n    this.getUrlProxy = getUrlProxy;\n    this.socketConnectionTimeout = socketConnectionTimeout;\n  }\n\n  addRequest (request: *, configuration: *) {\n    let requestUrl;\n\n    // It is possible that addRequest was constructed for a proxied request already, e.g.\n    // \"request\" package does this when it detects that a proxy should be used\n    // https://github.com/request/request/blob/212570b6971a732b8dd9f3c73354bcdda158a737/request.js#L402\n    // https://gist.github.com/gajus/e2074cd3b747864ffeaabbd530d30218\n    if (request.path.startsWith('http://') || request.path.startsWith('https://')) {\n      requestUrl = request.path;\n    } else {\n      requestUrl = this.protocol + '//' + (configuration.hostname || configuration.host) + (configuration.port === 80 || configuration.port === 443 ? '' : ':' + configuration.port) + request.path;\n    }\n\n    if (!this.isProxyConfigured()) {\n      log.trace({\n        destination: requestUrl,\n      }, 'not proxying request; GLOBAL_AGENT.HTTP_PROXY is not configured');\n\n      // $FlowFixMe It appears that Flow is missing the method description.\n      this.fallbackAgent.addRequest(request, configuration);\n\n      return;\n    }\n\n    if (!this.mustUrlUseProxy(requestUrl)) {\n      log.trace({\n        destination: requestUrl,\n      }, 'not proxying request; url matches GLOBAL_AGENT.NO_PROXY');\n\n      // $FlowFixMe It appears that Flow is missing the method description.\n      this.fallbackAgent.addRequest(request, configuration);\n\n      return;\n    }\n\n    const currentRequestId = requestId++;\n\n    const proxy = this.getUrlProxy(requestUrl);\n\n    if (this.protocol === 'http:') {\n      request.path = requestUrl;\n\n      if (proxy.authorization) {\n        request.setHeader('proxy-authorization', 'Basic ' + Buffer.from(proxy.authorization).toString('base64'));\n      }\n    }\n\n    log.trace({\n      destination: requestUrl,\n      proxy: 'http://' + proxy.hostname + ':' + proxy.port,\n      requestId: currentRequestId,\n    }, 'proxying request');\n\n    request.on('error', (error) => {\n      log.error({\n        error: serializeError(error),\n      }, 'request error');\n    });\n\n    request.once('response', (response) => {\n      log.trace({\n        headers: response.headers,\n        requestId: currentRequestId,\n        statusCode: response.statusCode,\n      }, 'proxying response');\n    });\n\n    request.shouldKeepAlive = false;\n\n    const connectionConfiguration = {\n      host: configuration.hostname || configuration.host,\n      port: configuration.port || 80,\n      proxy,\n      tls: {},\n    };\n\n    // add optional tls options for https requests.\n    // @see https://nodejs.org/docs/latest-v12.x/api/https.html#https_https_request_url_options_callback :\n    // > The following additional options from tls.connect()\n    // >   - https://nodejs.org/docs/latest-v12.x/api/tls.html#tls_tls_connect_options_callback -\n    // > are also accepted:\n    // >   ca, cert, ciphers, clientCertEngine, crl, dhparam, ecdhCurve, honorCipherOrder,\n    // >   key, passphrase, pfx, rejectUnauthorized, secureOptions, secureProtocol, servername, sessionIdContext.\n    if (this.protocol === 'https:') {\n      connectionConfiguration.tls = {\n        ca: configuration.ca,\n        cert: configuration.cert,\n        ciphers: configuration.ciphers,\n        clientCertEngine: configuration.clientCertEngine,\n        crl: configuration.crl,\n        dhparam: configuration.dhparam,\n        ecdhCurve: configuration.ecdhCurve,\n        honorCipherOrder: configuration.honorCipherOrder,\n        key: configuration.key,\n        passphrase: configuration.passphrase,\n        pfx: configuration.pfx,\n        rejectUnauthorized: configuration.rejectUnauthorized,\n        secureOptions: configuration.secureOptions,\n        secureProtocol: configuration.secureProtocol,\n        servername: configuration.servername || connectionConfiguration.host,\n        sessionIdContext: configuration.sessionIdContext,\n      };\n\n      // This is not ideal because there is no way to override this setting using `tls` configuration if `NODE_TLS_REJECT_UNAUTHORIZED=0`.\n      // However, popular HTTP clients (such as https://github.com/sindresorhus/got) come with pre-configured value for `rejectUnauthorized`,\n      // which makes it impossible to override that value globally and respect `rejectUnauthorized` for specific requests only.\n      //\n      // eslint-disable-next-line no-process-env\n      if (typeof process.env.NODE_TLS_REJECT_UNAUTHORIZED === 'string' && boolean(process.env.NODE_TLS_REJECT_UNAUTHORIZED) === false) {\n        connectionConfiguration.tls.rejectUnauthorized = false;\n      }\n    }\n\n    // $FlowFixMe It appears that Flow is missing the method description.\n    this.createConnection(connectionConfiguration, (error, socket) => {\n      log.trace({\n        target: connectionConfiguration,\n      }, 'connecting');\n\n      // @see https://github.com/nodejs/node/issues/5757#issuecomment-305969057\n      if (socket) {\n        socket.setTimeout(this.socketConnectionTimeout, () => {\n          socket.destroy();\n        });\n\n        socket.once('connect', () => {\n          log.trace({\n            target: connectionConfiguration,\n          }, 'connected');\n\n          socket.setTimeout(0);\n        });\n\n        socket.once('secureConnect', () => {\n          log.trace({\n            target: connectionConfiguration,\n          }, 'connected (secure)');\n\n          socket.setTimeout(0);\n        });\n      }\n\n      if (error) {\n        request.emit('error', error);\n      } else {\n        log.debug('created socket');\n\n        socket.on('error', (socketError) => {\n          log.error({\n            error: serializeError(socketError),\n          }, 'socket error');\n        });\n\n        request.onSocket(socket);\n      }\n    });\n  }\n}\n\nexport default Agent;\n"],"file":"Agent.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/HttpProxyAgent.js b/node_modules/global-agent/dist/classes/HttpProxyAgent.js deleted file mode 100644 index 6d1c831..0000000 --- a/node_modules/global-agent/dist/classes/HttpProxyAgent.js +++ /dev/null @@ -1,33 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _net = _interopRequireDefault(require("net")); - -var _Agent = _interopRequireDefault(require("./Agent")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -class HttpProxyAgent extends _Agent.default { -  // @see https://github.com/sindresorhus/eslint-plugin-unicorn/issues/169#issuecomment-486980290 -  // eslint-disable-next-line unicorn/prevent-abbreviations -  constructor(...args) { -    super(...args); -    this.protocol = 'http:'; -    this.defaultPort = 80; -  } - -  createConnection(configuration, callback) { -    const socket = _net.default.connect(configuration.proxy.port, configuration.proxy.hostname); - -    callback(null, socket); -  } - -} - -var _default = HttpProxyAgent; -exports.default = _default; -//# sourceMappingURL=HttpProxyAgent.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/HttpProxyAgent.js.flow b/node_modules/global-agent/dist/classes/HttpProxyAgent.js.flow deleted file mode 100644 index 8b9b471..0000000 --- a/node_modules/global-agent/dist/classes/HttpProxyAgent.js.flow +++ /dev/null @@ -1,30 +0,0 @@ -// @flow - -import net from 'net'; -import type { -  ConnectionCallbackType, -  ConnectionConfigurationType, -} from '../types'; -import Agent from './Agent'; - -class HttpProxyAgent extends Agent { -  // @see https://github.com/sindresorhus/eslint-plugin-unicorn/issues/169#issuecomment-486980290 -  // eslint-disable-next-line unicorn/prevent-abbreviations -  constructor (...args: *) { -    super(...args); - -    this.protocol = 'http:'; -    this.defaultPort = 80; -  } - -  createConnection (configuration: ConnectionConfigurationType, callback: ConnectionCallbackType) { -    const socket = net.connect( -      configuration.proxy.port, -      configuration.proxy.hostname, -    ); - -    callback(null, socket); -  } -} - -export default HttpProxyAgent; diff --git a/node_modules/global-agent/dist/classes/HttpProxyAgent.js.map b/node_modules/global-agent/dist/classes/HttpProxyAgent.js.map deleted file mode 100644 index f2586b9..0000000 --- a/node_modules/global-agent/dist/classes/HttpProxyAgent.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/classes/HttpProxyAgent.js"],"names":["HttpProxyAgent","Agent","constructor","args","protocol","defaultPort","createConnection","configuration","callback","socket","net","connect","proxy","port","hostname"],"mappings":";;;;;;;AAEA;;AAKA;;;;AAEA,MAAMA,cAAN,SAA6BC,cAA7B,CAAmC;AACjC;AACA;AACAC,EAAAA,WAAW,CAAE,GAAGC,IAAL,EAAc;AACvB,UAAM,GAAGA,IAAT;AAEA,SAAKC,QAAL,GAAgB,OAAhB;AACA,SAAKC,WAAL,GAAmB,EAAnB;AACD;;AAEDC,EAAAA,gBAAgB,CAAEC,aAAF,EAA8CC,QAA9C,EAAgF;AAC9F,UAAMC,MAAM,GAAGC,aAAIC,OAAJ,CACbJ,aAAa,CAACK,KAAd,CAAoBC,IADP,EAEbN,aAAa,CAACK,KAAd,CAAoBE,QAFP,CAAf;;AAKAN,IAAAA,QAAQ,CAAC,IAAD,EAAOC,MAAP,CAAR;AACD;;AAjBgC;;eAoBpBT,c","sourcesContent":["// @flow\n\nimport net from 'net';\nimport type {\n  ConnectionCallbackType,\n  ConnectionConfigurationType,\n} from '../types';\nimport Agent from './Agent';\n\nclass HttpProxyAgent extends Agent {\n  // @see https://github.com/sindresorhus/eslint-plugin-unicorn/issues/169#issuecomment-486980290\n  // eslint-disable-next-line unicorn/prevent-abbreviations\n  constructor (...args: *) {\n    super(...args);\n\n    this.protocol = 'http:';\n    this.defaultPort = 80;\n  }\n\n  createConnection (configuration: ConnectionConfigurationType, callback: ConnectionCallbackType) {\n    const socket = net.connect(\n      configuration.proxy.port,\n      configuration.proxy.hostname,\n    );\n\n    callback(null, socket);\n  }\n}\n\nexport default HttpProxyAgent;\n"],"file":"HttpProxyAgent.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js b/node_modules/global-agent/dist/classes/HttpsProxyAgent.js deleted file mode 100644 index 1206ffa..0000000 --- a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js +++ /dev/null @@ -1,53 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _net = _interopRequireDefault(require("net")); - -var _tls = _interopRequireDefault(require("tls")); - -var _Agent = _interopRequireDefault(require("./Agent")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -class HttpsProxyAgent extends _Agent.default { -  // eslint-disable-next-line unicorn/prevent-abbreviations -  constructor(...args) { -    super(...args); -    this.protocol = 'https:'; -    this.defaultPort = 443; -  } - -  createConnection(configuration, callback) { -    const socket = _net.default.connect(configuration.proxy.port, configuration.proxy.hostname); - -    socket.on('error', error => { -      callback(error); -    }); -    socket.once('data', () => { -      const secureSocket = _tls.default.connect({ ...configuration.tls, -        socket -      }); - -      callback(null, secureSocket); -    }); -    let connectMessage = ''; -    connectMessage += 'CONNECT ' + configuration.host + ':' + configuration.port + ' HTTP/1.1\r\n'; -    connectMessage += 'Host: ' + configuration.host + ':' + configuration.port + '\r\n'; - -    if (configuration.proxy.authorization) { -      connectMessage += 'Proxy-Authorization: Basic ' + Buffer.from(configuration.proxy.authorization).toString('base64') + '\r\n'; -    } - -    connectMessage += '\r\n'; -    socket.write(connectMessage); -  } - -} - -var _default = HttpsProxyAgent; -exports.default = _default; -//# sourceMappingURL=HttpsProxyAgent.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.flow b/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.flow deleted file mode 100644 index 24d724f..0000000 --- a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.flow +++ /dev/null @@ -1,54 +0,0 @@ -// @flow - -import net from 'net'; -import tls from 'tls'; -import type { -  ConnectionCallbackType, -  ConnectionConfigurationType, -} from '../types'; -import Agent from './Agent'; - -class HttpsProxyAgent extends Agent { -  // eslint-disable-next-line unicorn/prevent-abbreviations -  constructor (...args: *) { -    super(...args); - -    this.protocol = 'https:'; -    this.defaultPort = 443; -  } - -  createConnection (configuration: ConnectionConfigurationType, callback: ConnectionCallbackType) { -    const socket = net.connect( -      configuration.proxy.port, -      configuration.proxy.hostname, -    ); - -    socket.on('error', (error) => { -      callback(error); -    }); - -    socket.once('data', () => { -      const secureSocket = tls.connect({ -        ...configuration.tls, -        socket, -      }); - -      callback(null, secureSocket); -    }); - -    let connectMessage = ''; - -    connectMessage += 'CONNECT ' + configuration.host + ':' + configuration.port + ' HTTP/1.1\r\n'; -    connectMessage += 'Host: ' + configuration.host + ':' + configuration.port + '\r\n'; - -    if (configuration.proxy.authorization) { -      connectMessage += 'Proxy-Authorization: Basic ' + Buffer.from(configuration.proxy.authorization).toString('base64') + '\r\n'; -    } - -    connectMessage += '\r\n'; - -    socket.write(connectMessage); -  } -} - -export default HttpsProxyAgent; diff --git a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.map b/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.map deleted file mode 100644 index 0bad4a9..0000000 --- a/node_modules/global-agent/dist/classes/HttpsProxyAgent.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/classes/HttpsProxyAgent.js"],"names":["HttpsProxyAgent","Agent","constructor","args","protocol","defaultPort","createConnection","configuration","callback","socket","net","connect","proxy","port","hostname","on","error","once","secureSocket","tls","connectMessage","host","authorization","Buffer","from","toString","write"],"mappings":";;;;;;;AAEA;;AACA;;AAKA;;;;AAEA,MAAMA,eAAN,SAA8BC,cAA9B,CAAoC;AAClC;AACAC,EAAAA,WAAW,CAAE,GAAGC,IAAL,EAAc;AACvB,UAAM,GAAGA,IAAT;AAEA,SAAKC,QAAL,GAAgB,QAAhB;AACA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} from '../types';\nimport Agent from './Agent';\n\nclass HttpsProxyAgent extends Agent {\n  // eslint-disable-next-line unicorn/prevent-abbreviations\n  constructor (...args: *) {\n    super(...args);\n\n    this.protocol = 'https:';\n    this.defaultPort = 443;\n  }\n\n  createConnection (configuration: ConnectionConfigurationType, callback: ConnectionCallbackType) {\n    const socket = net.connect(\n      configuration.proxy.port,\n      configuration.proxy.hostname,\n    );\n\n    socket.on('error', (error) => {\n      callback(error);\n    });\n\n    socket.once('data', () => {\n      const secureSocket = tls.connect({\n        ...configuration.tls,\n        socket,\n      });\n\n      callback(null, secureSocket);\n    });\n\n    let connectMessage = '';\n\n    connectMessage += 'CONNECT ' + configuration.host + ':' + configuration.port + ' HTTP/1.1\\r\\n';\n    connectMessage += 'Host: ' + configuration.host + ':' + configuration.port + '\\r\\n';\n\n    if (configuration.proxy.authorization) {\n      connectMessage += 'Proxy-Authorization: Basic ' + Buffer.from(configuration.proxy.authorization).toString('base64') + '\\r\\n';\n    }\n\n    connectMessage += '\\r\\n';\n\n    socket.write(connectMessage);\n  }\n}\n\nexport default HttpsProxyAgent;\n"],"file":"HttpsProxyAgent.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/index.js b/node_modules/global-agent/dist/classes/index.js deleted file mode 100644 index b3889d2..0000000 --- a/node_modules/global-agent/dist/classes/index.js +++ /dev/null @@ -1,32 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -Object.defineProperty(exports, "Agent", { -  enumerable: true, -  get: function () { -    return _Agent.default; -  } -}); -Object.defineProperty(exports, "HttpProxyAgent", { -  enumerable: true, -  get: function () { -    return _HttpProxyAgent.default; -  } -}); -Object.defineProperty(exports, "HttpsProxyAgent", { -  enumerable: true, -  get: function () { -    return _HttpsProxyAgent.default; -  } -}); - -var _Agent = _interopRequireDefault(require("./Agent")); - -var _HttpProxyAgent = _interopRequireDefault(require("./HttpProxyAgent")); - -var _HttpsProxyAgent = _interopRequireDefault(require("./HttpsProxyAgent")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/classes/index.js.flow b/node_modules/global-agent/dist/classes/index.js.flow deleted file mode 100644 index 9e8418a..0000000 --- a/node_modules/global-agent/dist/classes/index.js.flow +++ /dev/null @@ -1,5 +0,0 @@ -// @flow - -export {default as Agent} from './Agent'; -export {default as HttpProxyAgent} from './HttpProxyAgent'; -export {default as HttpsProxyAgent} from './HttpsProxyAgent'; diff --git a/node_modules/global-agent/dist/classes/index.js.map b/node_modules/global-agent/dist/classes/index.js.map deleted file mode 100644 index 59a05bb..0000000 --- a/node_modules/global-agent/dist/classes/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/classes/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAEA;;AACA;;AACA","sourcesContent":["// @flow\n\nexport {default as Agent} from './Agent';\nexport {default as HttpProxyAgent} from './HttpProxyAgent';\nexport {default as HttpsProxyAgent} from './HttpsProxyAgent';\n"],"file":"index.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/errors.js b/node_modules/global-agent/dist/errors.js deleted file mode 100644 index 578d19e..0000000 --- a/node_modules/global-agent/dist/errors.js +++ /dev/null @@ -1,22 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.UnexpectedStateError = void 0; - -var _es6Error = _interopRequireDefault(require("es6-error")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -/* eslint-disable fp/no-class, fp/no-this */ -class UnexpectedStateError extends _es6Error.default { -  constructor(message, code = 'UNEXPECTED_STATE_ERROR') { -    super(message); -    this.code = code; -  } - -} - -exports.UnexpectedStateError = UnexpectedStateError; -//# sourceMappingURL=errors.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/errors.js.flow b/node_modules/global-agent/dist/errors.js.flow deleted file mode 100644 index d93ba6f..0000000 --- a/node_modules/global-agent/dist/errors.js.flow +++ /dev/null @@ -1,15 +0,0 @@ -// @flow - -/* eslint-disable fp/no-class, fp/no-this */ - -import ExtendableError from 'es6-error'; - -export class UnexpectedStateError extends ExtendableError { -  code: string; - -  constructor (message: string, code: string = 'UNEXPECTED_STATE_ERROR') { -    super(message); - -    this.code = code; -  } -} diff --git a/node_modules/global-agent/dist/errors.js.map b/node_modules/global-agent/dist/errors.js.map deleted file mode 100644 index 7388bd1..0000000 --- a/node_modules/global-agent/dist/errors.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../src/errors.js"],"names":["UnexpectedStateError","ExtendableError","constructor","message","code"],"mappings":";;;;;;;AAIA;;;;AAFA;AAIO,MAAMA,oBAAN,SAAmCC,iBAAnC,CAAmD;AAGxDC,EAAAA,WAAW,CAAEC,OAAF,EAAmBC,IAAY,GAAG,wBAAlC,EAA4D;AACrE,UAAMD,OAAN;AAEA,SAAKC,IAAL,GAAYA,IAAZ;AACD;;AAPuD","sourcesContent":["// @flow\n\n/* eslint-disable fp/no-class, fp/no-this */\n\nimport ExtendableError from 'es6-error';\n\nexport class UnexpectedStateError extends ExtendableError {\n  code: string;\n\n  constructor (message: string, code: string = 'UNEXPECTED_STATE_ERROR') {\n    super(message);\n\n    this.code = code;\n  }\n}\n"],"file":"errors.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js b/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js deleted file mode 100644 index c87b9ed..0000000 --- a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js +++ /dev/null @@ -1,175 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _http = _interopRequireDefault(require("http")); - -var _https = _interopRequireDefault(require("https")); - -var _boolean = require("boolean"); - -var _semver = _interopRequireDefault(require("semver")); - -var _Logger = _interopRequireDefault(require("../Logger")); - -var _classes = require("../classes"); - -var _errors = require("../errors"); - -var _utilities = require("../utilities"); - -var _createProxyController = _interopRequireDefault(require("./createProxyController")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const httpGet = _http.default.get; -const httpRequest = _http.default.request; -const httpsGet = _https.default.get; -const httpsRequest = _https.default.request; - -const log = _Logger.default.child({ -  namespace: 'createGlobalProxyAgent' -}); - -const defaultConfigurationInput = { -  environmentVariableNamespace: undefined, -  forceGlobalAgent: undefined, -  socketConnectionTimeout: 60000 -}; - -const omitUndefined = subject => { -  const keys = Object.keys(subject); -  const result = {}; - -  for (const key of keys) { -    const value = subject[key]; - -    if (value !== undefined) { -      result[key] = value; -    } -  } - -  return result; -}; - -const createConfiguration = configurationInput => { -  // eslint-disable-next-line no-process-env -  const environment = process.env; -  const defaultConfiguration = { -    environmentVariableNamespace: typeof environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE === 'string' ? environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE : 'GLOBAL_AGENT_', -    forceGlobalAgent: typeof environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT === 'string' ? (0, _boolean.boolean)(environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT) : true, -    socketConnectionTimeout: typeof environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT === 'string' ? Number.parseInt(environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT, 10) : defaultConfigurationInput.socketConnectionTimeout -  }; // $FlowFixMe - -  return { ...defaultConfiguration, -    ...omitUndefined(configurationInput) -  }; -}; - -const createGlobalProxyAgent = (configurationInput = defaultConfigurationInput) => { -  const configuration = createConfiguration(configurationInput); -  const proxyController = (0, _createProxyController.default)(); // eslint-disable-next-line no-process-env - -  proxyController.HTTP_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTP_PROXY'] || null; // eslint-disable-next-line no-process-env - -  proxyController.HTTPS_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTPS_PROXY'] || null; // eslint-disable-next-line no-process-env - -  proxyController.NO_PROXY = process.env[configuration.environmentVariableNamespace + 'NO_PROXY'] || null; -  log.info({ -    configuration, -    state: proxyController -  }, 'global agent has been initialized'); - -  const mustUrlUseProxy = getProxy => { -    return url => { -      if (!getProxy()) { -        return false; -      } - -      if (!proxyController.NO_PROXY) { -        return true; -      } - -      return !(0, _utilities.isUrlMatchingNoProxy)(url, proxyController.NO_PROXY); -    }; -  }; - -  const getUrlProxy = getProxy => { -    return () => { -      const proxy = getProxy(); - -      if (!proxy) { -        throw new _errors.UnexpectedStateError('HTTP(S) proxy must be configured.'); -      } - -      return (0, _utilities.parseProxyUrl)(proxy); -    }; -  }; - -  const getHttpProxy = () => { -    return proxyController.HTTP_PROXY; -  }; - -  const BoundHttpProxyAgent = class extends _classes.HttpProxyAgent { -    constructor() { -      super(() => { -        return getHttpProxy(); -      }, mustUrlUseProxy(getHttpProxy), getUrlProxy(getHttpProxy), _http.default.globalAgent, configuration.socketConnectionTimeout); -    } - -  }; -  const httpAgent = new BoundHttpProxyAgent(); - -  const getHttpsProxy = () => { -    return proxyController.HTTPS_PROXY || proxyController.HTTP_PROXY; -  }; - -  const BoundHttpsProxyAgent = class extends _classes.HttpsProxyAgent { -    constructor() { -      super(() => { -        return getHttpsProxy(); -      }, mustUrlUseProxy(getHttpsProxy), getUrlProxy(getHttpsProxy), _https.default.globalAgent, configuration.socketConnectionTimeout); -    } - -  }; -  const httpsAgent = new BoundHttpsProxyAgent(); // Overriding globalAgent was added in v11.7. -  // @see https://nodejs.org/uk/blog/release/v11.7.0/ - -  if (_semver.default.gte(process.version, 'v11.7.0')) { -    // @see https://github.com/facebook/flow/issues/7670 -    // $FlowFixMe -    _http.default.globalAgent = httpAgent; // $FlowFixMe - -    _https.default.globalAgent = httpsAgent; -  } // The reason this logic is used in addition to overriding http(s).globalAgent -  // is because there is no guarantee that we set http(s).globalAgent variable -  // before an instance of http(s).Agent has been already constructed by someone, -  // e.g. Stripe SDK creates instances of http(s).Agent at the top-level. -  // @see https://github.com/gajus/global-agent/pull/13 -  // -  // We still want to override http(s).globalAgent when possible to enable logic -  // in `bindHttpMethod`. - - -  if (_semver.default.gte(process.version, 'v10.0.0')) { -    // $FlowFixMe -    _http.default.get = (0, _utilities.bindHttpMethod)(httpGet, httpAgent, configuration.forceGlobalAgent); // $FlowFixMe - -    _http.default.request = (0, _utilities.bindHttpMethod)(httpRequest, httpAgent, configuration.forceGlobalAgent); // $FlowFixMe - -    _https.default.get = (0, _utilities.bindHttpMethod)(httpsGet, httpsAgent, configuration.forceGlobalAgent); // $FlowFixMe - -    _https.default.request = (0, _utilities.bindHttpMethod)(httpsRequest, httpsAgent, configuration.forceGlobalAgent); -  } else { -    log.warn('attempt to initialize global-agent in unsupported Node.js version was ignored'); -  } - -  return proxyController; -}; - -var _default = createGlobalProxyAgent; -exports.default = _default; -//# sourceMappingURL=createGlobalProxyAgent.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.flow b/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.flow deleted file mode 100644 index d515a9d..0000000 --- a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.flow +++ /dev/null @@ -1,197 +0,0 @@ -// @flow - -import http from 'http'; -import https from 'https'; -import { -  boolean as parseBoolean, -} from 'boolean'; -import semver from 'semver'; -import Logger from '../Logger'; -import { -  HttpProxyAgent, -  HttpsProxyAgent, -} from '../classes'; -import { -  UnexpectedStateError, -} from '../errors'; -import { -  bindHttpMethod, -  isUrlMatchingNoProxy, -  parseProxyUrl, -} from '../utilities'; -import type { -  ProxyAgentConfigurationInputType, -  ProxyAgentConfigurationType, -} from '../types'; -import createProxyController from './createProxyController'; - -const httpGet = http.get; -const httpRequest = http.request; -const httpsGet = https.get; -const httpsRequest = https.request; - -const log = Logger.child({ -  namespace: 'createGlobalProxyAgent', -}); - -const defaultConfigurationInput = { -  environmentVariableNamespace: undefined, -  forceGlobalAgent: undefined, -  socketConnectionTimeout: 60000, -}; - -const omitUndefined = (subject) => { -  const keys = Object.keys(subject); - -  const result = {}; - -  for (const key of keys) { -    const value = subject[key]; - -    if (value !== undefined) { -      result[key] = value; -    } -  } - -  return result; -}; - -const createConfiguration = (configurationInput: ProxyAgentConfigurationInputType): ProxyAgentConfigurationType => { -  // eslint-disable-next-line no-process-env -  const environment = process.env; - -  const defaultConfiguration = { -    environmentVariableNamespace: typeof environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE === 'string' ? environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE : 'GLOBAL_AGENT_', -    forceGlobalAgent: typeof environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT === 'string' ? parseBoolean(environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT) : true, -    socketConnectionTimeout: typeof environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT === 'string' ? Number.parseInt(environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT, 10) : defaultConfigurationInput.socketConnectionTimeout, -  }; - -  // $FlowFixMe -  return { -    ...defaultConfiguration, -    ...omitUndefined(configurationInput), -  }; -}; - -export default (configurationInput: ProxyAgentConfigurationInputType = defaultConfigurationInput) => { -  const configuration = createConfiguration(configurationInput); - -  const proxyController = createProxyController(); - -  // eslint-disable-next-line no-process-env -  proxyController.HTTP_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTP_PROXY'] || null; - -  // eslint-disable-next-line no-process-env -  proxyController.HTTPS_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTPS_PROXY'] || null; - -  // eslint-disable-next-line no-process-env -  proxyController.NO_PROXY = process.env[configuration.environmentVariableNamespace + 'NO_PROXY'] || null; - -  log.info({ -    configuration, -    state: proxyController, -  }, 'global agent has been initialized'); - -  const mustUrlUseProxy = (getProxy) => { -    return (url) => { -      if (!getProxy()) { -        return false; -      } - -      if (!proxyController.NO_PROXY) { -        return true; -      } - -      return !isUrlMatchingNoProxy(url, proxyController.NO_PROXY); -    }; -  }; - -  const getUrlProxy = (getProxy) => { -    return () => { -      const proxy = getProxy(); - -      if (!proxy) { -        throw new UnexpectedStateError('HTTP(S) proxy must be configured.'); -      } - -      return parseProxyUrl(proxy); -    }; -  }; - -  const getHttpProxy = () => { -    return proxyController.HTTP_PROXY; -  }; - -  const BoundHttpProxyAgent = class extends HttpProxyAgent { -    constructor () { -      super( -        () => { -          return getHttpProxy(); -        }, -        mustUrlUseProxy(getHttpProxy), -        getUrlProxy(getHttpProxy), -        http.globalAgent, -        configuration.socketConnectionTimeout, -      ); -    } -  }; - -  const httpAgent = new BoundHttpProxyAgent(); - -  const getHttpsProxy = () => { -    return proxyController.HTTPS_PROXY || proxyController.HTTP_PROXY; -  }; - -  const BoundHttpsProxyAgent = class extends HttpsProxyAgent { -    constructor () { -      super( -        () => { -          return getHttpsProxy(); -        }, -        mustUrlUseProxy(getHttpsProxy), -        getUrlProxy(getHttpsProxy), -        https.globalAgent, -        configuration.socketConnectionTimeout, -      ); -    } -  }; - -  const httpsAgent = new BoundHttpsProxyAgent(); - -  // Overriding globalAgent was added in v11.7. -  // @see https://nodejs.org/uk/blog/release/v11.7.0/ -  if (semver.gte(process.version, 'v11.7.0')) { -    // @see https://github.com/facebook/flow/issues/7670 -    // $FlowFixMe -    http.globalAgent = httpAgent; - -    // $FlowFixMe -    https.globalAgent = httpsAgent; -  } - -  // The reason this logic is used in addition to overriding http(s).globalAgent -  // is because there is no guarantee that we set http(s).globalAgent variable -  // before an instance of http(s).Agent has been already constructed by someone, -  // e.g. Stripe SDK creates instances of http(s).Agent at the top-level. -  // @see https://github.com/gajus/global-agent/pull/13 -  // -  // We still want to override http(s).globalAgent when possible to enable logic -  // in `bindHttpMethod`. -  if (semver.gte(process.version, 'v10.0.0')) { -    // $FlowFixMe -    http.get = bindHttpMethod(httpGet, httpAgent, configuration.forceGlobalAgent); - -    // $FlowFixMe -    http.request = bindHttpMethod(httpRequest, httpAgent, configuration.forceGlobalAgent); - -    // $FlowFixMe -    https.get = bindHttpMethod(httpsGet, httpsAgent, configuration.forceGlobalAgent); - -    // $FlowFixMe -    https.request = bindHttpMethod(httpsRequest, httpsAgent, configuration.forceGlobalAgent); -  } else { -    log.warn('attempt to initialize global-agent in unsupported Node.js version was ignored'); -  } - -  return proxyController; -}; diff --git a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.map b/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.map deleted file mode 100644 index 00b69f9..0000000 --- a/node_modules/global-agent/dist/factories/createGlobalProxyAgent.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/factories/createGlobalProxyAgent.js"],"names":["httpGet","http","get","httpRequest","request","httpsGet","https","httpsRequest","log","Logger","child","namespace","defaultConfigurationInput","environmentVariableNamespace","undefined","forceGlobalAgent","socketConnectionTimeout","omitUndefined","subject","keys","Object","result","key","value","createConfiguration","configurationInput","environment","process","env","defaultConfiguration","GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE","GLOBAL_AGENT_FORCE_GLOBAL_AGENT","GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT","Number","parseInt","configuration","proxyController","HTTP_PROXY","HTTPS_PROXY","NO_PROXY","info","state","mustUrlUseProxy","getProxy","url","getUrlProxy","proxy","UnexpectedStateError","getHttpProxy","BoundHttpProxyAgent","HttpProxyAgent","constructor","globalAgent","httpAgent","getHttpsProxy","BoundHttpsProxyAgent","HttpsProxyAgent","httpsAgent","semver","gte","version","warn"],"mappings":";;;;;;;AAEA;;AACA;;AACA;;AAGA;;AACA;;AACA;;AAIA;;AAGA;;AASA;;;;AAEA,MAAMA,OAAO,GAAGC,cAAKC,GAArB;AACA,MAAMC,WAAW,GAAGF,cAAKG,OAAzB;AACA,MAAMC,QAAQ,GAAGC,eAAMJ,GAAvB;AACA,MAAMK,YAAY,GAAGD,eAAMF,OAA3B;;AAEA,MAAMI,GAAG,GAAGC,gBAAOC,KAAP,CAAa;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BkD,SAA5B,EAAuClB,aAAa,CAACpB,gBAArD,CAAf,CAL0C,CAO1C;;AACAT,mBAAMJ,GAAN,GAAY,+BAAeG,QAAf,EAAyBoD,UAAzB,EAAqCtB,aAAa,CAACpB,gBAAnD,CAAZ,CAR0C,CAU1C;;AACAT,mBAAMF,OAAN,GAAgB,+BAAeG,YAAf,EAA6BkD,UAA7B,EAAyCtB,aAAa,CAACpB,gBAAvD,CAAhB;AACD,GAZD,MAYO;AACLP,IAAAA,GAAG,CAACqD,IAAJ,CAAS,+EAAT;AACD;;AAED,SAAOzB,eAAP;AACD,C","sourcesContent":["// @flow\n\nimport http from 'http';\nimport https from 'https';\nimport {\n  boolean as parseBoolean,\n} from 'boolean';\nimport semver from 'semver';\nimport Logger from '../Logger';\nimport {\n  HttpProxyAgent,\n  HttpsProxyAgent,\n} from '../classes';\nimport {\n  UnexpectedStateError,\n} from '../errors';\nimport {\n  bindHttpMethod,\n  isUrlMatchingNoProxy,\n  parseProxyUrl,\n} from '../utilities';\nimport type {\n  ProxyAgentConfigurationInputType,\n  ProxyAgentConfigurationType,\n} from '../types';\nimport createProxyController from './createProxyController';\n\nconst httpGet = http.get;\nconst httpRequest = http.request;\nconst httpsGet = https.get;\nconst httpsRequest = https.request;\n\nconst log = Logger.child({\n  namespace: 'createGlobalProxyAgent',\n});\n\nconst defaultConfigurationInput = {\n  environmentVariableNamespace: undefined,\n  forceGlobalAgent: undefined,\n  socketConnectionTimeout: 60000,\n};\n\nconst omitUndefined = (subject) => {\n  const keys = Object.keys(subject);\n\n  const result = {};\n\n  for (const key of keys) {\n    const value = subject[key];\n\n    if (value !== undefined) {\n      result[key] = value;\n    }\n  }\n\n  return result;\n};\n\nconst createConfiguration = (configurationInput: ProxyAgentConfigurationInputType): ProxyAgentConfigurationType => {\n  // eslint-disable-next-line no-process-env\n  const environment = process.env;\n\n  const defaultConfiguration = {\n    environmentVariableNamespace: typeof environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE === 'string' ? environment.GLOBAL_AGENT_ENVIRONMENT_VARIABLE_NAMESPACE : 'GLOBAL_AGENT_',\n    forceGlobalAgent: typeof environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT === 'string' ? parseBoolean(environment.GLOBAL_AGENT_FORCE_GLOBAL_AGENT) : true,\n    socketConnectionTimeout: typeof environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT === 'string' ? Number.parseInt(environment.GLOBAL_AGENT_SOCKET_CONNECTION_TIMEOUT, 10) : defaultConfigurationInput.socketConnectionTimeout,\n  };\n\n  // $FlowFixMe\n  return {\n    ...defaultConfiguration,\n    ...omitUndefined(configurationInput),\n  };\n};\n\nexport default (configurationInput: ProxyAgentConfigurationInputType = defaultConfigurationInput) => {\n  const configuration = createConfiguration(configurationInput);\n\n  const proxyController = createProxyController();\n\n  // eslint-disable-next-line no-process-env\n  proxyController.HTTP_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTP_PROXY'] || null;\n\n  // eslint-disable-next-line no-process-env\n  proxyController.HTTPS_PROXY = process.env[configuration.environmentVariableNamespace + 'HTTPS_PROXY'] || null;\n\n  // eslint-disable-next-line no-process-env\n  proxyController.NO_PROXY = process.env[configuration.environmentVariableNamespace + 'NO_PROXY'] || null;\n\n  log.info({\n    configuration,\n    state: proxyController,\n  }, 'global agent has been initialized');\n\n  const mustUrlUseProxy = (getProxy) => {\n    return (url) => {\n      if (!getProxy()) {\n        return false;\n      }\n\n      if (!proxyController.NO_PROXY) {\n        return true;\n      }\n\n      return !isUrlMatchingNoProxy(url, proxyController.NO_PROXY);\n    };\n  };\n\n  const getUrlProxy = (getProxy) => {\n    return () => {\n      const proxy = getProxy();\n\n      if (!proxy) {\n        throw new UnexpectedStateError('HTTP(S) proxy must be configured.');\n      }\n\n      return parseProxyUrl(proxy);\n    };\n  };\n\n  const getHttpProxy = () => {\n    return proxyController.HTTP_PROXY;\n  };\n\n  const BoundHttpProxyAgent = class extends HttpProxyAgent {\n    constructor () {\n      super(\n        () => {\n          return getHttpProxy();\n        },\n        mustUrlUseProxy(getHttpProxy),\n        getUrlProxy(getHttpProxy),\n        http.globalAgent,\n        configuration.socketConnectionTimeout,\n      );\n    }\n  };\n\n  const httpAgent = new BoundHttpProxyAgent();\n\n  const getHttpsProxy = () => {\n    return proxyController.HTTPS_PROXY || proxyController.HTTP_PROXY;\n  };\n\n  const BoundHttpsProxyAgent = class extends HttpsProxyAgent {\n    constructor () {\n      super(\n        () => {\n          return getHttpsProxy();\n        },\n        mustUrlUseProxy(getHttpsProxy),\n        getUrlProxy(getHttpsProxy),\n        https.globalAgent,\n        configuration.socketConnectionTimeout,\n      );\n    }\n  };\n\n  const httpsAgent = new BoundHttpsProxyAgent();\n\n  // Overriding globalAgent was added in v11.7.\n  // @see https://nodejs.org/uk/blog/release/v11.7.0/\n  if (semver.gte(process.version, 'v11.7.0')) {\n    // @see https://github.com/facebook/flow/issues/7670\n    // $FlowFixMe\n    http.globalAgent = httpAgent;\n\n    // $FlowFixMe\n    https.globalAgent = httpsAgent;\n  }\n\n  // The reason this logic is used in addition to overriding http(s).globalAgent\n  // is because there is no guarantee that we set http(s).globalAgent variable\n  // before an instance of http(s).Agent has been already constructed by someone,\n  // e.g. Stripe SDK creates instances of http(s).Agent at the top-level.\n  // @see https://github.com/gajus/global-agent/pull/13\n  //\n  // We still want to override http(s).globalAgent when possible to enable logic\n  // in `bindHttpMethod`.\n  if (semver.gte(process.version, 'v10.0.0')) {\n    // $FlowFixMe\n    http.get = bindHttpMethod(httpGet, httpAgent, configuration.forceGlobalAgent);\n\n    // $FlowFixMe\n    http.request = bindHttpMethod(httpRequest, httpAgent, configuration.forceGlobalAgent);\n\n    // $FlowFixMe\n    https.get = bindHttpMethod(httpsGet, httpsAgent, configuration.forceGlobalAgent);\n\n    // $FlowFixMe\n    https.request = bindHttpMethod(httpsRequest, httpsAgent, configuration.forceGlobalAgent);\n  } else {\n    log.warn('attempt to initialize global-agent in unsupported Node.js version was ignored');\n  }\n\n  return proxyController;\n};\n"],"file":"createGlobalProxyAgent.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/createProxyController.js b/node_modules/global-agent/dist/factories/createProxyController.js deleted file mode 100644 index 7746081..0000000 --- a/node_modules/global-agent/dist/factories/createProxyController.js +++ /dev/null @@ -1,45 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _Logger = _interopRequireDefault(require("../Logger")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const log = _Logger.default.child({ -  namespace: 'createProxyController' -}); - -const KNOWN_PROPERTY_NAMES = ['HTTP_PROXY', 'HTTPS_PROXY', 'NO_PROXY']; - -const createProxyController = () => { -  // eslint-disable-next-line fp/no-proxy -  return new Proxy({ -    HTTP_PROXY: null, -    HTTPS_PROXY: null, -    NO_PROXY: null -  }, { -    set: (subject, name, value) => { -      if (!KNOWN_PROPERTY_NAMES.includes(name)) { -        throw new Error('Cannot set an unmapped property "' + name + '".'); -      } - -      subject[name] = value; -      log.info({ -        change: { -          name, -          value -        }, -        newConfiguration: subject -      }, 'configuration changed'); -      return true; -    } -  }); -}; - -var _default = createProxyController; -exports.default = _default; -//# sourceMappingURL=createProxyController.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/createProxyController.js.flow b/node_modules/global-agent/dist/factories/createProxyController.js.flow deleted file mode 100644 index 5805ec8..0000000 --- a/node_modules/global-agent/dist/factories/createProxyController.js.flow +++ /dev/null @@ -1,46 +0,0 @@ -// @flow - -import Logger from '../Logger'; - -type ProxyControllerType = {| -  HTTP_PROXY: string | null, -  HTTPS_PROXY: string | null, -  NO_PROXY: string | null, -|}; - -const log = Logger.child({ -  namespace: 'createProxyController', -}); - -const KNOWN_PROPERTY_NAMES = [ -  'HTTP_PROXY', -  'HTTPS_PROXY', -  'NO_PROXY', -]; - -export default (): ProxyControllerType => { -  // eslint-disable-next-line fp/no-proxy -  return new Proxy({ -    HTTP_PROXY: null, -    HTTPS_PROXY: null, -    NO_PROXY: null, -  }, { -    set: (subject, name, value) => { -      if (!KNOWN_PROPERTY_NAMES.includes(name)) { -        throw new Error('Cannot set an unmapped property "' + name + '".'); -      } - -      subject[name] = value; - -      log.info({ -        change: { -          name, -          value, -        }, -        newConfiguration: subject, -      }, 'configuration changed'); - -      return true; -    }, -  }); -}; diff --git a/node_modules/global-agent/dist/factories/createProxyController.js.map b/node_modules/global-agent/dist/factories/createProxyController.js.map deleted file mode 100644 index da7b0e7..0000000 --- a/node_modules/global-agent/dist/factories/createProxyController.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/factories/createProxyController.js"],"names":["log","Logger","child","namespace","KNOWN_PROPERTY_NAMES","Proxy","HTTP_PROXY","HTTPS_PROXY","NO_PROXY","set","subject","name","value","includes","Error","info","change","newConfiguration"],"mappings":";;;;;;;AAEA;;;;AAQA,MAAMA,GAAG,GAAGC,gBAAOC,KAAP,CAAa;AACvBC,EAAAA,SAAS,EAAE;AADY,CAAb,CAAZ;;AAIA,MAAMC,oBAAoB,GAAG,CAC3B,YAD2B,EAE3B,aAF2B,EAG3B,UAH2B,CAA7B;;oCAM0C;AACxC;AACA,SAAO,IAAIC,KAAJ,CAAU;AACfC,IAAAA,UAAU,EAAE,IADG;AAEfC,IAAAA,WAAW,EAAE,IAFE;AAGfC,IAAAA,QAAQ,EAAE;AAHK,GAAV,EAIJ;AACDC,IAAAA,GAAG,EAAE,CAACC,OAAD,EAAUC,IAAV,EAAgBC,KAAhB,KAA0B;AAC7B,UAAI,CAACR,oBAAoB,CAACS,QAArB,CAA8BF,IAA9B,CAAL,EAA0C;AACxC,cAAM,IAAIG,KAAJ,CAAU,sCAAsCH,IAAtC,GAA6C,IAAvD,CAAN;AACD;;AAEDD,MAAAA,OAAO,CAACC,IAAD,CAAP,GAAgBC,KAAhB;AAEAZ,MAAAA,GAAG,CAACe,IAAJ,CAAS;AACPC,QAAAA,MAAM,EAAE;AACNL,UAAAA,IADM;AAENC,UAAAA;AAFM,SADD;AAKPK,QAAAA,gBAAgB,EAAEP;AALX,OAAT,EAMG,uBANH;AAQA,aAAO,IAAP;AACD;AAjBA,GAJI,CAAP;AAuBD,C","sourcesContent":["// @flow\n\nimport Logger from '../Logger';\n\ntype ProxyControllerType = {|\n  HTTP_PROXY: string | null,\n  HTTPS_PROXY: string | null,\n  NO_PROXY: string | null,\n|};\n\nconst log = Logger.child({\n  namespace: 'createProxyController',\n});\n\nconst KNOWN_PROPERTY_NAMES = [\n  'HTTP_PROXY',\n  'HTTPS_PROXY',\n  'NO_PROXY',\n];\n\nexport default (): ProxyControllerType => {\n  // eslint-disable-next-line fp/no-proxy\n  return new Proxy({\n    HTTP_PROXY: null,\n    HTTPS_PROXY: null,\n    NO_PROXY: null,\n  }, {\n    set: (subject, name, value) => {\n      if (!KNOWN_PROPERTY_NAMES.includes(name)) {\n        throw new Error('Cannot set an unmapped property \"' + name + '\".');\n      }\n\n      subject[name] = value;\n\n      log.info({\n        change: {\n          name,\n          value,\n        },\n        newConfiguration: subject,\n      }, 'configuration changed');\n\n      return true;\n    },\n  });\n};\n"],"file":"createProxyController.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/index.js b/node_modules/global-agent/dist/factories/index.js deleted file mode 100644 index 3193022..0000000 --- a/node_modules/global-agent/dist/factories/index.js +++ /dev/null @@ -1,24 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -Object.defineProperty(exports, "createGlobalProxyAgent", { -  enumerable: true, -  get: function () { -    return _createGlobalProxyAgent.default; -  } -}); -Object.defineProperty(exports, "createProxyController", { -  enumerable: true, -  get: function () { -    return _createProxyController.default; -  } -}); - -var _createGlobalProxyAgent = _interopRequireDefault(require("./createGlobalProxyAgent")); - -var _createProxyController = _interopRequireDefault(require("./createProxyController")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/factories/index.js.flow b/node_modules/global-agent/dist/factories/index.js.flow deleted file mode 100644 index c16eca6..0000000 --- a/node_modules/global-agent/dist/factories/index.js.flow +++ /dev/null @@ -1,4 +0,0 @@ -// @flow - -export {default as createGlobalProxyAgent} from './createGlobalProxyAgent'; -export {default as createProxyController} from './createProxyController'; diff --git a/node_modules/global-agent/dist/factories/index.js.map b/node_modules/global-agent/dist/factories/index.js.map deleted file mode 100644 index 2e61240..0000000 --- a/node_modules/global-agent/dist/factories/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/factories/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAEA;;AACA","sourcesContent":["// @flow\n\nexport {default as createGlobalProxyAgent} from './createGlobalProxyAgent';\nexport {default as createProxyController} from './createProxyController';\n"],"file":"index.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/index.js b/node_modules/global-agent/dist/index.js deleted file mode 100644 index 242a88a..0000000 --- a/node_modules/global-agent/dist/index.js +++ /dev/null @@ -1,22 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -Object.defineProperty(exports, "bootstrap", { -  enumerable: true, -  get: function () { -    return _routines.bootstrap; -  } -}); -Object.defineProperty(exports, "createGlobalProxyAgent", { -  enumerable: true, -  get: function () { -    return _factories.createGlobalProxyAgent; -  } -}); - -var _routines = require("./routines"); - -var _factories = require("./factories"); -//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/index.js.flow b/node_modules/global-agent/dist/index.js.flow deleted file mode 100644 index 14da1ba..0000000 --- a/node_modules/global-agent/dist/index.js.flow +++ /dev/null @@ -1,4 +0,0 @@ -// @flow - -export {bootstrap} from './routines'; -export {createGlobalProxyAgent} from './factories'; diff --git a/node_modules/global-agent/dist/index.js.map b/node_modules/global-agent/dist/index.js.map deleted file mode 100644 index 42901df..0000000 --- a/node_modules/global-agent/dist/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../src/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAEA;;AACA","sourcesContent":["// @flow\n\nexport {bootstrap} from './routines';\nexport {createGlobalProxyAgent} from './factories';\n"],"file":"index.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/routines/bootstrap.js b/node_modules/global-agent/dist/routines/bootstrap.js deleted file mode 100644 index 444df53..0000000 --- a/node_modules/global-agent/dist/routines/bootstrap.js +++ /dev/null @@ -1,30 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _Logger = _interopRequireDefault(require("../Logger")); - -var _factories = require("../factories"); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const log = _Logger.default.child({ -  namespace: 'bootstrap' -}); - -const bootstrap = configurationInput => { -  if (global.GLOBAL_AGENT) { -    log.warn('found global.GLOBAL_AGENT; second attempt to bootstrap global-agent was ignored'); -    return false; -  } - -  global.GLOBAL_AGENT = (0, _factories.createGlobalProxyAgent)(configurationInput); -  return true; -}; - -var _default = bootstrap; -exports.default = _default; -//# sourceMappingURL=bootstrap.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/routines/bootstrap.js.flow b/node_modules/global-agent/dist/routines/bootstrap.js.flow deleted file mode 100644 index 038feb3..0000000 --- a/node_modules/global-agent/dist/routines/bootstrap.js.flow +++ /dev/null @@ -1,25 +0,0 @@ -// @flow - -import Logger from '../Logger'; -import { -  createGlobalProxyAgent, -} from '../factories'; -import type { -  ProxyAgentConfigurationInputType, -} from '../types'; - -const log = Logger.child({ -  namespace: 'bootstrap', -}); - -export default (configurationInput?: ProxyAgentConfigurationInputType): boolean => { -  if (global.GLOBAL_AGENT) { -    log.warn('found global.GLOBAL_AGENT; second attempt to bootstrap global-agent was ignored'); - -    return false; -  } - -  global.GLOBAL_AGENT = createGlobalProxyAgent(configurationInput); - -  return true; -}; diff --git a/node_modules/global-agent/dist/routines/bootstrap.js.map b/node_modules/global-agent/dist/routines/bootstrap.js.map deleted file mode 100644 index 84bbf79..0000000 --- a/node_modules/global-agent/dist/routines/bootstrap.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/routines/bootstrap.js"],"names":["log","Logger","child","namespace","configurationInput","global","GLOBAL_AGENT","warn"],"mappings":";;;;;;;AAEA;;AACA;;;;AAOA,MAAMA,GAAG,GAAGC,gBAAOC,KAAP,CAAa;AACvBC,EAAAA,SAAS,EAAE;AADY,CAAb,CAAZ;;kBAIgBC,kB,IAAmE;AACjF,MAAIC,MAAM,CAACC,YAAX,EAAyB;AACvBN,IAAAA,GAAG,CAACO,IAAJ,CAAS,iFAAT;AAEA,WAAO,KAAP;AACD;;AAEDF,EAAAA,MAAM,CAACC,YAAP,GAAsB,uCAAuBF,kBAAvB,CAAtB;AAEA,SAAO,IAAP;AACD,C","sourcesContent":["// @flow\n\nimport Logger from '../Logger';\nimport {\n  createGlobalProxyAgent,\n} from '../factories';\nimport type {\n  ProxyAgentConfigurationInputType,\n} from '../types';\n\nconst log = Logger.child({\n  namespace: 'bootstrap',\n});\n\nexport default (configurationInput?: ProxyAgentConfigurationInputType): boolean => {\n  if (global.GLOBAL_AGENT) {\n    log.warn('found global.GLOBAL_AGENT; second attempt to bootstrap global-agent was ignored');\n\n    return false;\n  }\n\n  global.GLOBAL_AGENT = createGlobalProxyAgent(configurationInput);\n\n  return true;\n};\n"],"file":"bootstrap.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/routines/index.js b/node_modules/global-agent/dist/routines/index.js deleted file mode 100644 index 2ae1be2..0000000 --- a/node_modules/global-agent/dist/routines/index.js +++ /dev/null @@ -1,16 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -Object.defineProperty(exports, "bootstrap", { -  enumerable: true, -  get: function () { -    return _bootstrap.default; -  } -}); - -var _bootstrap = _interopRequireDefault(require("./bootstrap")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/routines/index.js.flow b/node_modules/global-agent/dist/routines/index.js.flow deleted file mode 100644 index e47a8a0..0000000 --- a/node_modules/global-agent/dist/routines/index.js.flow +++ /dev/null @@ -1,3 +0,0 @@ -// @flow - -export {default as bootstrap} from './bootstrap'; diff --git a/node_modules/global-agent/dist/routines/index.js.map b/node_modules/global-agent/dist/routines/index.js.map deleted file mode 100644 index 97295d9..0000000 --- a/node_modules/global-agent/dist/routines/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/routines/index.js"],"names":[],"mappings":";;;;;;;;;;;;AAEA","sourcesContent":["// @flow\n\nexport {default as bootstrap} from './bootstrap';\n"],"file":"index.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/types.js b/node_modules/global-agent/dist/types.js deleted file mode 100644 index fb07a95..0000000 --- a/node_modules/global-agent/dist/types.js +++ /dev/null @@ -1,10 +0,0 @@ -"use strict"; - -var _net = require("net"); - -var _tls = require("tls"); - -var _http = require("http"); - -var _https = require("https"); -//# sourceMappingURL=types.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/types.js.flow b/node_modules/global-agent/dist/types.js.flow deleted file mode 100644 index e2f1a99..0000000 --- a/node_modules/global-agent/dist/types.js.flow +++ /dev/null @@ -1,66 +0,0 @@ -// @flow - -import { -  Socket, -} from 'net'; -import { -  TLSSocket, -} from 'tls'; -import { -  Agent as HttpAgent, -} from 'http'; -import { -  Agent as HttpsAgent, -} from 'https'; - -export type ProxyConfigurationType = {| -  +authorization: string, -  +hostname: string, -  +port: number, -|}; - -export type TlsConfigurationType = {| -  +ca?: string, -  +cert?: string, -  +ciphers?: string, -  +clientCertEngine?: string, -  +crl?: string, -  +dhparam?: string, -  +ecdhCurve?: string, -  +honorCipherOrder?: boolean, -  +key?: string, -  +passphrase?: string, -  +pfx?: string, -  +rejectUnauthorized?: boolean, -  +secureOptions?: number, -  +secureProtocol?: string, -  +servername?: string, -  +sessionIdContext?: string, -|}; - -export type ConnectionConfigurationType = {| -  +host: string, -  +port: number, -  +tls?: TlsConfigurationType, -  +proxy: ProxyConfigurationType, -|}; - -export type ConnectionCallbackType = (error: Error | null, socket?: Socket | TLSSocket) => void; - -export type AgentType = HttpAgent | HttpsAgent; -export type IsProxyConfiguredMethodType = () => boolean; -export type MustUrlUseProxyMethodType = (url: string) => boolean; -export type GetUrlProxyMethodType = (url: string) => ProxyConfigurationType; -export type ProtocolType = 'http:' | 'https:'; - -export type ProxyAgentConfigurationInputType = {| -  +environmentVariableNamespace?: string, -  +forceGlobalAgent?: boolean, -  +socketConnectionTimeout?: number, -|}; - -export type ProxyAgentConfigurationType = {| -  +environmentVariableNamespace: string, -  +forceGlobalAgent: boolean, -  +socketConnectionTimeout: number, -|}; diff --git a/node_modules/global-agent/dist/types.js.map b/node_modules/global-agent/dist/types.js.map deleted file mode 100644 index 46e65bc..0000000 --- a/node_modules/global-agent/dist/types.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../src/types.js"],"names":[],"mappings":";;AAEA;;AAGA;;AAGA;;AAGA","sourcesContent":["// @flow\n\nimport {\n  Socket,\n} from 'net';\nimport {\n  TLSSocket,\n} from 'tls';\nimport {\n  Agent as HttpAgent,\n} from 'http';\nimport {\n  Agent as HttpsAgent,\n} from 'https';\n\nexport type ProxyConfigurationType = {|\n  +authorization: string,\n  +hostname: string,\n  +port: number,\n|};\n\nexport type TlsConfigurationType = {|\n  +ca?: string,\n  +cert?: string,\n  +ciphers?: string,\n  +clientCertEngine?: string,\n  +crl?: string,\n  +dhparam?: string,\n  +ecdhCurve?: string,\n  +honorCipherOrder?: boolean,\n  +key?: string,\n  +passphrase?: string,\n  +pfx?: string,\n  +rejectUnauthorized?: boolean,\n  +secureOptions?: number,\n  +secureProtocol?: string,\n  +servername?: string,\n  +sessionIdContext?: string,\n|};\n\nexport type ConnectionConfigurationType = {|\n  +host: string,\n  +port: number,\n  +tls?: TlsConfigurationType,\n  +proxy: ProxyConfigurationType,\n|};\n\nexport type ConnectionCallbackType = (error: Error | null, socket?: Socket | TLSSocket) => void;\n\nexport type AgentType = HttpAgent | HttpsAgent;\nexport type IsProxyConfiguredMethodType = () => boolean;\nexport type MustUrlUseProxyMethodType = (url: string) => boolean;\nexport type GetUrlProxyMethodType = (url: string) => ProxyConfigurationType;\nexport type ProtocolType = 'http:' | 'https:';\n\nexport type ProxyAgentConfigurationInputType = {|\n  +environmentVariableNamespace?: string,\n  +forceGlobalAgent?: boolean,\n  +socketConnectionTimeout?: number,\n|};\n\nexport type ProxyAgentConfigurationType = {|\n  +environmentVariableNamespace: string,\n  +forceGlobalAgent: boolean,\n  +socketConnectionTimeout: number,\n|};\n"],"file":"types.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/bindHttpMethod.js b/node_modules/global-agent/dist/utilities/bindHttpMethod.js deleted file mode 100644 index 4ce571a..0000000 --- a/node_modules/global-agent/dist/utilities/bindHttpMethod.js +++ /dev/null @@ -1,62 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _http = _interopRequireDefault(require("http")); - -var _https = _interopRequireDefault(require("https")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -// eslint-disable-next-line flowtype/no-weak-types -const bindHttpMethod = (originalMethod, agent, forceGlobalAgent) => { -  // eslint-disable-next-line unicorn/prevent-abbreviations -  return (...args) => { -    let url; -    let options; -    let callback; - -    if (typeof args[0] === 'string' || args[0] instanceof URL) { -      url = args[0]; - -      if (typeof args[1] === 'function') { -        options = {}; -        callback = args[1]; -      } else { -        options = { ...args[1] -        }; -        callback = args[2]; -      } -    } else { -      options = { ...args[0] -      }; -      callback = args[1]; -    } - -    if (forceGlobalAgent) { -      options.agent = agent; -    } else { -      if (!options.agent) { -        options.agent = agent; -      } - -      if (options.agent === _http.default.globalAgent || options.agent === _https.default.globalAgent) { -        options.agent = agent; -      } -    } - -    if (url) { -      // $FlowFixMe -      return originalMethod(url, options, callback); -    } else { -      return originalMethod(options, callback); -    } -  }; -}; - -var _default = bindHttpMethod; -exports.default = _default; -//# sourceMappingURL=bindHttpMethod.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/bindHttpMethod.js.flow b/node_modules/global-agent/dist/utilities/bindHttpMethod.js.flow deleted file mode 100644 index f8859b5..0000000 --- a/node_modules/global-agent/dist/utilities/bindHttpMethod.js.flow +++ /dev/null @@ -1,54 +0,0 @@ -// @flow - -import http from 'http'; -import https from 'https'; - -type AgentType = http.Agent | https.Agent; - -// eslint-disable-next-line flowtype/no-weak-types -export default (originalMethod: Function, agent: AgentType, forceGlobalAgent: boolean) => { -  // eslint-disable-next-line unicorn/prevent-abbreviations -  return (...args: *) => { -    let url; -    let options; -    let callback; - -    if (typeof args[0] === 'string' || args[0] instanceof URL) { -      url = args[0]; - -      if (typeof args[1] === 'function') { -        options = {}; -        callback = args[1]; -      } else { -        options = { -          ...args[1], -        }; -        callback = args[2]; -      } -    } else { -      options = { -        ...args[0], -      }; -      callback = args[1]; -    } - -    if (forceGlobalAgent) { -      options.agent = agent; -    } else { -      if (!options.agent) { -        options.agent = agent; -      } - -      if (options.agent === http.globalAgent || options.agent === https.globalAgent) { -        options.agent = agent; -      } -    } - -    if (url) { -      // $FlowFixMe -      return originalMethod(url, options, callback); -    } else { -      return originalMethod(options, callback); -    } -  }; -}; diff --git a/node_modules/global-agent/dist/utilities/bindHttpMethod.js.map b/node_modules/global-agent/dist/utilities/bindHttpMethod.js.map deleted file mode 100644 index 0d49171..0000000 --- a/node_modules/global-agent/dist/utilities/bindHttpMethod.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/utilities/bindHttpMethod.js"],"names":["originalMethod","agent","forceGlobalAgent","args","url","options","callback","URL","http","globalAgent","https"],"mappings":";;;;;;;AAEA;;AACA;;;;AAIA;w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AAc,CAACK,OAAD,EAAUC,QAAV,CAArB;AACD;AACF,GA1CD;AA2CD,C","sourcesContent":["// @flow\n\nimport http from 'http';\nimport https from 'https';\n\ntype AgentType = http.Agent | https.Agent;\n\n// eslint-disable-next-line flowtype/no-weak-types\nexport default (originalMethod: Function, agent: AgentType, forceGlobalAgent: boolean) => {\n  // eslint-disable-next-line unicorn/prevent-abbreviations\n  return (...args: *) => {\n    let url;\n    let options;\n    let callback;\n\n    if (typeof args[0] === 'string' || args[0] instanceof URL) {\n      url = args[0];\n\n      if (typeof args[1] === 'function') {\n        options = {};\n        callback = args[1];\n      } else {\n        options = {\n          ...args[1],\n        };\n        callback = args[2];\n      }\n    } else {\n      options = {\n        ...args[0],\n      };\n      callback = args[1];\n    }\n\n    if (forceGlobalAgent) {\n      options.agent = agent;\n    } else {\n      if (!options.agent) {\n        options.agent = agent;\n      }\n\n      if (options.agent === http.globalAgent || options.agent === https.globalAgent) {\n        options.agent = agent;\n      }\n    }\n\n    if (url) {\n      // $FlowFixMe\n      return originalMethod(url, options, callback);\n    } else {\n      return originalMethod(options, callback);\n    }\n  };\n};\n"],"file":"bindHttpMethod.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/index.js b/node_modules/global-agent/dist/utilities/index.js deleted file mode 100644 index 5b9ff43..0000000 --- a/node_modules/global-agent/dist/utilities/index.js +++ /dev/null @@ -1,32 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -Object.defineProperty(exports, "bindHttpMethod", { -  enumerable: true, -  get: function () { -    return _bindHttpMethod.default; -  } -}); -Object.defineProperty(exports, "isUrlMatchingNoProxy", { -  enumerable: true, -  get: function () { -    return _isUrlMatchingNoProxy.default; -  } -}); -Object.defineProperty(exports, "parseProxyUrl", { -  enumerable: true, -  get: function () { -    return _parseProxyUrl.default; -  } -}); - -var _bindHttpMethod = _interopRequireDefault(require("./bindHttpMethod")); - -var _isUrlMatchingNoProxy = _interopRequireDefault(require("./isUrlMatchingNoProxy")); - -var _parseProxyUrl = _interopRequireDefault(require("./parseProxyUrl")); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } -//# sourceMappingURL=index.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/index.js.flow b/node_modules/global-agent/dist/utilities/index.js.flow deleted file mode 100644 index 3412387..0000000 --- a/node_modules/global-agent/dist/utilities/index.js.flow +++ /dev/null @@ -1,5 +0,0 @@ -// @flow - -export {default as bindHttpMethod} from './bindHttpMethod'; -export {default as isUrlMatchingNoProxy} from './isUrlMatchingNoProxy'; -export {default as parseProxyUrl} from './parseProxyUrl'; diff --git a/node_modules/global-agent/dist/utilities/index.js.map b/node_modules/global-agent/dist/utilities/index.js.map deleted file mode 100644 index 6861a5a..0000000 --- a/node_modules/global-agent/dist/utilities/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/utilities/index.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAEA;;AACA;;AACA","sourcesContent":["// @flow\n\nexport {default as bindHttpMethod} from './bindHttpMethod';\nexport {default as isUrlMatchingNoProxy} from './isUrlMatchingNoProxy';\nexport {default as parseProxyUrl} from './parseProxyUrl';\n"],"file":"index.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js b/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js deleted file mode 100644 index 92a3436..0000000 --- a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js +++ /dev/null @@ -1,43 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _url = require("url"); - -var _matcher = _interopRequireDefault(require("matcher")); - -var _errors = require("../errors"); - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -const isUrlMatchingNoProxy = (subjectUrl, noProxy) => { -  const subjectUrlTokens = (0, _url.parse)(subjectUrl); -  const rules = noProxy.split(/[\s,]+/); - -  for (const rule of rules) { -    const ruleMatch = rule.replace(/^(?<leadingDot>\.)/, '*').match(/^(?<hostname>.+?)(?::(?<port>\d+))?$/); - -    if (!ruleMatch || !ruleMatch.groups) { -      throw new _errors.UnexpectedStateError('Invalid NO_PROXY pattern.'); -    } - -    if (!ruleMatch.groups.hostname) { -      throw new _errors.UnexpectedStateError('NO_PROXY entry pattern must include hostname. Use * to match any hostname.'); -    } - -    const hostnameIsMatch = _matcher.default.isMatch(subjectUrlTokens.hostname, ruleMatch.groups.hostname); - -    if (hostnameIsMatch && (!ruleMatch.groups || !ruleMatch.groups.port || subjectUrlTokens.port && subjectUrlTokens.port === ruleMatch.groups.port)) { -      return true; -    } -  } - -  return false; -}; - -var _default = isUrlMatchingNoProxy; -exports.default = _default; -//# sourceMappingURL=isUrlMatchingNoProxy.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.flow b/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.flow deleted file mode 100644 index f2de584..0000000 --- a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.flow +++ /dev/null @@ -1,37 +0,0 @@ -// @flow - -import { -  parse as parseUrl, -} from 'url'; -import matcher from 'matcher'; -import { -  UnexpectedStateError, -} from '../errors'; - -export default (subjectUrl: string, noProxy: string) => { -  const subjectUrlTokens = parseUrl(subjectUrl); - -  const rules = noProxy.split(/[\s,]+/); - -  for (const rule of rules) { -    const ruleMatch = rule -      .replace(/^(?<leadingDot>\.)/, '*') -      .match(/^(?<hostname>.+?)(?::(?<port>\d+))?$/); - -    if (!ruleMatch || !ruleMatch.groups) { -      throw new UnexpectedStateError('Invalid NO_PROXY pattern.'); -    } - -    if (!ruleMatch.groups.hostname) { -      throw new UnexpectedStateError('NO_PROXY entry pattern must include hostname. Use * to match any hostname.'); -    } - -    const hostnameIsMatch = matcher.isMatch(subjectUrlTokens.hostname, ruleMatch.groups.hostname); - -    if (hostnameIsMatch && (!ruleMatch.groups || !ruleMatch.groups.port || subjectUrlTokens.port && subjectUrlTokens.port === ruleMatch.groups.port)) { -      return true; -    } -  } - -  return false; -}; diff --git a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.map b/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.map deleted file mode 100644 index 9f60970..0000000 --- a/node_modules/global-agent/dist/utilities/isUrlMatchingNoProxy.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/utilities/isUrlMatchingNoProxy.js"],"names":["subjectUrl","noProxy","subjectUrlTokens","rules","split","rule","ruleMatch","replace","match","groups","UnexpectedStateError","hostname","hostnameIsMatch","matcher","isMatch","port"],"mappings":";;;;;;;AAEA;;AAGA;;AACA;;;;8BAIgBA,U,EAAoBC,O,KAAoB;AACtD,QAAMC,gBAAgB,GAAG,gBAASF,UAAT,CAAzB;AAEA,QAAMG,KAAK,GAAGF,OAAO,CAACG,KAAR,CAAc,QAAd,CAAd;;AAEA,OAAK,MAAMC,IAAX,IAAmBF,KAAnB,EAA0B;AACxB,UAAMG,SAAS,GAAGD,IAAI,CACnBE,OADe,CACP,oBADO,EACe,GADf,EAEfC,KAFe,CAET,sCAFS,CAAlB;;AAIA,QAAI,CAACF,SAAD,IAAc,CAACA,SAAS,CAACG,MAA7B,EAAqC;AACnC,YAAM,IAAIC,4BAAJ,CAAyB,2BAAzB,CAAN;AACD;;AAED,QAAI,CAACJ,SAAS,CAACG,MAAV,CAAiBE,QAAtB,EAAgC;AAC9B,YAAM,IAAID,4BAAJ,CAAyB,4EAAzB,CAAN;AACD;;AAED,UAAME,eAAe,GAAGC,iBAAQC,OAAR,CAAgBZ,gBAAgB,CAACS,QAAjC,EAA2CL,SAAS,CAACG,MAAV,CAAiBE,QAA5D,CAAxB;;AAEA,QAAIC,eAAe,KAAK,CAACN,SAAS,CAACG,MAAX,IAAqB,CAACH,SAAS,CAACG,MAAV,CAAiBM,IAAvC,IAA+Cb,gBAAgB,CAACa,IAAjB,IAAyBb,gBAAgB,CAACa,IAAjB,KAA0BT,SAAS,CAACG,MAAV,CAAiBM,IAAxH,CAAnB,EAAkJ;AAChJ,aAAO,IAAP;AACD;AACF;;AAED,SAAO,KAAP;AACD,C","sourcesContent":["// @flow\n\nimport {\n  parse as parseUrl,\n} from 'url';\nimport matcher from 'matcher';\nimport {\n  UnexpectedStateError,\n} from '../errors';\n\nexport default (subjectUrl: string, noProxy: string) => {\n  const subjectUrlTokens = parseUrl(subjectUrl);\n\n  const rules = noProxy.split(/[\\s,]+/);\n\n  for (const rule of rules) {\n    const ruleMatch = rule\n      .replace(/^(?<leadingDot>\\.)/, '*')\n      .match(/^(?<hostname>.+?)(?::(?<port>\\d+))?$/);\n\n    if (!ruleMatch || !ruleMatch.groups) {\n      throw new UnexpectedStateError('Invalid NO_PROXY pattern.');\n    }\n\n    if (!ruleMatch.groups.hostname) {\n      throw new UnexpectedStateError('NO_PROXY entry pattern must include hostname. Use * to match any hostname.');\n    }\n\n    const hostnameIsMatch = matcher.isMatch(subjectUrlTokens.hostname, ruleMatch.groups.hostname);\n\n    if (hostnameIsMatch && (!ruleMatch.groups || !ruleMatch.groups.port || subjectUrlTokens.port && subjectUrlTokens.port === ruleMatch.groups.port)) {\n      return true;\n    }\n  }\n\n  return false;\n};\n"],"file":"isUrlMatchingNoProxy.js"}
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/parseProxyUrl.js b/node_modules/global-agent/dist/utilities/parseProxyUrl.js deleted file mode 100644 index e4f1185..0000000 --- a/node_modules/global-agent/dist/utilities/parseProxyUrl.js +++ /dev/null @@ -1,42 +0,0 @@ -"use strict"; - -Object.defineProperty(exports, "__esModule", { -  value: true -}); -exports.default = void 0; - -var _url = require("url"); - -var _errors = require("../errors"); - -const parseProxyUrl = url => { -  const urlTokens = (0, _url.parse)(url); - -  if (urlTokens.query !== null) { -    throw new _errors.UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have query.'); -  } - -  if (urlTokens.hash !== null) { -    throw new _errors.UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have hash.'); -  } - -  if (urlTokens.protocol !== 'http:') { -    throw new _errors.UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL protocol must be "http:".'); -  } - -  let port = 80; - -  if (urlTokens.port) { -    port = Number.parseInt(urlTokens.port, 10); -  } - -  return { -    authorization: urlTokens.auth || null, -    hostname: urlTokens.hostname, -    port -  }; -}; - -var _default = parseProxyUrl; -exports.default = _default; -//# sourceMappingURL=parseProxyUrl.js.map
\ No newline at end of file diff --git a/node_modules/global-agent/dist/utilities/parseProxyUrl.js.flow b/node_modules/global-agent/dist/utilities/parseProxyUrl.js.flow deleted file mode 100644 index e2e9a6b..0000000 --- a/node_modules/global-agent/dist/utilities/parseProxyUrl.js.flow +++ /dev/null @@ -1,36 +0,0 @@ -// @flow - -import { -  parse as parseUrl, -} from 'url'; -import { -  UnexpectedStateError, -} from '../errors'; - -export default (url: string) => { -  const urlTokens = parseUrl(url); - -  if (urlTokens.query !== null) { -    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have query.'); -  } - -  if (urlTokens.hash !== null) { -    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have hash.'); -  } - -  if (urlTokens.protocol !== 'http:') { -    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL protocol must be "http:".'); -  } - -  let port = 80; - -  if (urlTokens.port) { -    port = Number.parseInt(urlTokens.port, 10); -  } - -  return { -    authorization: urlTokens.auth || null, -    hostname: urlTokens.hostname, -    port, -  }; -}; diff --git a/node_modules/global-agent/dist/utilities/parseProxyUrl.js.map b/node_modules/global-agent/dist/utilities/parseProxyUrl.js.map deleted file mode 100644 index 4457f10..0000000 --- a/node_modules/global-agent/dist/utilities/parseProxyUrl.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../src/utilities/parseProxyUrl.js"],"names":["url","urlTokens","query","UnexpectedStateError","hash","protocol","port","Number","parseInt","authorization","auth","hostname"],"mappings":";;;;;;;AAEA;;AAGA;;sBAIgBA,G,IAAgB;AAC9B,QAAMC,SAAS,GAAG,gBAASD,GAAT,CAAlB;;AAEA,MAAIC,SAAS,CAACC,KAAV,KAAoB,IAAxB,EAA8B;AAC5B,UAAM,IAAIC,4BAAJ,CAAyB,qFAAzB,CAAN;AACD;;AAED,MAAIF,SAAS,CAACG,IAAV,KAAmB,IAAvB,EAA6B;AAC3B,UAAM,IAAID,4BAAJ,CAAyB,oFAAzB,CAAN;AACD;;AAED,MAAIF,SAAS,CAACI,QAAV,KAAuB,OAA3B,EAAoC;AAClC,UAAM,IAAIF,4BAAJ,CAAyB,0FAAzB,CAAN;AACD;;AAED,MAAIG,IAAI,GAAG,EAAX;;AAEA,MAAIL,SAAS,CAACK,IAAd,EAAoB;AAClBA,IAAAA,IAAI,GAAGC,MAAM,CAACC,QAAP,CAAgBP,SAAS,CAACK,IAA1B,EAAgC,EAAhC,CAAP;AACD;;AAED,SAAO;AACLG,IAAAA,aAAa,EAAER,SAAS,CAACS,IAAV,IAAkB,IAD5B;AAELC,IAAAA,QAAQ,EAAEV,SAAS,CAACU,QAFf;AAGLL,IAAAA;AAHK,GAAP;AAKD,C","sourcesContent":["// @flow\n\nimport {\n  parse as parseUrl,\n} from 'url';\nimport {\n  UnexpectedStateError,\n} from '../errors';\n\nexport default (url: string) => {\n  const urlTokens = parseUrl(url);\n\n  if (urlTokens.query !== null) {\n    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have query.');\n  }\n\n  if (urlTokens.hash !== null) {\n    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL must not have hash.');\n  }\n\n  if (urlTokens.protocol !== 'http:') {\n    throw new UnexpectedStateError('Unsupported `GLOBAL_AGENT.HTTP_PROXY` configuration value: URL protocol must be \"http:\".');\n  }\n\n  let port = 80;\n\n  if (urlTokens.port) {\n    port = Number.parseInt(urlTokens.port, 10);\n  }\n\n  return {\n    authorization: urlTokens.auth || null,\n    hostname: urlTokens.hostname,\n    port,\n  };\n};\n"],"file":"parseProxyUrl.js"}
\ No newline at end of file | 
