Support a proxy mode for outbound HTTP and HTTPS traffic #83

Closed
ozten opened this Issue Jun 27, 2012 · 5 comments

Comments

Projects
None yet
2 participants
@ozten
Contributor

ozten commented Jun 27, 2012

Please consider adding support for a HTTP proxy everywhere node-openid uses the http or https node module.

Suggested API:
node-openid would look for an environment variable HTTP_PROXY and if present, respect it.

Example:

export HTTP_PROXY=http://localhost:8080
node bin/server

Use Cases:

  1. Security and Performance
    When we deploy services, we put them behind squid or another proxy layer. This allows us to deny outbound http requests to unknown urls. It allows us to locally cache OpenID responses (for the calls that are cachable).

  2. Load Testing
    We're looking at also using this setting for load testing, so we don't hit 3rd party OpenID endpoints.

ozten added a commit to ozten/node-openid that referenced this issue Jun 28, 2012

ozten added a commit to ozten/node-openid that referenced this issue Jun 28, 2012

@havard

This comment has been minimized.

Show comment
Hide comment
@havard

havard Jul 5, 2012

Owner

I have been gathering opinions on the matter through the nodejs mailing list and discussions with various developers. The environment variable proposal seems to be a good solution.

One suggestion though: How about splitting HTTP_PROXY into HTTP_PROXY_HOST and HTTP_PROXY_PORT (and add HTTPS_ variants)? This will align the settings with other existing solutions (notably Java).

Owner

havard commented Jul 5, 2012

I have been gathering opinions on the matter through the nodejs mailing list and discussions with various developers. The environment variable proposal seems to be a good solution.

One suggestion though: How about splitting HTTP_PROXY into HTTP_PROXY_HOST and HTTP_PROXY_PORT (and add HTTPS_ variants)? This will align the settings with other existing solutions (notably Java).

@ozten

This comment has been minimized.

Show comment
Hide comment
@ozten

ozten Jul 5, 2012

Contributor

Thanks for looking into this and coordinating with the broader community.

It would be good to use the same solution across this and node-oauth.
ciaranj/node-oauth#102

I'm fine with These env variables. I'll update my fork once I'm back from traveling.

I've also found separating HTTP and HTTPS settings useful.

Contributor

ozten commented Jul 5, 2012

Thanks for looking into this and coordinating with the broader community.

It would be good to use the same solution across this and node-oauth.
ciaranj/node-oauth#102

I'm fine with These env variables. I'll update my fork once I'm back from traveling.

I've also found separating HTTP and HTTPS settings useful.

@havard

This comment has been minimized.

Show comment
Hide comment
@havard

havard Jul 20, 2012

Owner

Merged and fixed in ead2635

Owner

havard commented Jul 20, 2012

Merged and fixed in ead2635

@havard havard closed this Jul 20, 2012

@ozten

This comment has been minimized.

Show comment
Hide comment
@ozten

ozten Jul 20, 2012

Contributor

This is great, thanks again! Any timelines for a 0.4.3 release?

Contributor

ozten commented Jul 20, 2012

This is great, thanks again! Any timelines for a 0.4.3 release?

@havard

This comment has been minimized.

Show comment
Hide comment
@havard

havard Jul 20, 2012

Owner

I am gonna let it sit for a few days and see if anyone reports problems, then make a release.

Owner

havard commented Jul 20, 2012

I am gonna let it sit for a few days and see if anyone reports problems, then make a release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment