Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2012 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_SSL_SSL_SEVERITY_DATE_INVALID_H_ | |
| 6 #define CHROME_BROWSER_SSL_SSL_SEVERITY_DATE_INVALID_H_ | |
| 7 #endif | |
| 8 | |
| 9 #include "base/time/time.h" | |
| 10 #include "net/cert/x509_certificate.h" | |
| 11 | |
| 12 // This class describes the functions which will be usefule in calcualting the | |
| 13 // severity score when the SSL Error is Date Invalid. | |
|
felt
2014/07/07 22:01:34
^ make sure to read your comments, there are two b
radhikabhar
2014/07/09 17:17:12
Done.
| |
| 14 class SSLSeverityDateInvalid { | |
|
felt
2014/07/07 22:01:34
I don't think you need to make a new class for eac
radhikabhar
2014/07/09 17:17:12
Done.
| |
| 15 public : | |
| 16 // A function which calcualtes the weight of the client characteristics in | |
| 17 // contributing towards the SSL error. | |
| 18 float ClientCharacteristics(); | |
| 19 | |
| 20 // A function which calculates the weight of the server characteristics in | |
| 21 // contributing towards the SSL error. | |
| 22 float ServerCharacteristics(); | |
| 23 | |
| 24 SSLSeverityDateInvalid(base::Time current_time, | |
| 25 net::X509Certificate* cert); | |
| 26 ~SSLSeverityDateInvalid(); | |
| 27 | |
| 28 private: | |
| 29 | |
| 30 float IsUserClockWrong(); | |
| 31 float TimePassedSinceExpiry(); | |
| 32 | |
| 33 // This stores the current time. | |
| 34 base::Time current_time_; | |
| 35 | |
| 36 // This stores the certificate. | |
| 37 net::X509Certificate* cert_ ; | |
| 38 FRIEND_TEST_ALL_PREFIXES(SSLSeverityDateInvalidTest, IsUserClockWrongTest); | |
| 39 }; | |
| OLD | NEW |