| 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 #ifndef CONTENT_CHILD_WEBCRYPTO_STATUS_H_ | 5 #ifndef CONTENT_CHILD_WEBCRYPTO_STATUS_H_ |
| 6 #define CONTENT_CHILD_WEBCRYPTO_STATUS_H_ | 6 #define CONTENT_CHILD_WEBCRYPTO_STATUS_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include "content/common/content_export.h" | 9 #include "content/common/content_export.h" |
| 10 #include "third_party/WebKit/public/platform/WebCrypto.h" | 10 #include "third_party/WebKit/public/platform/WebCrypto.h" |
| (...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 // multiple of 8 bytes, as required by RFC 3394. | 169 // multiple of 8 bytes, as required by RFC 3394. |
| 170 static Status ErrorInvalidAesKwDataLength(); | 170 static Status ErrorInvalidAesKwDataLength(); |
| 171 | 171 |
| 172 // The "publicExponent" used to generate a key was invalid or unsupported. | 172 // The "publicExponent" used to generate a key was invalid or unsupported. |
| 173 // Only values of 3 and 65537 are allowed. | 173 // Only values of 3 and 65537 are allowed. |
| 174 static Status ErrorGenerateKeyPublicExponent(); | 174 static Status ErrorGenerateKeyPublicExponent(); |
| 175 | 175 |
| 176 // The modulus bytes were empty when importing an RSA public key. | 176 // The modulus bytes were empty when importing an RSA public key. |
| 177 static Status ErrorImportRsaEmptyModulus(); | 177 static Status ErrorImportRsaEmptyModulus(); |
| 178 | 178 |
| 179 // The the modulus length was zero bits when generating an RSA public key. | 179 // The modulus length was zero bits when generating an RSA key pair. |
| 180 static Status ErrorGenerateRsaZeroModulus(); | 180 static Status ErrorGenerateRsaZeroModulus(); |
| 181 | 181 |
| 182 // The modulus length was unsupported when generating an RSA key pair. |
| 183 static Status ErrorGenerateRsaUnsupportedModulus(); |
| 184 |
| 182 // The exponent bytes were empty when importing an RSA public key. | 185 // The exponent bytes were empty when importing an RSA public key. |
| 183 static Status ErrorImportRsaEmptyExponent(); | 186 static Status ErrorImportRsaEmptyExponent(); |
| 184 | 187 |
| 185 // An unextractable key was used by an operation which exports the key data. | 188 // An unextractable key was used by an operation which exports the key data. |
| 186 static Status ErrorKeyNotExtractable(); | 189 static Status ErrorKeyNotExtractable(); |
| 187 | 190 |
| 188 // The key length specified when generating a key was invalid. Either it was | 191 // The key length specified when generating a key was invalid. Either it was |
| 189 // zero, or it was not a multiple of 8 bits. | 192 // zero, or it was not a multiple of 8 bits. |
| 190 static Status ErrorGenerateKeyLength(); | 193 static Status ErrorGenerateKeyLength(); |
| 191 | 194 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 207 Type type_; | 210 Type type_; |
| 208 blink::WebCryptoErrorType error_type_; | 211 blink::WebCryptoErrorType error_type_; |
| 209 std::string error_details_; | 212 std::string error_details_; |
| 210 }; | 213 }; |
| 211 | 214 |
| 212 } // namespace webcrypto | 215 } // namespace webcrypto |
| 213 | 216 |
| 214 } // namespace content | 217 } // namespace content |
| 215 | 218 |
| 216 #endif // CONTENT_CHILD_WEBCRYPTO_STATUS_H_ | 219 #endif // CONTENT_CHILD_WEBCRYPTO_STATUS_H_ |
| OLD | NEW |