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

Unified Diff: net/dns/dns_util.h

Issue 2921553002: Track how often we successfully resolve non-'compliant' domain names. (Closed)
Patch Set: |valid_name| is now a pointer! Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/dns/dns_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/dns/dns_util.h
diff --git a/net/dns/dns_util.h b/net/dns/dns_util.h
index 81eb1a28ba11dd57a0af00b91c9f69274babe707..4867c80f41d9d3f71c3750e34792562c75728478 100644
--- a/net/dns/dns_util.h
+++ b/net/dns/dns_util.h
@@ -24,6 +24,14 @@ class AddressList;
NET_EXPORT_PRIVATE bool DNSDomainFromDot(const base::StringPiece& dotted,
std::string* out);
+// dotted: a string in dotted form: "www.google.com"
+// out: a result in DNS form: "\x03www\x06google\x03com\x00"
+// valid_name: whether or not |IsValidHostLabelCharacter| returned true for
+// all characters in all labels in the name.
+bool DNSDomainFromDotWithValidityCheck(const base::StringPiece& dotted,
+ std::string* out,
+ bool* valid_name);
+
// Checks that a hostname is valid. Simple wrapper around DNSDomainFromDot.
NET_EXPORT_PRIVATE bool IsValidDNSDomain(const base::StringPiece& dotted);
« no previous file with comments | « no previous file | net/dns/dns_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698