Bearer/bearer

Bearer silently fails when it can't download any rules

Closed this issue · 0 comments

Description & Reproduction

If you try to run bearer in an airgapped environment it will silently fail to download the rules.

Expected Behavior

I expect that in this case an error message is shown so the user can check his connection or provide his own rules.

Actual Behavior

Bearer does not log an error message. Instead it continues and generates an empty report with 0 findings.
The exit code is 0 in this case.
This could lead to the assumption that the own software does not have any bugs that bearer can detect and that it is "safe"

Possible Fix

Fail with an error message if bearer was not able to load any rules (neither local nor the default ones).

Your Environment

  • Operating System and version: Linux - Docker Image in Gitlab Runner
  • Output of 'bearer version':
bearer version: 1.38.0