{"id":28366885,"url":"https://github.com/pixielabs/scan-suppressing-logger","last_synced_at":"2026-05-17T04:33:12.463Z","repository":{"id":40224930,"uuid":"192498765","full_name":"pixielabs/scan-suppressing-logger","owner":"pixielabs","description":"Suppress Rails logs and exceptions from automated scan requests.","archived":false,"fork":false,"pushed_at":"2024-06-25T16:20:29.000Z","size":59,"stargazers_count":2,"open_issues_count":22,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-12T16:04:46.702Z","etag":null,"topics":["exception-handling","logging","penetration-testing","rollbar","ruby","ruby-on-rails"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pixielabs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-06-18T08:30:14.000Z","updated_at":"2024-06-25T16:20:27.000Z","dependencies_parsed_at":"2023-02-11T01:20:23.708Z","dependency_job_id":null,"html_url":"https://github.com/pixielabs/scan-suppressing-logger","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/pixielabs/scan-suppressing-logger","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixielabs%2Fscan-suppressing-logger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixielabs%2Fscan-suppressing-logger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixielabs%2Fscan-suppressing-logger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixielabs%2Fscan-suppressing-logger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pixielabs","download_url":"https://codeload.github.com/pixielabs/scan-suppressing-logger/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pixielabs%2Fscan-suppressing-logger/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261694187,"owners_count":23195529,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["exception-handling","logging","penetration-testing","rollbar","ruby","ruby-on-rails"],"created_at":"2025-05-29T00:13:23.739Z","updated_at":"2026-05-17T04:33:07.425Z","avatar_url":"https://github.com/pixielabs.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ScanSuppressingLogger\n\n[![Gem Version](https://badge.fury.io/rb/scan-suppressing-logger.svg)](https://badge.fury.io/rb/scan-suppressing-logger)\n\nRails middleware to suppress logging and exception reporting for certain IP\naddresses or IP address ranges. Useful if your application is the target of\nautomated security scans (e.g. a scheduled penetration test) that fills your\nlogs with garbage errors and requests.\n\nSuppresses the standard Rails logging, and also suppresses exception reporting\nfor:\n\n - [Rollbar](https://rollbar.com)\n - _Sentry \u0026 more coming soon!_\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'scan-suppressing-logger'\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install scan-suppressing-logger\n\n## Usage\n\nAdd to your `config/environments/production.rb`:\n\n```ruby\n# config/environments/production.rb\nconfig.middleware.swap Rails::Rack::Logger, ScanSuppressingLogger::Middleware, {\n  networks: ['123.0.2.2/24', '86.54.222.1/16']\n}\n```\n\nPass an array of IP addresses or networks as strings to suppress logging for.\nThese should be parseable by\n[IPAddr](https://ruby-doc.org/stdlib-2.6.3/libdoc/ipaddr/rdoc/IPAddr.html).\n\n### Help! `No such middleware to insert before: Rails::Rack::Logger`\n\nIf you get this error it might be because something else is replacing the\nstandard logger, or expecting it to be there. For example, if you have\n`config.assets.quiet = true` in your configuration, Sprockets tries to\n`insert_before` the standard logging middleware in an initializer. You'll need\nto configure this gem in an initializer instead:\n\n```ruby\n# config/initializer/suppressing_logger.rb\nRails.application.config.middleware.swap Rails::Rack::Logger, ScanSuppressingLogger::Middleware, {\n  networks: ['123.0.2.2/24', '86.54.222.1/16']\n}\n```\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To\nrelease a new version, update the version number in `version.rb`, and then run\n`bundle exec rake release`, which will create a git tag for the version, push\ngit commits and tags, and push the `.gem` file to\n[rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at\nhttps://github.com/pixielabs/scan-suppressing-logger. This project is intended to\nbe a safe, welcoming space for collaboration, and contributors are expected to\nadhere to the [Contributor Covenant](http://contributor-covenant.org) code of\nconduct.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT\nLicense](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the ScanSuppressingLogger project’s codebases, issue\ntrackers, chat rooms and mailing lists is expected to follow the [code of\nconduct](https://github.com/jalada/scan-suppressing-logger/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixielabs%2Fscan-suppressing-logger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpixielabs%2Fscan-suppressing-logger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpixielabs%2Fscan-suppressing-logger/lists"}