-
Notifications
You must be signed in to change notification settings - Fork 2k
Expand file tree
/
Copy pathtst.js
More file actions
81 lines (69 loc) · 1.61 KB
/
tst.js
File metadata and controls
81 lines (69 loc) · 1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
let https = require("https"),
tls = require("tls");
new https.Agent();
new https.Agent({
rejectUnauthorized: true
});
unknownCall({
rejectUnauthorized: false // OK - but probably unsafe after all
});
new https.Agent({
rejectUnauthorized: false // $ Alert
});
process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0"; // $ Alert
https.get({
rejectUnauthorized: false // $ Alert
});
new tls.TLSSocket(socket, {
rejectUnauthorized: false // $ Alert
});
tls.connect({
rejectUnauthorized: false // $ Alert
});
let socket = new tls.TLSSocket();
socket.renegotiate({
rejectUnauthorized: false // $ Alert
});
let indirect = false;
new https.Agent({
rejectUnauthorized: indirect // $ Alert
});
new https.Agent({
rejectUnauthorized: !false
});
new https.Agent({
rejectUnauthorized: !!false // $ Alert
});
new https.Agent({
rejectUnauthorized: !true // $ Alert
});
new https.Agent({
rejectUnauthorized: !!true
});
new https.Agent({
rejectUnauthorized: unknown()
});
new https.Agent({
rejectUnauthorized: !getOptions().selfSignedSSL
});
new https.Agent({
rejectUnauthorized: getOptions().rejectUnauthorized
});
new https.Agent({
rejectUnauthorized: !!getOptions().rejectUnauthorized
});
new https.Agent({
rejectUnauthorized: getOptions() == null ? true : getOptions().verifySsl
});
new https.Agent({
rejectUnauthorized: typeof getOptions().rejectUnauthorized === 'boolean' ? getOptions().rejectUnauthorized : undefined
});
function getSomeunsafeOptions() {
return {
rejectUnauthorized: false // $ Alert
}
}
new https.Agent(getSomeunsafeOptions());
https.createServer({
rejectUnauthorized: false // $ Alert
});