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
|
# File 'lib/checks/cloudflare.rb', line 6
def generate_checks(url)
[
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:version => nil,
:match_type => :content_cookies,
:match_content => /__cfduid/i,
:match_details =>"Cloudflare Accelerated Page",
:paths => ["#{url}"]
},
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:version => nil,
:match_type => :content_headers,
:match_content => /cfray:/i,
:match_details =>"header",
:paths => ["#{url}"]
},
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:version => nil,
:match_type => :content_headers,
:match_content => /cloudflare-nginx/i,
:match_details =>"cloudflare nginx header",
:paths => ["#{url}"]
},
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:tags => ["error_page"],
:version => nil,
:match_type => :content_body,
:match_content => /<title>Direct IP access not allowed \| Cloudflare/,
:match_details =>"Cloudflare - Direct IP Access",
:hide => true,
:paths => ["#{url}"]
},
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:match_details =>"Cloudflare Error",
:tags => ["error_page"],
:version => "",
:match_type => :content_body,
:match_content => /cferror_details/,
:hide => true,
:paths => ["#{url}"]
},
{
:type => "service",
:vendor => "Cloudflare",
:product => "CDN",
:match_details =>"Cloudfront Error - Direct IP Access",
:version => nil,
:match_type => :content_body,
:match_content => /403\ Forbidden<\/h1><\/center>\n<hr><center>cloudflare<\/center>/im,
:hide => true,
:paths => ["#{url}"]
}
]
end
|