caido 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/lib/caido/helpers/export.rb +38 -0
- data/lib/caido/helpers/replay.rb +1 -1
- data/lib/caido/helpers/request.rb +34 -0
- data/lib/caido/helpers/response.rb +19 -0
- data/lib/caido/helpers/sitemap.rb +40 -0
- data/lib/caido/helpers/{project.rb → workspace.rb} +15 -0
- data/lib/caido/version.rb +1 -1
- metadata +7 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cda2477d6d465b1196201a4f35af51e6b8529f5257de078f103fa5e91b9f213c
|
4
|
+
data.tar.gz: 1defe074a9e68c5dd032044247283d8299fefb6858d49def449ae9c8038700d1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 91393a417bdf2970789a2bcc050dc5f58897bbcf6e87d410000e935415e4742f47e9c5972572b98db486fdd2bda18297691a3bb795c909c49053f39e0a298f0e
|
7
|
+
data.tar.gz: 04ead47dc67153ec370bd30ebb1a0ac151858bbc3c8a7655032e381fecfae92a7d0bb7941544ebbfdd24851486db46fcca451b7410e55611fb715784c4e655be
|
data/README.md
CHANGED
@@ -21,6 +21,8 @@ instance = Caido::Instance.new "http://localhost:8080", "AUTH_TOKEN"
|
|
21
21
|
# Use helper
|
22
22
|
instance.version # 0.38.0
|
23
23
|
instance.projects # [...]
|
24
|
+
instance.replay_sessions # [{"name"=>"1", "activeEntry"=> {"request"=> ... ]
|
25
|
+
instance.request(12) # {"id"=>"12", "host"=>"www.hahwul.com", "method"=>"GET", ... }
|
24
26
|
|
25
27
|
# Use GraphQL Query
|
26
28
|
instance.query('{runtime{platform}}')
|
@@ -0,0 +1,38 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Caido
|
4
|
+
# Instance class
|
5
|
+
class Instance
|
6
|
+
def exports
|
7
|
+
query('query{
|
8
|
+
dataExports{
|
9
|
+
id
|
10
|
+
format
|
11
|
+
name
|
12
|
+
status
|
13
|
+
error
|
14
|
+
createdAt
|
15
|
+
path
|
16
|
+
size
|
17
|
+
downloadUri
|
18
|
+
}
|
19
|
+
}')['dataExports']
|
20
|
+
end
|
21
|
+
|
22
|
+
def export(id)
|
23
|
+
query("query{
|
24
|
+
dataExport(id: \"#{id}\"){
|
25
|
+
id
|
26
|
+
format
|
27
|
+
name
|
28
|
+
status
|
29
|
+
error
|
30
|
+
createdAt
|
31
|
+
path
|
32
|
+
size
|
33
|
+
downloadUri
|
34
|
+
}
|
35
|
+
}")['dataExport']
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
data/lib/caido/helpers/replay.rb
CHANGED
@@ -0,0 +1,34 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Caido
|
4
|
+
# Instance class
|
5
|
+
class Instance
|
6
|
+
def request(id)
|
7
|
+
query("query{
|
8
|
+
request(id:\"#{id}\"){
|
9
|
+
id
|
10
|
+
host
|
11
|
+
method
|
12
|
+
query
|
13
|
+
length
|
14
|
+
port
|
15
|
+
isTls
|
16
|
+
fileExtension
|
17
|
+
source
|
18
|
+
alteration
|
19
|
+
edited
|
20
|
+
createdAt
|
21
|
+
raw
|
22
|
+
response{
|
23
|
+
id
|
24
|
+
statusCode
|
25
|
+
length
|
26
|
+
roundtripTime
|
27
|
+
edited
|
28
|
+
raw
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}")['request']
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Caido
|
4
|
+
# Instance class
|
5
|
+
class Instance
|
6
|
+
def response(id)
|
7
|
+
query("query{
|
8
|
+
response(id:\"#{id}\"){
|
9
|
+
id
|
10
|
+
statusCode
|
11
|
+
length
|
12
|
+
roundtripTime
|
13
|
+
edited
|
14
|
+
raw
|
15
|
+
}
|
16
|
+
}")['response']
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Caido
|
4
|
+
# Instance class
|
5
|
+
class Instance
|
6
|
+
def sitemap_entiry(id)
|
7
|
+
query("query{
|
8
|
+
sitemapEntry(id: \"#{id}\"){
|
9
|
+
id
|
10
|
+
label
|
11
|
+
kind
|
12
|
+
parentId
|
13
|
+
request{
|
14
|
+
id
|
15
|
+
host
|
16
|
+
method
|
17
|
+
query
|
18
|
+
length
|
19
|
+
port
|
20
|
+
isTls
|
21
|
+
fileExtension
|
22
|
+
source
|
23
|
+
alteration
|
24
|
+
edited
|
25
|
+
createdAt
|
26
|
+
raw
|
27
|
+
response{
|
28
|
+
id
|
29
|
+
statusCode
|
30
|
+
length
|
31
|
+
roundtripTime
|
32
|
+
edited
|
33
|
+
raw
|
34
|
+
}
|
35
|
+
}
|
36
|
+
}
|
37
|
+
}")['sitemapEntry']
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
data/lib/caido/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: caido
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- HAHWUL
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-06-
|
11
|
+
date: 2024-06-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: graphql
|
@@ -56,11 +56,15 @@ files:
|
|
56
56
|
- lib/caido.rb
|
57
57
|
- lib/caido/helpers/_example.rb
|
58
58
|
- lib/caido/helpers/automate.rb
|
59
|
+
- lib/caido/helpers/export.rb
|
59
60
|
- lib/caido/helpers/hosted_file.rb
|
60
|
-
- lib/caido/helpers/project.rb
|
61
61
|
- lib/caido/helpers/replay.rb
|
62
|
+
- lib/caido/helpers/request.rb
|
63
|
+
- lib/caido/helpers/response.rb
|
62
64
|
- lib/caido/helpers/runtime.rb
|
65
|
+
- lib/caido/helpers/sitemap.rb
|
63
66
|
- lib/caido/helpers/workflow.rb
|
67
|
+
- lib/caido/helpers/workspace.rb
|
64
68
|
- lib/caido/instance.rb
|
65
69
|
- lib/caido/version.rb
|
66
70
|
- sig/caido.rbs
|