1// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2// for details. All rights reserved. Use of this source code is governed by a
3// BSD-style license that can be found in the LICENSE file.
4
5#if defined(DART_IO_SECURE_SOCKET_DISABLED)
6
7#include "bin/builtin.h"
8#include "bin/dartutils.h"
9#include "include/dart_api.h"
10
11namespace dart {
12namespace bin {
13
14void FUNCTION_NAME(SecureSocket_Init)(Dart_NativeArguments args) {
15 Dart_ThrowException(DartUtils::NewDartArgumentError(
16 "Secure Sockets unsupported on this platform"));
17}
18
19void FUNCTION_NAME(SecureSocket_Connect)(Dart_NativeArguments args) {
20 Dart_ThrowException(DartUtils::NewDartArgumentError(
21 "Secure Sockets unsupported on this platform"));
22}
23
24void FUNCTION_NAME(SecureSocket_AddCertificate)(Dart_NativeArguments args) {
25 Dart_ThrowException(DartUtils::NewDartArgumentError(
26 "Secure Sockets unsupported on this platform"));
27}
28
29void FUNCTION_NAME(SecureSocket_Destroy)(Dart_NativeArguments args) {
30 Dart_ThrowException(DartUtils::NewDartArgumentError(
31 "Secure Sockets unsupported on this platform"));
32}
33
34void FUNCTION_NAME(SecureSocket_Handshake)(Dart_NativeArguments args) {
35 Dart_ThrowException(DartUtils::NewDartArgumentError(
36 "Secure Sockets unsupported on this platform"));
37}
38
39void FUNCTION_NAME(SecureSocket_MarkAsTrusted)(Dart_NativeArguments args) {
40 Dart_ThrowException(DartUtils::NewDartArgumentError(
41 "Secure Sockets unsupported on this platform"));
42}
43
44void FUNCTION_NAME(SecureSocket_NewX509CertificateWrapper)(
45 Dart_NativeArguments args) {
46 Dart_ThrowException(DartUtils::NewDartArgumentError(
47 "Secure Sockets unsupported on this platform"));
48}
49
50void FUNCTION_NAME(SecureSocket_GetSelectedProtocol)(
51 Dart_NativeArguments args) {
52 Dart_ThrowException(DartUtils::NewDartArgumentError(
53 "Secure Sockets unsupported on this platform"));
54}
55
56void FUNCTION_NAME(SecureSocket_RegisterHandshakeCompleteCallback)(
57 Dart_NativeArguments args) {
58 Dart_ThrowException(DartUtils::NewDartArgumentError(
59 "Secure Sockets unsupported on this platform"));
60}
61
62void FUNCTION_NAME(SecureSocket_RegisterBadCertificateCallback)(
63 Dart_NativeArguments args) {
64 Dart_ThrowException(DartUtils::NewDartArgumentError(
65 "Secure Sockets unsupported on this platform"));
66}
67
68void FUNCTION_NAME(SecureSocket_RegisterKeyLogPort)(Dart_NativeArguments args) {
69 Dart_ThrowException(DartUtils::NewDartArgumentError(
70 "Secure Sockets unsupported on this platform"));
71}
72
73void FUNCTION_NAME(SecureSocket_ProcessBuffer)(Dart_NativeArguments args) {
74 Dart_ThrowException(DartUtils::NewDartArgumentError(
75 "Secure Sockets unsupported on this platform"));
76}
77
78void FUNCTION_NAME(SecureSocket_InitializeLibrary)(Dart_NativeArguments args) {
79 Dart_ThrowException(DartUtils::NewDartArgumentError(
80 "Secure Sockets unsupported on this platform"));
81}
82
83void FUNCTION_NAME(SecureSocket_PeerCertificate)(Dart_NativeArguments args) {
84 Dart_ThrowException(DartUtils::NewDartArgumentError(
85 "Secure Sockets unsupported on this platform"));
86}
87
88void FUNCTION_NAME(SecureSocket_FilterPointer)(Dart_NativeArguments args) {
89 Dart_ThrowException(DartUtils::NewDartArgumentError(
90 "Secure Sockets unsupported on this platform"));
91}
92
93void FUNCTION_NAME(SecureSocket_NewServicePort)(Dart_NativeArguments args) {
94 Dart_ThrowException(DartUtils::NewDartArgumentError(
95 "Secure Sockets unsupported on this platform"));
96}
97
98void FUNCTION_NAME(SecurityContext_Allocate)(Dart_NativeArguments args) {
99 Dart_ThrowException(DartUtils::NewDartArgumentError(
100 "Secure Sockets unsupported on this platform"));
101}
102
103void FUNCTION_NAME(SecurityContext_UsePrivateKeyBytes)(
104 Dart_NativeArguments args) {
105 Dart_ThrowException(DartUtils::NewDartArgumentError(
106 "Secure Sockets unsupported on this platform"));
107}
108
109void FUNCTION_NAME(SecurityContext_SetAlpnProtocols)(
110 Dart_NativeArguments args) {
111 Dart_ThrowException(DartUtils::NewDartArgumentError(
112 "Secure Sockets unsupported on this platform"));
113}
114
115void FUNCTION_NAME(SecurityContext_SetClientAuthoritiesBytes)(
116 Dart_NativeArguments args) {
117 Dart_ThrowException(DartUtils::NewDartArgumentError(
118 "Secure Sockets unsupported on this platform"));
119}
120
121void FUNCTION_NAME(SecurityContext_SetTrustedCertificatesBytes)(
122 Dart_NativeArguments args) {
123 Dart_ThrowException(DartUtils::NewDartArgumentError(
124 "Secure Sockets unsupported on this platform"));
125}
126
127void FUNCTION_NAME(SecurityContext_TrustBuiltinRoots)(
128 Dart_NativeArguments args) {
129 Dart_ThrowException(DartUtils::NewDartArgumentError(
130 "Secure Sockets unsupported on this platform"));
131}
132
133void FUNCTION_NAME(SecurityContext_SetAllowTlsRenegotiation)(
134 Dart_NativeArguments args) {
135 Dart_ThrowException(DartUtils::NewDartArgumentError(
136 "Secure Sockets unsupported on this platform"));
137}
138
139void FUNCTION_NAME(SecurityContext_UseCertificateChainBytes)(
140 Dart_NativeArguments args) {
141 Dart_ThrowException(DartUtils::NewDartArgumentError(
142 "Secure Sockets unsupported on this platform"));
143}
144
145void FUNCTION_NAME(X509_Der)(Dart_NativeArguments args) {
146 Dart_ThrowException(DartUtils::NewDartArgumentError(
147 "Secure Sockets unsupported on this platform"));
148}
149
150void FUNCTION_NAME(X509_Sha1)(Dart_NativeArguments args) {
151 Dart_ThrowException(DartUtils::NewDartArgumentError(
152 "Secure Sockets unsupported on this platform"));
153}
154
155void FUNCTION_NAME(X509_Subject)(Dart_NativeArguments args) {
156 Dart_ThrowException(DartUtils::NewDartArgumentError(
157 "Secure Sockets unsupported on this platform"));
158}
159
160void FUNCTION_NAME(X509_Issuer)(Dart_NativeArguments args) {
161 Dart_ThrowException(DartUtils::NewDartArgumentError(
162 "Secure Sockets unsupported on this platform"));
163}
164
165void FUNCTION_NAME(X509_StartValidity)(Dart_NativeArguments args) {
166 Dart_ThrowException(DartUtils::NewDartArgumentError(
167 "Secure Sockets unsupported on this platform"));
168}
169
170void FUNCTION_NAME(X509_EndValidity)(Dart_NativeArguments args) {
171 Dart_ThrowException(DartUtils::NewDartArgumentError(
172 "Secure Sockets unsupported on this platform"));
173}
174
175void FUNCTION_NAME(X509_Pem)(Dart_NativeArguments args) {
176 Dart_ThrowException(DartUtils::NewDartArgumentError(
177 "Secure Sockets unsupported on this platform"));
178}
179
180class SSLFilter {
181 public:
182 static CObject* ProcessFilterRequest(const CObjectArray& request);
183};
184
185CObject* SSLFilter::ProcessFilterRequest(const CObjectArray& request) {
186 return CObject::IllegalArgumentError();
187}
188
189} // namespace bin
190} // namespace dart
191
192#endif // defined(DART_IO_SECURE_SOCKET_DISABLED)
193

source code of dart_sdk/runtime/bin/secure_socket_unsupported.cc