{"id":17132215,"url":"https://github.com/bitsofinfo/fluentd-modsecurity","last_synced_at":"2025-10-13T19:37:42.505Z","repository":{"id":146759046,"uuid":"14306192","full_name":"bitsofinfo/fluentd-modsecurity","owner":"bitsofinfo","description":"Fluentd output (filter) plugin for parsing events from ModSecurity audit logs","archived":false,"fork":false,"pushed_at":"2018-01-26T20:28:10.000Z","size":15,"stargazers_count":14,"open_issues_count":0,"forks_count":14,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-13T07:55:57.482Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://bitsofinfo.wordpress.com/2013/11/11/modsecurity-audit-logs-fluentd/","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bitsofinfo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2013-11-11T16:24:09.000Z","updated_at":"2024-06-20T11:56:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"780d0738-0924-48e6-9a5e-da3c335215a1","html_url":"https://github.com/bitsofinfo/fluentd-modsecurity","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/bitsofinfo/fluentd-modsecurity","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitsofinfo%2Ffluentd-modsecurity","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitsofinfo%2Ffluentd-modsecurity/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitsofinfo%2Ffluentd-modsecurity/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitsofinfo%2Ffluentd-modsecurity/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bitsofinfo","download_url":"https://codeload.github.com/bitsofinfo/fluentd-modsecurity/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bitsofinfo%2Ffluentd-modsecurity/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279016928,"owners_count":26085888,"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","status":"online","status_checked_at":"2025-10-13T02:00:06.723Z","response_time":61,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-10-14T19:26:23.842Z","updated_at":"2025-10-13T19:37:42.495Z","avatar_url":"https://github.com/bitsofinfo.png","language":"Ruby","readme":"# fluentd-modsecurity\n\n[Fluentd](http://fluentd.org/) output (filter) plugin for parsing a [ModSecurity](https://www.modsecurity.org/) audit log\n\nThis is intended to serve as an example starting point for how to ingest\nparse entries from a ModSecurity audit log file using fluentd into a more first-class\nstructured object that can then be forwarded on to another output.\n\n## Getting Started\n\nMore info and example output:\n* http://bitsofinfo.wordpress.com/2013/11/11/modsecurity-audit-logs-fluentd/\n\nModSecurity Audit Log format:\n* https://github.com/SpiderLabs/ModSecurity/wiki/ModSecurity-2-Data-Formats\n* https://www.nginx.com/blog/modsecurity-logging-and-debugging/\n\n### Prerequisites\n\nBuild the gem\n```\ngem build fluent-plugin-modsecurity.gemspec\n``` \n\nInstall the gem to fluentd\n```\nfluent-gem install ./fluent-plugin-modsecurity-0.2.gem\n``` \n\n## Deployment\n\nExample fluent.conf setup.\n\n```\n# (1) Consume the input\n\u003csource\u003e\n  @type tail\n  tag raw-modsec\n  path /path/to/modsec_audit.log\n  \u003cparse\u003e\n    @type multiline\n    format_firstline /^-{2,3}][a-zA-Z0-9]{8}-{2,3}A--$/\n    format1 /(?\u003cmessage\u003e.*)/\n  \u003c/parse\u003e\n\u003c/source\u003e\n\n# (2) Massage it via this plugin to a more structured object\n\u003cmatch raw-modsec\u003e\n  @type modsecurity-audit-format\n  tag modsec-formatted\n\u003c/match\u003e\n\n# (3) Output to stdout\n\u003cmatch modsec-formatted\u003e\n  @type stdout\n\u003c/match\u003e\n```\n\n## License\n\nThis project is licensed under the Apache 2.0 License - see the [LICENSE](LICENSE) file for details","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitsofinfo%2Ffluentd-modsecurity","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbitsofinfo%2Ffluentd-modsecurity","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbitsofinfo%2Ffluentd-modsecurity/lists"}