diff options
Diffstat (limited to 'types/ssl/https.d.tl')
-rw-r--r-- | types/ssl/https.d.tl | 50 |
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 @@ | |||
1 | local ssl = require("ssl") | ||
2 | local SSLCertificate = ssl.SSLCertificate | ||
3 | local SSLConnection = ssl.SSLConnection | ||
4 | |||
5 | local ltn12 = require("ltn12") | ||
6 | local Pump = ltn12.Pump | ||
7 | local Sink = ltn12.Sink | ||
8 | local Source = ltn12.Source | ||
9 | |||
10 | local 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 | ||
48 | end | ||
49 | |||
50 | return https \ No newline at end of file | ||