From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS4713 221.184.0.0/13 X-Spam-Status: No, score=-2.6 required=3.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FORGED_GMAIL_RCVD,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS shortcircuit=no autolearn=no autolearn_force=no version=3.4.2 Received: from neon.ruby-lang.org (neon.ruby-lang.org [221.186.184.75]) by dcvr.yhbt.net (Postfix) with ESMTP id B57F51F461 for ; Mon, 19 Aug 2019 01:44:35 +0000 (UTC) Received: from neon.ruby-lang.org (localhost [IPv6:::1]) by neon.ruby-lang.org (Postfix) with ESMTP id 3CFAB120A45; Mon, 19 Aug 2019 10:44:27 +0900 (JST) Received: from o1678916x28.outbound-mail.sendgrid.net (o1678916x28.outbound-mail.sendgrid.net [167.89.16.28]) by neon.ruby-lang.org (Postfix) with ESMTPS id 62C6F120A3F for ; Mon, 19 Aug 2019 10:44:25 +0900 (JST) Received: by filter0183p3mdw1.sendgrid.net with SMTP id filter0183p3mdw1-6823-5D59FEFA-2C 2019-08-19 01:44:26.860981635 +0000 UTC m=+107547.051192002 Received: from herokuapp.com (unknown [54.80.45.23]) by ismtpd0012p1iad2.sendgrid.net (SG) with ESMTP id Ja5ZReHnRjupUgyEoNqeOg for ; Mon, 19 Aug 2019 01:44:26.894 +0000 (UTC) Date: Mon, 19 Aug 2019 01:44:27 +0000 (UTC) From: not.waf@gmail.com Message-ID: References: Mime-Version: 1.0 X-Redmine-MailingListIntegration-Message-Ids: 69969 X-Redmine-Project: ruby-trunk X-Redmine-Issue-Id: 15215 X-Redmine-Issue-Author: aspettl X-Redmine-Sender: waf X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-SG-EID: =?us-ascii?Q?+=2FmkkFVHM7w41TjarBM0dHOdFC53BZl11=2FOLF4h8Y4qUcZUvgQXbM=2FDuyKJkoI?= =?us-ascii?Q?W1cYD9Fz3GzO3U8lsKVofajy19lg638DicYyuT0?= =?us-ascii?Q?kKmXrWewqFkKytE+o7Pb1gK9F6PIV96fL6diwS8?= =?us-ascii?Q?Ovdel5zqEqbbRNmObBp=2FTo0KQh4ov62UdHSrZqL?= =?us-ascii?Q?GxWOd6cf5oK9Fcl8uQ4Hbd4TG1nCc0VDwgw=3D=3D?= To: ruby-core@ruby-lang.org X-ML-Name: ruby-core X-Mail-Count: 94421 Subject: [ruby-core:94421] [Ruby master Feature#15215] HTTPS server name indication (SNI): explicit server_name in Net::HTTP X-BeenThere: ruby-core@ruby-lang.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Ruby developers List-Id: Ruby developers List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ruby-core-bounces@ruby-lang.org Sender: "ruby-core" Issue #15215 has been updated by waf (felix wong). aspettl (Aaron Spettl) wrote: > I still like to have this feature. Any opinion on this? Especially @naruse as a maintainer of lib/net/http(s).rb? > > Thanks! +1 as well ---------------------------------------- Feature #15215: HTTPS server name indication (SNI): explicit server_name in Net::HTTP https://bugs.ruby-lang.org/issues/15215#change-80842 * Author: aspettl (Aaron Spettl) * Status: Open * Priority: Normal * Assignee: * Target version: ---------------------------------------- **Current behavior and problem:** At the moment, the host name or IP address given in the URL is used to provide the server name for SNI in HTTPS connections. While this behavior is sufficient in most cases, establishing a connection to a fixed IP using a certain server name is not possible. **Proposed solution:** Decouple the server name used for SNI from the address used for connecting. Add a new ssl_server_name attribute in Net::HTTP that defaults to the address (so the default behavior stays exactly the same). **Notes** * There are scenarios where a client would like to select a specific host when e.g. DNS round robin is configured. Examples: fallback strategies, monitoring of individual hosts. * This has nothing to do with the HTTP "Host" header, which one needs to set additionally. For my "proposed solution", a patch is attached (or see https://github.com/ruby/ruby/pull/1977). Please let me know about any ideas for improvement or other approaches, thanks! ---Files-------------------------------- ssl_server_name.patch (2.17 KB) -- https://bugs.ruby-lang.org/