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

Unified Diff: runtime/bin/secure_socket_patch.dart

Issue 1699163002: More SecurityContext calls accept a password. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Fix typo Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/bin/secure_socket.cc ('k') | sdk/lib/io/security_context.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/secure_socket_patch.dart
diff --git a/runtime/bin/secure_socket_patch.dart b/runtime/bin/secure_socket_patch.dart
index b15d61a84532551e6bd2abff895d749cf975c6a6..ccfc1c1e78d8c5368e9cee9eb4b549773fae8650 100644
--- a/runtime/bin/secure_socket_patch.dart
+++ b/runtime/bin/secure_socket_patch.dart
@@ -147,38 +147,38 @@ class _SecurityContext
void usePrivateKeyBytes(List<int> keyBytes, {String password})
native "SecurityContext_UsePrivateKeyBytes";
- void setTrustedCertificates(String file) {
- setTrustedCertificatesSync(file);
+ void setTrustedCertificates(String file, {String password}) {
+ setTrustedCertificatesSync(file, password: password);
}
- void setTrustedCertificatesSync(String file) {
+ void setTrustedCertificatesSync(String file, {String password}) {
List<int> bytes = (new File(file)).readAsBytesSync();
- setTrustedCertificatesBytes(bytes);
+ setTrustedCertificatesBytes(bytes, password: password);
}
- void setTrustedCertificatesBytes(List<int> certBytes)
+ void setTrustedCertificatesBytes(List<int> certBytes, {String password})
native "SecurityContext_SetTrustedCertificatesBytes";
- void useCertificateChain({String file, String directory}) {
+ void useCertificateChain({String file, String directory, String password}) {
if (directory != null) {
throw new UnsupportedError(
"The directory argument to useCertificateChain is not supported.");
}
- useCertificateChainSync(file);
+ useCertificateChainSync(file, password: password);
}
- void useCertificateChainSync(String chainFile) {
+ void useCertificateChainSync(String chainFile, {String password}) {
List<int> bytes = (new File(chainFile)).readAsBytesSync();
- useCertificateChainBytes(bytes);
+ useCertificateChainBytes(bytes, password: password);
}
- void useCertificateChainBytes(List<int> chainBytes)
+ void useCertificateChainBytes(List<int> chainBytes, {String password})
native "SecurityContext_UseCertificateChainBytes";
- void setClientAuthorities(String file) {
- setClientAuthoritiesSync(file);
+ void setClientAuthorities(String file, {String password}) {
+ setClientAuthoritiesSync(file, password: password);
}
- void setClientAuthoritiesSync(String file) {
+ void setClientAuthoritiesSync(String file, {String password}) {
List<int> bytes = (new File(file)).readAsBytesSync();
- setClientAuthoritiesBytes(bytes);
+ setClientAuthoritiesBytes(bytes, password: password);
}
- void setClientAuthoritiesBytes(List<int> authCertBytes)
+ void setClientAuthoritiesBytes(List<int> authCertBytes, {String password})
native "SecurityContext_SetClientAuthoritiesBytes";
void setAlpnProtocols(List<String> protocols, bool isServer) {
Uint8List encodedProtocols =
« no previous file with comments | « runtime/bin/secure_socket.cc ('k') | sdk/lib/io/security_context.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698