Home | History | Annotate | Download | only in download
      1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_EXTENSIONS_H_
      6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_EXTENSIONS_H_
      7 
      8 #include <string>
      9 
     10 #include "base/files/file_path.h"
     11 
     12 namespace download_util {
     13 
     14 enum DownloadDangerLevel {
     15   NOT_DANGEROUS,
     16   ALLOW_ON_USER_GESTURE,
     17   DANGEROUS
     18 };
     19 
     20 // Determine the download danger level of a file.
     21 DownloadDangerLevel GetFileDangerLevel(const base::FilePath& path);
     22 
     23 // Tests if we think the server means for this mime_type to be executable.
     24 bool IsExecutableMimeType(const std::string& mime_type);
     25 
     26 }  // namespace download_util
     27 
     28 #endif  // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_EXTENSIONS_H_
     29