OSDN Git Service

FIX:NP_SecurityEnforcerの正規表現パターンの修正
authorshizuki <shizuki@kinezumi.net>
Tue, 29 May 2012 07:03:12 +0000 (16:03 +0900)
committershizuki <shizuki@kinezumi.net>
Tue, 29 May 2012 07:03:12 +0000 (16:03 +0900)
「\」と「#」が正しくエスケープされていなかったので修正

nucleus/plugins/NP_SecurityEnforcer.php

index 61dd62a..bf1a027 100644 (file)
@@ -277,6 +277,7 @@ class NP_SecurityEnforcer extends NucleusPlugin
        {
                $minlength = intval($minlength);
                $complexity = intval($complexity);
+               $message = '';
                
                if ( $minlength < 6 )
                {
@@ -295,7 +296,7 @@ class NP_SecurityEnforcer extends NucleusPlugin
                $ucchars        = '[A-Z]';
                $lcchars        = '[a-z]';
                $numchars       = '[0-9]';
-               $ochars         = '[-~!@#\$%^&*()_+=,.<>?:;|]';
+               $ochars         = '[\#-~!@\\$%^&*()_+=,.<>?:;|]';
                $chartypes      = array($ucchars, $lcchars, $numchars, $ochars);
                $tot            = array(0,0,0,0);
                $i                      = 0;