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

Side by Side Diff: content/child/webcrypto/status.cc

Issue 334983006: [webcrypto] Disable RSA key import for NSS versions less than 3.16.2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 return Status(blink::WebCryptoErrorTypeData, 144 return Status(blink::WebCryptoErrorTypeData,
145 "The provided data is too large"); 145 "The provided data is too large");
146 } 146 }
147 147
148 Status Status::ErrorDataTooSmall() { 148 Status Status::ErrorDataTooSmall() {
149 return Status(blink::WebCryptoErrorTypeData, 149 return Status(blink::WebCryptoErrorTypeData,
150 "The provided data is too small"); 150 "The provided data is too small");
151 } 151 }
152 152
153 Status Status::ErrorUnsupported() { 153 Status Status::ErrorUnsupported() {
154 return Status(blink::WebCryptoErrorTypeNotSupported, 154 return ErrorUnsupported("The requested operation is unsupported");
155 "The requested operation is unsupported"); 155 }
156
157 Status Status::ErrorUnsupported(const std::string message) {
158 return Status(blink::WebCryptoErrorTypeNotSupported, message);
156 } 159 }
157 160
158 Status Status::ErrorUnexpected() { 161 Status Status::ErrorUnexpected() {
159 return Status(blink::WebCryptoErrorTypeUnknown, 162 return Status(blink::WebCryptoErrorTypeUnknown,
160 "Something unexpected happened..."); 163 "Something unexpected happened...");
161 } 164 }
162 165
163 Status Status::ErrorInvalidAesGcmTagLength() { 166 Status Status::ErrorInvalidAesGcmTagLength() {
164 return Status( 167 return Status(
165 blink::WebCryptoErrorTypeData, 168 blink::WebCryptoErrorTypeData,
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 error_type_(error_type), 217 error_type_(error_type),
215 error_details_(error_details_utf8) { 218 error_details_(error_details_utf8) {
216 } 219 }
217 220
218 Status::Status(Type type) : type_(type) { 221 Status::Status(Type type) : type_(type) {
219 } 222 }
220 223
221 } // namespace webcrypto 224 } // namespace webcrypto
222 225
223 } // namespace content 226 } // namespace content
OLDNEW
« content/child/webcrypto/platform_crypto_nss.cc ('K') | « content/child/webcrypto/status.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698