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

Unified Diff: net/base/mime_util.cc

Issue 1423663012: Removing x-x509-user-cert mime handler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Using MimeType for handler. Created 5 years, 1 month 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
Index: net/base/mime_util.cc
diff --git a/net/base/mime_util.cc b/net/base/mime_util.cc
index 0d511201fd0cdfdda126ad480bc0157e5385e33f..1d433e9f03335813051871a640bf490d72bc5d8d 100644
--- a/net/base/mime_util.cc
+++ b/net/base/mime_util.cc
@@ -359,6 +359,12 @@ bool GetWellKnownMimeTypeFromExtension(const base::FilePath::StringType& ext,
bool GetPreferredExtensionForMimeType(const std::string& mime_type,
base::FilePath::StringType* extension) {
+ // Force .crt extension for client certificates.
Ryan Sleevi 2015/12/01 22:45:47 Shouldn't this only be for ChromeOS, and embedded
svaldez 2015/12/01 22:53:36 Not entirely sure whether we want to limit this to
Ryan Sleevi 2015/12/01 23:00:50 My (opinionated, potentially wrong) thinking is th
svaldez 2015/12/01 23:05:22 The problem in that case is that since we'll end u
+ if (mime_type == "application/x-x509-user-cert") {
+ *extension = FILE_PATH_LITERAL("crt");
+ return true;
+ }
+
return g_mime_util.Get().GetPreferredExtensionForMimeType(mime_type,
extension);
}
« content/browser/loader/mime_type_resource_handler.cc ('K') | « content/content_browser.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698