aboutsummaryrefslogtreecommitdiff
path: root/types/ssl/https.d.tl
diff options
context:
space:
mode:
Diffstat (limited to 'types/ssl/https.d.tl')
-rw-r--r--types/ssl/https.d.tl50
1 files changed, 50 insertions, 0 deletions
diff --git a/types/ssl/https.d.tl b/types/ssl/https.d.tl
new file mode 100644
index 00000000..94c38df6
--- /dev/null
+++ b/types/ssl/https.d.tl
@@ -0,0 +1,50 @@
1local ssl = require("ssl")
2local SSLCertificate = ssl.SSLCertificate
3local SSLConnection = ssl.SSLConnection
4
5local ltn12 = require("ltn12")
6local Pump = ltn12.Pump
7local Sink = ltn12.Sink
8local Source = ltn12.Source
9
10local record https
11 record HTTPSRequest
12 -- HTTP options
13 url: string|{string}
14 sink: Sink<string>
15 method: string
16 headers: {string:string}
17 source: Source<string>
18 step: Pump<string>
19 -- proxy: string -- not supported
20 -- redirect: boolean -- not supported
21 -- create: function -- https implements its own
22
23 -- SSL options
24 mode: string
25 protocol: string
26 key: string
27 password: string|function
28 certificate: string
29 certificates: {SSLCertificate}
30 cafile: string
31 capath: string
32 verify: string|{string}
33 options: string|{string}
34 ciphers: string
35 ciphersuites: string
36 depth: number
37 dhparam: function
38 curve: string
39 curves_list: string
40 verifyext: string|{string}
41 alpn: string|function|{string}
42 dane: boolean
43 end
44 request: function(string): string, number, {string:string}, string
45 request: function(string, string): string, number, {string:string}, string
46 request: function(HTTPSRequest): string, number, {string:string}, string
47 tcp: function(): function(): SSLConnection
48end
49
50return https \ No newline at end of file