cirro-ruby-client 2.8.0 → 2.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.circleci/config.yml +0 -58
- data/Gemfile.lock +1 -1
- data/lib/cirro_io/client/version.rb +1 -1
- data/lib/cirro_io_v2/errors/client_error.rb +4 -5
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 101d2c8b46c83770524743e918ed784ae30273023a716269ac40d11a215e5880
|
|
4
|
+
data.tar.gz: fa4a057b29d61eaefbfe922591e1b76cf0d742dd608f2a9fc4728b56c113d455
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2ce706e8e7a4ca9a7c51bdb4c1443994bdc17bacc405754367ba6067169eda1343be9f1d0bd7ab7927fac87c93884717a03fd0d6ed6ef292a0810c4417235159
|
|
7
|
+
data.tar.gz: 6aef7329ef7d9c0be72cb6cc04d8950f0855c8afa0af4ea82e198b24acfda6a4ef362480b8c8024559f5fb02f03024e7f2d636b6bb9af6ca190a29393d915148
|
data/.circleci/config.yml
CHANGED
|
@@ -63,60 +63,6 @@ jobs:
|
|
|
63
63
|
gem push cirro-ruby-client-$version.gem
|
|
64
64
|
shred -u ~/.gem/credentials # completely remove the file making it hard for even very expensive hardware to recover the data
|
|
65
65
|
|
|
66
|
-
defectdojo:
|
|
67
|
-
executor: cci-base
|
|
68
|
-
environment:
|
|
69
|
-
DEFECTDOJO_URL: defectdojo.testcloud.io
|
|
70
|
-
DEFECTDOJO_PRODUCT: Cirro Ruby Client
|
|
71
|
-
DEFECTDOJO_ENG_NAME: CircleCI Scan
|
|
72
|
-
circleci_ip_ranges: true # opts the job into the IP ranges feature
|
|
73
|
-
steps:
|
|
74
|
-
- checkout
|
|
75
|
-
- run:
|
|
76
|
-
name: Install Trivy and Gitleaks
|
|
77
|
-
command: |
|
|
78
|
-
curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sudo sh -s -- -b /usr/local/bin
|
|
79
|
-
curl -sfL https://github.com/zricethezav/gitleaks/releases/download/v8.18.2/gitleaks_8.18.2_linux_x64.tar.gz -o gitleaks.tar.gz && \
|
|
80
|
-
tar -xf gitleaks.tar.gz
|
|
81
|
-
- run:
|
|
82
|
-
name: Scans
|
|
83
|
-
command: |
|
|
84
|
-
trivy fs --exit-code 0 --no-progress --format json --output filesystem-scan.json .
|
|
85
|
-
./gitleaks detect --no-git --exit-code 0 --report-format json --report-path gitleaks.json
|
|
86
|
-
- run:
|
|
87
|
-
name: Send data to DefectDojo
|
|
88
|
-
command: |
|
|
89
|
-
# The DEFECTDOJO_TOKEN env var is set in CCI to not have to be authenticated
|
|
90
|
-
# to GCP only for this purpose, so please change it there if it gets rotated
|
|
91
|
-
|
|
92
|
-
# Send Trivy filesystem scan
|
|
93
|
-
curl --fail --request POST https://$DEFECTDOJO_URL/api/v2/reimport-scan/ \
|
|
94
|
-
--header "Authorization: Token $DEFECTDOJO_TOKEN" \
|
|
95
|
-
--form "active=true" \
|
|
96
|
-
--form "auto_create_context=true" \
|
|
97
|
-
--form "branch_tag=${CIRCLE_BRANCH}" \
|
|
98
|
-
--form "commit_hash=${CIRCLE_SHA1}" \
|
|
99
|
-
--form "close_old_findings=true" \
|
|
100
|
-
--form "scan_type=Trivy Scan" \
|
|
101
|
-
--form "test_title=Trivy application scan" \
|
|
102
|
-
--form "engagement_name=${DEFECTDOJO_ENG_NAME}" \
|
|
103
|
-
--form "product_name=${DEFECTDOJO_PRODUCT}" \
|
|
104
|
-
--form "file=@filesystem-scan.json"
|
|
105
|
-
|
|
106
|
-
# Send Gitleaks scan
|
|
107
|
-
curl --fail --request POST https://$DEFECTDOJO_URL/api/v2/reimport-scan/ \
|
|
108
|
-
--header "Authorization: Token $DEFECTDOJO_TOKEN" \
|
|
109
|
-
--form "active=true" \
|
|
110
|
-
--form "auto_create_context=true" \
|
|
111
|
-
--form "branch_tag=${CIRCLE_BRANCH}" \
|
|
112
|
-
--form "commit_hash=${CIRCLE_SHA1}" \
|
|
113
|
-
--form "close_old_findings=true" \
|
|
114
|
-
--form "scan_type=Gitleaks Scan" \
|
|
115
|
-
--form "test_title=Gitleaks Scan" \
|
|
116
|
-
--form "engagement_name=${DEFECTDOJO_ENG_NAME}" \
|
|
117
|
-
--form "product_name=${DEFECTDOJO_PRODUCT}" \
|
|
118
|
-
--form "file=@gitleaks.json"
|
|
119
|
-
|
|
120
66
|
workflows:
|
|
121
67
|
deploy_the_gem:
|
|
122
68
|
jobs:
|
|
@@ -127,7 +73,3 @@ workflows:
|
|
|
127
73
|
filters:
|
|
128
74
|
branches:
|
|
129
75
|
only: master
|
|
130
|
-
- defectdojo:
|
|
131
|
-
filters:
|
|
132
|
-
branches:
|
|
133
|
-
only: master
|
data/Gemfile.lock
CHANGED
|
@@ -17,12 +17,11 @@ module CirroIOV2
|
|
|
17
17
|
end
|
|
18
18
|
|
|
19
19
|
def message
|
|
20
|
-
|
|
21
|
-
faraday_error.response.then do |response|
|
|
22
|
-
return response.inspect if ENV.fetch('DEBUG_CIRRO_RUBY_CLIENT', false)
|
|
20
|
+
return faraday_error.response.inspect if ENV['DEBUG_CIRRO_RUBY_CLIENT']
|
|
23
21
|
|
|
24
|
-
|
|
25
|
-
|
|
22
|
+
body = faraday_error.response&.dig(:body)
|
|
23
|
+
result = body.presence || faraday_error.try(:message)
|
|
24
|
+
result.is_a?(String) ? result : result.to_json
|
|
26
25
|
end
|
|
27
26
|
end
|
|
28
27
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: cirro-ruby-client
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.8.
|
|
4
|
+
version: 2.8.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Cirro Dev Team
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2026-04-10 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|