Skip to content

Commit

Permalink
chore: prepare for release (#5)
Browse files Browse the repository at this point in the history
  • Loading branch information
EsadCetiner committed Mar 5, 2024
1 parent 324c5e5 commit 05b2924
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 22 deletions.
40 changes: 20 additions & 20 deletions plugins/sogo-rule-exclusions-before.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# Plugin name: sogo-rule-exclusions-plugin
# Plugin description: OWASP CRS 3rd party plugin for SOGo Groupware
# Rule ID block base: 9,520,000 - 9,520,999
# Plugin version: 1.0.0
# Plugin version: 1.0.1

# See readme.md for documentation

Expand All @@ -29,7 +29,7 @@ SecRule &TX:allowed_methods "@eq 0" \
phase:1,\
pass,\
nolog,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_methods=GET HEAD POST OPTIONS'"

# Copy of CRS rule 901162.
Expand All @@ -38,7 +38,7 @@ SecRule &TX:allowed_request_content_type "@eq 0" \
phase:1,\
pass,\
nolog,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_request_content_type=|application/x-www-form-urlencoded| |multipart/form-data| |multipart/related| |text/xml| |application/xml| |application/soap+xml| |application/json| |application/cloudevents+json| |application/cloudevents-batch+json|'"

# Fix SOGo cookie false positive
Expand All @@ -54,7 +54,7 @@ SecRule REQUEST_FILENAME "@beginsWith /SOGo/" \
ctl:ruleRemoveTargetById=942450;REQUEST_COOKIES:XSRF-TOKEN,\
ctl:ruleRemoveTargetById=932236;REQUEST_COOKIES:0xHIGHFLYxSOGo,\
ctl:ruleRemoveTargetById=942450;REQUEST_COOKIES:0xHIGHFLYxSOGo,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When logging into SOGo webmail
SecRule REQUEST_FILENAME "@streq /SOGo/connect" \
Expand All @@ -65,7 +65,7 @@ SecRule REQUEST_FILENAME "@streq /SOGo/connect" \
nolog,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:password,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:json.password,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# SOGo displays domain names inside the request uri, domains most commonly end in .com which triggers 920440.
SecRule REQUEST_FILENAME "@rx ^/SOGo/(?:dav/|so/)?[^/]+\.(?:com|inc)$" \
Expand All @@ -75,7 +75,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/(?:dav/|so/)?[^/]+\.(?:com|inc)$" \
t:none,\
nolog,\
ctl:ruleRemoveById=920440,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# SOGo sometimes sets funny referrers
SecRule REQUEST_FILENAME "@beginsWith /SOGo" \
Expand All @@ -85,7 +85,7 @@ SecRule REQUEST_FILENAME "@beginsWith /SOGo" \
t:none,\
nolog,\
ctl:ruleRemoveTargetById=932237;REQUEST_HEADERS:referer,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# Writing or saving an email
# Email content can be anything
Expand All @@ -103,7 +103,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Mail/[0-9]/folderDrafts/newDraft[0
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:json.text,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:subject,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:text,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

#
# [ SOGo Settings ]
Expand All @@ -120,7 +120,7 @@ SecRule REQUEST_FILENAME "@streq /SOGo/so/changePassword" \
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:json.newPassword,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:oldPassword,\
ctl:ruleRemoveTargetByTag=OWASP_CRS;ARGS:newPassword,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When changing settings in SOGo
SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Preferences/save$" \
Expand All @@ -146,7 +146,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Preferences/save$" \
ctl:ruleRemoveTargetById=931130;ARGS,\
ctl:ruleRemoveTargetById=932236;ARGS,\
ctl:ruleRemoveTargetById=942131;ARGS,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

#
# [ SOGo Contacts ]
Expand All @@ -169,7 +169,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Contacts/[^/]+/[^/]+\.vcf/saveAsCo
ctl:ruleRemoveTargetById=931130;ARGS:json.urls.array_6.value,\
ctl:ruleRemoveTargetById=931130;ARGS:json.urls.array_7.value,\
ctl:ruleRemoveTargetById=931130;ARGS:urls.urls.value,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When modifying properties for Addressbook
# Enabling/disabling Microsoft ActiveSync
Expand All @@ -181,7 +181,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Contacts/[^/]+/save$" \
nolog,\
ctl:ruleRemoveTargetById=931130;ARGS:cardDavURL,\
ctl:ruleRemoveTargetById=931130;ARGS:json.cardDavURL,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

#
# [ SOGo Calendar ]
Expand All @@ -204,7 +204,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Calendar/[^/]+/[^/]+\.ics/(?:saveA
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_5.value,\
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_6.value,\
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_7.value,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When creating/modifying a calendar event
# Attaching external URLs to a calendar event
Expand All @@ -224,7 +224,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Calendar/[^/]+/[^/]+\.ics/(?:saveA
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_5.value,\
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_6.value,\
ctl:ruleRemoveTargetById=931130;ARGS:json.attachUrls.array_7.value,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When modifying properties for Calendars
# Adding a remote webcal
Expand All @@ -244,7 +244,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Calendar/[^/]+/save$" \
ctl:ruleRemoveTargetById=931130;ARGS:urls.webDavURL,\
ctl:ruleRemoveTargetById=931130;ARGS:urls.calDavURL,\
ctl:ruleRemoveTargetById=931130;ARGS:urls.webCalendarURL,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

# When adding a remote web calendar
SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Calendar/addWebCalendar$" \
Expand All @@ -255,7 +255,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/so/[^/]+/Calendar/addWebCalendar$" \
nolog,\
ctl:ruleRemoveTargetById=931130;ARGS:json.url,\
ctl:ruleRemoveTargetById=931130;ARGS:url,\
ver:'sogo-rule-exclusions-plugin/1.0.0'"
ver:'sogo-rule-exclusions-plugin/1.0.1'"

#
# [ SOGo mobile DAV clients ]
Expand All @@ -276,7 +276,7 @@ SecRule REQUEST_FILENAME "@beginsWith /SOGo/dav" \
ctl:ruleRemoveTargetById=942421;XML:/*,\
ctl:ruleRemoveTargetById=942432;XML:/*,\
ctl:ruleRemoveTargetById=942440;XML:/*,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_methods=%{tx.allowed_methods} PUT DELETE PROPFIND REPORT MKCOL'"

# When modifying/creating contacts via mobile dav client
Expand All @@ -286,7 +286,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/dav/[^/]+/Contacts/[^/]+/[^/]+\.vcf$" \
pass,\
t:none,\
nolog,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_request_content_type=%{tx.allowed_request_content_type} |text/vcard|'"

# When modifying/creating calendar via mobile dav client
Expand All @@ -296,7 +296,7 @@ SecRule REQUEST_FILENAME "@rx ^/SOGo/dav/[^/]+/Calendar/[^/]+/[^/]+\.ics$" \
pass,\
t:none,\
nolog,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_request_content_type=%{tx.allowed_request_content_type} |text/calendar|'"

# Allow dav clients to scan for caldav/cardav path
Expand All @@ -306,5 +306,5 @@ SecRule REQUEST_FILENAME "@streq /" \
pass,\
t:none,\
nolog,\
ver:'sogo-rule-exclusions-plugin/1.0.0',\
ver:'sogo-rule-exclusions-plugin/1.0.1',\
setvar:'tx.allowed_methods=%{tx.allowed_methods} PROPFIND'"
4 changes: 2 additions & 2 deletions plugins/sogo-rule-exclusions-config.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
# Plugin name: sogo-rule-exclusions-plugin
# Plugin description: OWASP CRS 3rd party plugin for SOGo Groupware
# Rule ID block base: 9,520,000 - 9,520,999
# Plugin version: 1.0.0
# Plugin version: 1.0.1

# See readme.md for documentation

Expand Down Expand Up @@ -39,5 +39,5 @@
# phase:1,\
# pass,\
# nolog,\
# ver:'sogo-rule-exclusions-plugin/1.0.0',\
# ver:'sogo-rule-exclusions-plugin/1.0.1',\
# setvar:'tx.sogo-rule-exclusions-plugin=0'"

0 comments on commit 05b2924

Please sign in to comment.