File tree 11 files changed +26
-11
lines changed
app/controllers/vulneruby_engine
11 files changed +26
-11
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ def run
15
15
@result = {
16
16
digest : Vulneruby ::Trigger ::CryptoBadMac . run_digest_md5 ,
17
17
random : Vulneruby ::Trigger ::CryptoWeakRandomness . run_rand ,
18
- cipher : Vulneruby ::Trigger ::CryptoBadCipher . run_bad_cipher
18
+ # Bad Ciphers are deprecated in OpenSSL 3.X
19
+ # cipher: Vulneruby::Trigger::CryptoBadCipher.run_bad_cipher
19
20
}
20
21
21
22
render ( 'layouts/vulneruby_engine/insecure_algorithm/run' )
Original file line number Diff line number Diff line change @@ -3,6 +3,12 @@ ARG RUBY_VER=3.0
3
3
FROM ghcr.io/contrast-security-oss/vulneruby_engine/base:${RUBY_VER}
4
4
5
5
ENV CI_TEST=true
6
+
7
+ # If ruby is 3.0 then use ffi 1.15.5:
8
+ RUN if [ "$RUBY_VER" = "3.0" ]; \
9
+ then echo "RUBY_VER is 3.0" && export CONTRAST__PIPELINE__RUN=true; \
10
+ fi
11
+
6
12
COPY agent/* agent/
7
13
RUN rm contrast_security.yaml || true
8
14
COPY contrast_security.yaml contrast_security.yaml
Original file line number Diff line number Diff line change @@ -31,6 +31,14 @@ RUN gem install bundler
31
31
ENV PUMA=true
32
32
ENV THIN=true
33
33
34
+ # If ruby is 3.0 then use ffi 1.15.5:
35
+ RUN if [ "$RUBY_VER" = "3.0" ]; \
36
+ then echo "RUBY_VER is 3.0" && export CONTRAST__PIPELINE__RUN=true \
37
+ && bundle config build.ffi -- --disable-system-libffi \
38
+ && gem install ffi -v 1.15.5 -- -- disable-system-libffi; \
39
+ fi
40
+
41
+
34
42
RUN bundle config set with 'puma' 'thin'
35
43
RUN bundle config force_ruby_platform true \
36
44
&& bundle config build.nokogiri --use-system-libraries
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV PASSENGER_MAX=true
9
9
RUN bundle config set with 'passenger_max'
10
10
11
- RUN bundle update
11
+ RUN bundle install
12
12
13
13
# Copy configuration files to root directory:
14
14
RUN cp /app/contrast_security.yaml /app/spec/dummy/contrast_security.yaml
@@ -22,4 +22,4 @@ RUN bundle exec rake db:version
22
22
23
23
# Name and run the application
24
24
RUN ./docker/app_name_generator.sh Passenger_max >> /tmp/app_name.txt
25
- CMD redis-server & cat /tmp/app_name.txt && CONTRAST__APPLICATION__NAME=$(cat /tmp/app_name.txt) PASSENGER_START_TIMEOUT=300 bundle exec rails s -p $PORT
25
+ CMD redis-server & cat /tmp/app_name.txt && CONTRAST__APPLICATION__NAME=$(cat /tmp/app_name.txt) PASSENGER_START_TIMEOUT=300 bundle exec rails s -p $PORT
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV PASSENGER_MIN=true
9
9
RUN bundle config set with 'passenger_min'
10
10
11
- RUN bundle update
11
+ RUN bundle install
12
12
13
13
# Copy configuration files to root directory:
14
14
RUN cp /app/contrast_security.yaml /app/spec/dummy/contrast_security.yaml
@@ -22,4 +22,4 @@ RUN bundle exec rake db:version
22
22
23
23
# Name and run the application
24
24
RUN ./docker/app_name_generator.sh Passenger_min >> /tmp/app_name.txt
25
- CMD redis-server & cat /tmp/app_name.txt && CONTRAST__APPLICATION__NAME=$(cat /tmp/app_name.txt) PASSENGER_START_TIMEOUT=300 bundle exec rails s -p $PORT
25
+ CMD redis-server & cat /tmp/app_name.txt && CONTRAST__APPLICATION__NAME=$(cat /tmp/app_name.txt) PASSENGER_START_TIMEOUT=300 bundle exec rails s -p $PORT
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ ENV WEB_CONCURRENCY=1
11
11
ENV PUMA_MAX=true
12
12
RUN bundle config set with 'puma_max'
13
13
14
- RUN bundle update
14
+ RUN bundle install
15
15
16
16
# So we may use whatever command we want to trigger rake, to be sure
17
17
# that the agent is not braking the rake task
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ ENV WEB_CONCURRENCY=1
11
11
ENV PUMA_MIN=true
12
12
RUN bundle config set with 'puma_min'
13
13
14
- RUN bundle update
14
+ RUN bundle install
15
15
16
16
# So we may use whatever command we want to trigger rake, to be sure
17
17
# that the agent is not braking the rake task
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV THIN_MAX=true
9
9
RUN bundle config set with 'thin_max'
10
10
11
- RUN bundle update
11
+ RUN bundle install
12
12
13
13
# So we may use whatever command we want to trigger rake, to be sure
14
14
# that the agent is not braking the rake task
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV THIN_MIN=true
9
9
RUN bundle config set with 'thin_min'
10
10
11
- RUN bundle update
11
+ RUN bundle install
12
12
13
13
# So we may use whatever command we want to trigger rake, to be sure
14
14
# that the agent is not braking the rake task
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV UNICORN_MAX=true
9
9
RUN bundle config set with 'unicorn_max'
10
10
11
- RUN AGENT_PATH=`gem which contrast-agent` bundle update && bundle install
11
+ RUN AGENT_PATH=`gem which contrast-agent` bundle install
12
12
13
13
# So we may use whatever command we want to trigger rake, to be sure
14
14
# that the agent is not braking the rake task
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ ENV PORT=$PORT_ARG
8
8
ENV UNICORN_MIN=true
9
9
RUN bundle config set with 'unicorn_min'
10
10
11
- RUN AGENT_PATH=`gem which contrast-agent` bundle update && bundle install
11
+ RUN AGENT_PATH=`gem which contrast-agent` bundle install
12
12
13
13
# So we may use whatever command we want to trigger rake, to be sure
14
14
# that the agent is not braking the rake task
You can’t perform that action at this time.
0 commit comments