| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/child/webcrypto/status.h" | 5 #include "content/child/webcrypto/status.h" |
| 6 | 6 |
| 7 namespace content { | 7 namespace content { |
| 8 | 8 |
| 9 namespace webcrypto { | 9 namespace webcrypto { |
| 10 | 10 |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 } | 163 } |
| 164 | 164 |
| 165 Status Status::ErrorInvalidAesKwDataLength() { | 165 Status Status::ErrorInvalidAesKwDataLength() { |
| 166 return Status(blink::WebCryptoErrorTypeData, | 166 return Status(blink::WebCryptoErrorTypeData, |
| 167 "The AES-KW input data length is invalid: not a multiple of 8 " | 167 "The AES-KW input data length is invalid: not a multiple of 8 " |
| 168 "bytes"); | 168 "bytes"); |
| 169 } | 169 } |
| 170 | 170 |
| 171 Status Status::ErrorGenerateKeyPublicExponent() { | 171 Status Status::ErrorGenerateKeyPublicExponent() { |
| 172 return Status(blink::WebCryptoErrorTypeData, | 172 return Status(blink::WebCryptoErrorTypeData, |
| 173 "The \"publicExponent\" is either empty, zero, or too large"); | 173 "The \"publicExponent\" must be either 3 or 65537"); |
| 174 } | 174 } |
| 175 | 175 |
| 176 Status Status::ErrorImportRsaEmptyModulus() { | 176 Status Status::ErrorImportRsaEmptyModulus() { |
| 177 return Status(blink::WebCryptoErrorTypeData, "The modulus is empty"); | 177 return Status(blink::WebCryptoErrorTypeData, "The modulus is empty"); |
| 178 } | 178 } |
| 179 | 179 |
| 180 Status Status::ErrorGenerateRsaZeroModulus() { | 180 Status Status::ErrorGenerateRsaZeroModulus() { |
| 181 return Status(blink::WebCryptoErrorTypeData, | 181 return Status(blink::WebCryptoErrorTypeData, |
| 182 "The modulus bit length cannot be zero"); | 182 "The modulus bit length cannot be zero"); |
| 183 } | 183 } |
| (...skipping 25 matching lines...) Expand all Loading... |
| 209 error_type_(error_type), | 209 error_type_(error_type), |
| 210 error_details_(error_details_utf8) { | 210 error_details_(error_details_utf8) { |
| 211 } | 211 } |
| 212 | 212 |
| 213 Status::Status(Type type) : type_(type) { | 213 Status::Status(Type type) : type_(type) { |
| 214 } | 214 } |
| 215 | 215 |
| 216 } // namespace webcrypto | 216 } // namespace webcrypto |
| 217 | 217 |
| 218 } // namespace content | 218 } // namespace content |
| OLD | NEW |