From: Thomas Hochstein Date: Sat, 15 Feb 2014 16:30:08 +0000 (+0100) Subject: Merge branch 'thh-strictbdsg' into next X-Git-Url: https://code.th-h.de/?p=usenet%2Fusevote.git;a=commitdiff_plain;h=6422cdc89300a908d613765a85d075d9d5bb68be;hp=d0fda3342cddc288c5a252df971d19f876b0106b Merge branch 'thh-strictbdsg' into next * thh-strictbdsg: Enforce strict response for data protection clause. --- diff --git a/usevote.cfg b/usevote.cfg index d6a6b33..aee1fc1 100644 --- a/usevote.cfg +++ b/usevote.cfg @@ -271,6 +271,10 @@ enth_stimme = (E|E\s*N\s*T\s*H\s*A\s*L\s*T\s*U\s*N\s*G) # Achtung, sollte auch in den Templates im Bestaetigungstext angepasst werden ann_stimme = A\s*N\s*N\s*U\s*L\s*L\s*I\s*E\s*R\s*U\s*N\s*G +# RegExp fuer Bestaetigung der Datenschutzklause (case-insensitive) +# Standardmaessig wird nur JA erkannt +bdsg_confirm = JA + # Template files (these files are in the template directory defined above) tpl_mailheader = "mailheader" # generally used mail header tpl_bouncelist = "bouncelist" # used by uvbounce.pl diff --git a/usevote.global.cfg b/usevote.global.cfg index 2ba69b4..94e83cc 100644 --- a/usevote.global.cfg +++ b/usevote.global.cfg @@ -143,6 +143,10 @@ enth_stimme = (E|E\s*N\s*T\s*H\s*A\s*L\s*T\s*U\s*N\s*G) # Achtung, sollte auch in den Templates im Bestaetigungstext angepasst werden ann_stimme = A\s*N\s*N\s*U\s*L\s*L\s*I\s*E\s*R\s*U\s*N\s*G +# RegExp fuer Bestaetigung der Datenschutzklause (case-insensitive) +# Standardmaessig wird nur JA erkannt +bdsg_confirm = JA + # Template files (these files are in the template directory defined above) tpl_mailheader = "mailheader" # generally used mail header tpl_bouncelist = "bouncelist" # used by uvbounce.pl diff --git a/uvvote.pl b/uvvote.pl index 9505edc..2af270e 100755 --- a/uvvote.pl +++ b/uvvote.pl @@ -329,7 +329,7 @@ sub process_vote { # Should read like this: #a [ STIMME ] Text # (Text is configurable in usevote.cfg) unless ($$body =~ /$bdsg_regexp/s && - $$body =~ /#a\W*?\[\W*?$config{ja_stimme}\W*?\]\W*?$bdsg2_regexp/is) { + $$body =~ /#a\W*?\[\W*?$config{bdsg_confirm}\W*?\]\W*?$bdsg2_regexp/is) { push (@errors, 'InvalidBDSG'); }