summaryrefslogtreecommitdiffstats
path: root/chrome/browser/autocomplete/autocomplete.h
diff options
context:
space:
mode:
authordarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-10 06:36:34 +0000
committerdarin@chromium.org <darin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-10 06:36:34 +0000
commit83c7264800194b0d9ffdce49c57a3fdd5cf6a1a0 (patch)
tree11179533d5a0550b63b4a7a6ba9361f0dc9698da /chrome/browser/autocomplete/autocomplete.h
parentfcfaa4e7e70d366db6accae092855f59c44be4a9 (diff)
downloadchromium_src-83c7264800194b0d9ffdce49c57a3fdd5cf6a1a0.zip
chromium_src-83c7264800194b0d9ffdce49c57a3fdd5cf6a1a0.tar.gz
chromium_src-83c7264800194b0d9ffdce49c57a3fdd5cf6a1a0.tar.bz2
Don't send queries when URL is like:
- starts with http:// or https:// and includes username (e.g. http://me@test.com/) - starts with http:// or https:// and includes query (e.g. http://test.com/?q=x) - starts with https:// and includes path component (e.g. https://test.com/path) so as not to leak user data to the suggest server. Patch by takayoshi.kochi@gmail.com BUG=1647 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1978 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/autocomplete/autocomplete.h')
-rw-r--r--chrome/browser/autocomplete/autocomplete.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/chrome/browser/autocomplete/autocomplete.h b/chrome/browser/autocomplete/autocomplete.h
index 8102306..35fb790 100644
--- a/chrome/browser/autocomplete/autocomplete.h
+++ b/chrome/browser/autocomplete/autocomplete.h
@@ -193,9 +193,13 @@ class AutocompleteInput {
// Resets all internal variables to the null-constructed state.
void Clear();
+ // Returns parsed URL components.
+ const url_parse::Parsed& parts() const { return parts_; }
+
private:
std::wstring text_;
Type type_;
+ url_parse::Parsed parts_;
std::wstring scheme_;
std::wstring desired_tld_;
bool prevent_inline_autocomplete_;
@@ -777,4 +781,3 @@ struct AutocompleteLog {
};
#endif // CHROME_BROWSER_AUTOCOMPLETE_AUTOCOMPLETE_H_
-