Re: [apps-discuss] Fwd: I-D Action: draft-yevstifeyev-ftp-uri-scheme-04.txt

Mykyta Yevstifeyev <evnikita2@gmail.com> Thu, 14 July 2011 03:29 UTC

Return-Path: <evnikita2@gmail.com>
X-Original-To: apps-discuss@ietfa.amsl.com
Delivered-To: apps-discuss@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 0EE0711E80D5 for <apps-discuss@ietfa.amsl.com>; Wed, 13 Jul 2011 20:29:10 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.925
X-Spam-Level:
X-Spam-Status: No, score=-2.925 tagged_above=-999 required=5 tests=[AWL=-0.527, BAYES_00=-2.599, HTML_MESSAGE=0.001, J_CHICKENPOX_34=0.6, J_CHICKENPOX_44=0.6, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 1bk-vC0HdNkp for <apps-discuss@ietfa.amsl.com>; Wed, 13 Jul 2011 20:29:06 -0700 (PDT)
Received: from mail-fx0-f54.google.com (mail-fx0-f54.google.com [209.85.161.54]) by ietfa.amsl.com (Postfix) with ESMTP id F06D311E80C5 for <apps-discuss@ietf.org>; Wed, 13 Jul 2011 20:29:04 -0700 (PDT)
Received: by fxe4 with SMTP id 4so358011fxe.27 for <apps-discuss@ietf.org>; Wed, 13 Jul 2011 20:29:04 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type; bh=xfTQ7KlngpZInDqGAsd6d5vwA4unYPrn9aiOOBjrOCA=; b=Xun9VSuPN2BnSySe2ifRaVmNv3veQwCuKejnUVgL9Go7285AnKQog2o4Y/WyT2DJKy yAShexyMABms1Wp7jV59WiGx1V77gW9wshUwF44P1lF/Xpl9ZEXapI4st4+sbtgOos8a 8XYk/qOHg14u/L+1R6OCkxeaWFL5Nv5RF2vIQ=
Received: by 10.223.158.72 with SMTP id e8mr2473195fax.39.1310614144127; Wed, 13 Jul 2011 20:29:04 -0700 (PDT)
Received: from [127.0.0.1] ([195.191.104.224]) by mx.google.com with ESMTPS id y21sm4207189fad.15.2011.07.13.20.29.02 (version=SSLv3 cipher=OTHER); Wed, 13 Jul 2011 20:29:03 -0700 (PDT)
Message-ID: <4E1E62AB.2070608@gmail.com>
Date: Thu, 14 Jul 2011 06:29:47 +0300
From: Mykyta Yevstifeyev <evnikita2@gmail.com>
User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:5.0) Gecko/20110624 Thunderbird/5.0
MIME-Version: 1.0
To: Frank Ellermann <hmdmhdfmhdjmzdtjmzdtzktdkztdjz@gmail.com>
References: <4E15C895.6020701@gmail.com> <4E1B3270.40601@gmail.com> <CAHhFybpG-eoLb0uQ-JR9k7r1-NUohihXWS+w4Vsznpx=zYbGYA@mail.gmail.com>
In-Reply-To: <CAHhFybpG-eoLb0uQ-JR9k7r1-NUohihXWS+w4Vsznpx=zYbGYA@mail.gmail.com>
Content-Type: multipart/alternative; boundary="------------060502080607080701050404"
Cc: Apps-discuss list <apps-discuss@ietf.org>
Subject: Re: [apps-discuss] Fwd: I-D Action: draft-yevstifeyev-ftp-uri-scheme-04.txt
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 14 Jul 2011 03:29:10 -0000

Frank,

I think I'll move the discussion here.  The following is your posting to 
register@uri.arpa:

> 2011/7/10 Mykyta Yevstifeyev:
>
>>> That can be simplified to:
>>>    !^ftp://([^@]*@)?([^:/?#]*).*$!\\2!i
>> I agree with you here.  Yet, actually this may be simplified
>> far to
>>>    !^ftp://(.*@)?([^:/?#]*).*$!\\2!i

I don't agree with such expression.  See justification below.

> Is "anything ending with '@'" (in your version) the same as
> "any non-'@' ending with the first '@'" (in JimC's version)?
> For clarity I'd prefer the first version, but maybe we are
> not yet ready:
>
>> "@" chars are not generally allowed in in<userinfo>  without
>> percent encoding, as well as in other parts of the URI.
> As soon as you are behind the<userinfo>  in an<authority>
> it is not more necessary to percent-encode '@'.  I'm too lazy
> to check it, but I guess that '@' is an ordinary<pchar>, and
> also allowed in query parts and fragments.

"@" is in <gen-delims>, so we can safely assume that it won't apper 
anywhere else except the authority non-percent-encoded.  As "@"s aren't 
allowed in <userinfo> as by RFC 3986 and my document, it is also assumed 
that there will be no "@" chars before the "@" delimiting userinfo from 
host (if, we can they assume that the second "@" is a part of <host>, 
which isn't allowed as well).  So, "@" will normally occur only 1 time, 
and won't occur in the <userinfo> itself, query or fragment identifier.

>
> After all mailto: and news: URLs use '@' for their purposes
> outside of<userinfo>.
>
> Therefore we might need something in the direction of...
> !^ftp://([^@/?#]*@)?([^:/?#]*).*$!\\2!i
> ...matching '@' only before any path or query or fragment.
> [^@/?#]* should match the colon in a user:pass<userinfo>.

This would make sense if "@" was in <sub-delims>.  See above.

So as a summary: The expression

> !^ftp://([^@]*@)?([^:/?#]*).*$!\\2!i

is sufficient enough to match RFC 3986 and this particular URI scheme.

Mykyta

>
> -Frank
>

14.07.2011 4:48, Frank Ellermann wrote:
> On 11 July 2011 19:27, Mykyta Yevstifeyev wrote:
>
>>> !^ftp://(.*@)?([^:/?#]*).*$!\\2!i
> Sorry, I sent my comment to the uri.arpa list before I saw your
> summary here.  Here's my proposal based on the discussion there:
>
>     !^ftp://([^@/?#]*@)?([^:/?#]*).*$!\\2!i
>
> -Frank
>