Keyboard Shortcuts

File
u :up to issue
m :publish + mail comments
M :edit review message
j / k :jump to file after / before current file
J / K :jump to next file with a comment after / before current file
Side-by-side diff
i :toggle intra-line diffs
e :expand all comments
c :collapse all comments
s :toggle showing all comments
n / p :next / previous diff chunk or comment
N / P :next / previous comment
<Up> / <Down> :next / previous line
<Enter> :respond to / edit current comment
d :mark current comment as done
Issue
u :up to list of issues
m :publish + mail comments
j / k :jump to patch after / before current patch
o / <Enter> :open current patch in side-by-side view
i :open current patch in unified diff view
Issue List
j / k :jump to issue after / before current issue
o / <Enter> :open current issue
# : close issue
Comment/message editing
<Ctrl> + s or <Ctrl> + Enter :save comment
<Esc> :cancel edit
Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(256)
Issues Repositories Search
Open Issues | Closed Issues | All Issues | Sign in with your Google Account to create issues and add comments

Issue 2420041: code review 2420041: SRV support and RFC compliance

Can't Edit
Can't Publish+Mail
Start Review
Created:
15 years, 3 months ago by cjyar
Modified:
10 years, 4 months ago
Reviewers:
rsc1
CC:
rsc, chris_cjones.org, golang-dev
Visibility:
Public.
SRV support and RFC compliance LookupSRV() always fails because isDomainName() returns false for any valid SRV query. Specifically, it rejects the leading _ character on the first two domain name parts. This patch changes the behavior of isDomainName() to be in keeping with RFC 2181, which allows SRV queries to work. However, that RFC appears to contradict the other cited RFCs. It's likely that a correct reading requires a delicate interpretation of "DNS record" vs. "DNS name" or something similar. This change also adds LookupSRVByNet(), which uses the three parameters listed in RFC 2782: service, proto, and name. This function could use a better name; I'm guessing we can't replace the old LookupSRV() with it, because it would be an incompatible API change.

Patch Set 1 #

Patch Set 2 : code review 2420041: SRV support and RFC compliance #

Patch Set 3 : code review 2420041: SRV support and RFC compliance #

Created: 15 years, 3 months ago
Download [raw] [tar.bz2]
Unified diffs Side-by-side diffs Delta from patch set Stats (+105 lines, -2 lines) Patch
M src/pkg/net/dnsclient.go View 1 2 3 chunks +18 lines, -2 lines 0 comments Download
A src/pkg/net/dnsname_test.go View 1 2 1 chunk +65 lines, -0 lines 0 comments Download
A src/pkg/net/srv_test.go View 1 2 1 chunk +22 lines, -0 lines 0 comments Download
Total messages: 10
|
cjyar
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com), I'd like you to review this change.
15 years, 3 months ago (2010年10月10日 06:41:10 UTC) #1
Hello golang-dev@googlegroups.com (cc: golang-dev@googlegroups.com),
I'd like you to review this change.
Sign in to reply to this message.
rsc
Please sync with the latest tip. I believe half of this CL is covered by ...
15 years, 3 months ago (2010年10月11日 15:31:38 UTC) #2
Please sync with the latest tip. I believe half of this CL is covered by
changeset: 6473:9b27e48edf12
user: Russ Cox <rsc@golang.org>
date: Thu Oct 07 06:45:50 2010 -0400
summary: net: allow _ in names
I'd be happy to replace LookupSRV instead of adding a new function.
Thanks.
Russ
Sign in to reply to this message.
cjyar
Hello golang-dev@googlegroups.com, rsc (cc: golang-dev@googlegroups.com), Please take another look.
15 years, 3 months ago (2010年10月15日 04:43:59 UTC) #3
Hello golang-dev@googlegroups.com, rsc (cc: golang-dev@googlegroups.com),
Please take another look.
Sign in to reply to this message.
cjyar
Hello golang-dev@googlegroups.com, rsc (cc: golang-dev@googlegroups.com), Please take another look.
15 years, 3 months ago (2010年10月15日 04:44:24 UTC) #4
Hello golang-dev@googlegroups.com, rsc (cc: golang-dev@googlegroups.com),
Please take another look.
Sign in to reply to this message.
cjyar
On 2010年10月15日 04:44:24, cjyar wrote: > Hello mailto:golang-dev@googlegroups.com, rsc (cc: mailto:golang-dev@googlegroups.com), > > Please take ...
15 years, 3 months ago (2010年10月15日 04:46:50 UTC) #5
On 2010年10月15日 04:44:24, cjyar wrote:
> Hello mailto:golang-dev@googlegroups.com, rsc (cc:
mailto:golang-dev@googlegroups.com),
> 
> Please take another look.
Replaced the old LookupSRV() with the new 3-argument syntax. I think this is
more in keeping with the relevant RFC.
I also changed dnsname_test.go a bit. There are some names that I really don't
know if we should accept or not, so I removed them as test cases. :)
I added a bit of logic to isDomainName() to check the overall length of the name
and the lengths of its parts.
Sign in to reply to this message.
chris_cjones.org
It's been a couple of weeks. Could somebody take a look at this? Chris On ...
15 years, 2 months ago (2010年10月30日 02:33:05 UTC) #6
It's been a couple of weeks. Could somebody take a look at this?
Chris
On 10/14/2010 10:46 PM, chris.jones.yar@gmail.com wrote:
> On 2010年10月15日 04:44:24, cjyar wrote:
>> Hello mailto:golang-dev@googlegroups.com, rsc (cc:
> mailto:golang-dev@googlegroups.com),
>
>> Please take another look.
>
> Replaced the old LookupSRV() with the new 3-argument syntax. I think
> this is more in keeping with the relevant RFC.
>
> I also changed dnsname_test.go a bit. There are some names that I really
> don't know if we should accept or not, so I removed them as test cases.
> :)
>
> I added a bit of logic to isDomainName() to check the overall length of
> the name and the lengths of its parts.
>
> http://codereview.appspot.com/2420041/
Sign in to reply to this message.
rsc1
LGTM
15 years, 2 months ago (2010年11月01日 18:54:05 UTC) #7
LGTM
Sign in to reply to this message.
rsc1
Could you please complete a CLA as described at http://golang.org/doc/contribute.html#copyright ? Thanks. Russ
15 years, 2 months ago (2010年11月01日 20:21:01 UTC) #8
Could you please complete a CLA as described at
http://golang.org/doc/contribute.html#copyright ?
Thanks.
Russ
Sign in to reply to this message.
chris_cjones.org
Done. On 11/1/2010 2:21 PM, rsc@google.com wrote: > Could you please complete a CLA as ...
15 years, 2 months ago (2010年11月01日 20:40:25 UTC) #9
Done.
On 11/1/2010 2:21 PM, rsc@google.com wrote:
> Could you please complete a CLA as described at
> http://golang.org/doc/contribute.html#copyright ?
>
> Thanks.
> Russ
>
>
> http://codereview.appspot.com/2420041/
Sign in to reply to this message.
rsc
*** Submitted as e4191df7dd41 *** net: fix LookupSRV R=rsc, chris CC=golang-dev http://codereview.appspot.com/2420041 Committer: Russ Cox ...
15 years, 2 months ago (2010年11月04日 14:30:42 UTC) #10
*** Submitted as e4191df7dd41 ***
net: fix LookupSRV
R=rsc, chris
CC=golang-dev
http://codereview.appspot.com/2420041
Committer: Russ Cox <rsc@golang.org>
Sign in to reply to this message.
|
This is Rietveld f62528b

AltStyle によって変換されたページ (->オリジナル) /