Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(255)

Issue 632843003: Add a function to escape a query part of url (Closed)

Created:
6 years, 2 months ago by Jaekyun Seok (inactive)
Modified:
6 years, 2 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Add a function to escape a query part of url GURL can contain unescaped characters in query parameters. So this function is needed to escape them in some cases. For example, a GURL should be escaped before it passes to Java layer because invalid url can't be parsed there. BUG=419257

Patch Set 1 #

Patch Set 2 : Rename the function to EscapeQueryParameters #

Total comments: 1

Patch Set 3 : Follow RFC 2396 to escape a query part of url #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+46 lines, -1 line) Patch
M net/base/escape.h View 1 2 1 chunk +5 lines, -0 lines 1 comment Download
M net/base/escape.cc View 1 2 4 chunks +23 lines, -1 line 0 comments Download
M net/base/escape_unittest.cc View 1 2 1 chunk +18 lines, -0 lines 0 comments Download

Messages

Total messages: 23 (3 generated)
Jaekyun Seok (inactive)
Please review this change. Actually the function added by this change is already being used ...
6 years, 2 months ago (2014-10-06 22:59:11 UTC) #2
Jaekyun Seok (inactive)
Asanka, please review this change.
6 years, 2 months ago (2014-10-06 23:03:22 UTC) #4
Jaekyun Seok (inactive)
Ryan, please review this change.
6 years, 2 months ago (2014-10-06 23:30:55 UTC) #6
asanka
I think this API is too big of a foot gun. Adding unescaped strings to ...
6 years, 2 months ago (2014-10-07 04:40:01 UTC) #7
Jaekyun Seok (inactive)
On 2014/10/07 04:40:01, asanka wrote: > I think this API is too big of a ...
6 years, 2 months ago (2014-10-07 05:04:02 UTC) #8
Jaekyun Seok (inactive)
FYI, my function doesn't escape whole query section after unifying pairs of unescaped key and ...
6 years, 2 months ago (2014-10-07 06:42:15 UTC) #9
Jaekyun Seok (inactive)
It seems that I named the function wrongly because it didn't escape query part, but ...
6 years, 2 months ago (2014-10-07 12:55:00 UTC) #10
Jaekyun Seok (inactive)
Ping?
6 years, 2 months ago (2014-10-07 22:26:33 UTC) #11
willchan no longer on Chromium
Everyone is at the networking summit, so expect delays. Sorry. On Tue, Oct 7, 2014 ...
6 years, 2 months ago (2014-10-07 22:28:38 UTC) #12
asanka
Sorry about the delay and also sorry about the not lgtm. As I mentioned, this ...
6 years, 2 months ago (2014-10-08 13:42:27 UTC) #13
Jaekyun Seok (inactive)
Please see my inline comments. On 2014/10/08 13:42:27, asanka wrote: > Sorry about the delay ...
6 years, 2 months ago (2014-10-08 22:28:42 UTC) #14
Jaekyun Seok (inactive)
On 2014/10/08 13:42:27, asanka wrote: > Sorry about the delay and also sorry about the ...
6 years, 2 months ago (2014-10-08 22:55:28 UTC) #15
Jaekyun Seok (inactive)
FYI, I confirmed that GURL escaped '|' in other places automatically. For example, GURL("https://www.google.co.kr/a|b/a").spec() ==> ...
6 years, 2 months ago (2014-10-09 11:31:08 UTC) #16
Jaekyun Seok (inactive)
Asanka, do you still have a concern that my function is not a valid general ...
6 years, 2 months ago (2014-10-09 20:59:22 UTC) #17
Ryan Sleevi
I'm going to echo Asanka's not LGTM. The reasons he's provided are solid. The syntax ...
6 years, 2 months ago (2014-10-09 21:11:05 UTC) #18
Jaekyun Seok (inactive)
I don't still understand why my function isn't valid even though other ones use the ...
6 years, 2 months ago (2014-10-09 21:28:19 UTC) #19
Jaekyun Seok (inactive)
PTAL. I've uploaded a totally new patch to escape unescaped characters in a query part ...
6 years, 2 months ago (2014-10-10 04:59:25 UTC) #20
asanka
On 2014/10/09 21:28:19, Jaekyun Seok wrote: > I don't still understand why my function isn't ...
6 years, 2 months ago (2014-10-10 20:58:26 UTC) #21
asanka
https://codereview.chromium.org/632843003/diff/80001/net/base/escape.h File net/base/escape.h (right): https://codereview.chromium.org/632843003/diff/80001/net/base/escape.h#newcode59 net/base/escape.h:59: // the mark characters(-_.!~*'()). You are once again going ...
6 years, 2 months ago (2014-10-10 20:59:16 UTC) #22
Jaekyun Seok (inactive)
6 years, 2 months ago (2014-10-13 00:11:45 UTC) #23
I see. I will add a sanitizer for query part in a proper location.

Powered by Google App Engine
This is Rietveld 408576698