ruby / ruby/net-http

Feature Request: Add support for SSL settings for SSL proxies

Offen
#209 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
Ruby
Sterne
148
Forks
95
Ø Merge
10 Std. 54 Min.
Gemergte PRs (30 T.)
4

Beschreibung

https://github.com/ruby/net-http/pull/55 added support for HTTPS proxies, which is a nice feature. In that MR the lack of ability to set verification settings was called out as improvement point, but wasn't a blocker. I believe being able to pass SSL settings to the Proxy socket is needed. As outbound proxies are almost always internal to an org, it's quite likely they will use an internal CA, or possibly require mutual TLS. In both these cases being able to pass CA files or key settings to the SSL socket is either very nice, or required. Unless the proxy uses a publicly trusted cert, the only option is to build the internal cert into the host level CA config. Mutual TLS isn't possible.

This has tripped my attempt to use this feature, and I think users of libraries leveraging this will be confused that the endpoint level SSL settings, like specifying a CA bundle, don't apply to the proxy SSL connection.

As an aside, I also think that the argument list to Net::HTTP.new is getting a bit cumbersome. When using a HTTPS Proxy that doesn't require auth it's likely the Net::HTTP.new will look something like: Net::HTTP.new(endpoint.host, endpoint.port, proxy.host, proxy.port, nil, nil, nil, true). I think for this level of advanced config kwargs might be more manageable or instance attributes, like .use_ssl=.

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginne beim Einstiegspunkt Net::HTTP.new und der HTTPS-Proxy-Behandlung, die durch ruby/net-http#55 hinzugefügt wurde. Verfolge, wie der SSL-Socket des Proxys konfiguriert wird, und identifiziere die vorhandenen SSL-Einstellungen des Endpunkts, die ihn nicht erreichen. Erledigt ist die Aufgabe, wenn proxy-spezifische CA- und Client-Key-Einstellungen angegeben werden können und das Verhalten durch die relevanten Tests abgedeckt ist.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
ruby
Bereich
networking
Issue-Typ
Feature
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.