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

Side by Side Diff: third_party/WebKit/Source/platform/exported/WebCryptoKeyAlgorithm.cpp

Issue 2701993002: DO NOT COMMIT: Results of running new (proposed) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createRsaHashed( 90 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createRsaHashed(
91 WebCryptoAlgorithmId id, 91 WebCryptoAlgorithmId id,
92 unsigned modulusLengthBits, 92 unsigned modulusLengthBits,
93 const unsigned char* publicExponent, 93 const unsigned char* publicExponent,
94 unsigned publicExponentSize, 94 unsigned publicExponentSize,
95 WebCryptoAlgorithmId hash) { 95 WebCryptoAlgorithmId hash) {
96 // FIXME: Verify that id is an RSA algorithm which expects a hash 96 // FIXME: Verify that id is an RSA algorithm which expects a hash
97 if (!WebCryptoAlgorithm::isHash(hash)) 97 if (!WebCryptoAlgorithm::isHash(hash))
98 return WebCryptoKeyAlgorithm(); 98 return WebCryptoKeyAlgorithm();
99 return WebCryptoKeyAlgorithm( 99 return WebCryptoKeyAlgorithm(
100 id, WTF::wrapUnique(new WebCryptoRsaHashedKeyAlgorithmParams( 100 id,
101 modulusLengthBits, publicExponent, publicExponentSize, 101 WTF::wrapUnique(new WebCryptoRsaHashedKeyAlgorithmParams(
102 createHash(hash)))); 102 modulusLengthBits, publicExponent, publicExponentSize,
103 createHash(hash))));
103 } 104 }
104 105
105 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createEc( 106 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createEc(
106 WebCryptoAlgorithmId id, 107 WebCryptoAlgorithmId id,
107 WebCryptoNamedCurve namedCurve) { 108 WebCryptoNamedCurve namedCurve) {
108 return WebCryptoKeyAlgorithm( 109 return WebCryptoKeyAlgorithm(
109 id, WTF::makeUnique<WebCryptoEcKeyAlgorithmParams>(namedCurve)); 110 id, WTF::makeUnique<WebCryptoEcKeyAlgorithmParams>(namedCurve));
110 } 111 }
111 112
112 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createWithoutParams( 113 WebCryptoKeyAlgorithm WebCryptoKeyAlgorithm::createWithoutParams(
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 175
175 void WebCryptoKeyAlgorithm::assign(const WebCryptoKeyAlgorithm& other) { 176 void WebCryptoKeyAlgorithm::assign(const WebCryptoKeyAlgorithm& other) {
176 m_private = other.m_private; 177 m_private = other.m_private;
177 } 178 }
178 179
179 void WebCryptoKeyAlgorithm::reset() { 180 void WebCryptoKeyAlgorithm::reset() {
180 m_private.reset(); 181 m_private.reset();
181 } 182 }
182 183
183 } // namespace blink 184 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/audio/StereoPanner.cpp ('k') | third_party/WebKit/Source/platform/fonts/Font.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698