From b3dfad614ade26ba68c08bc52fb750dcd6875bac Mon Sep 17 00:00:00 2001 From: mark_story Date: Sun, 6 Jul 2014 09:42:20 -0400 Subject: [PATCH] Correct pattern matching. Instead of 10 digits, it should limit at 10 groups. Refs 1988e89e7382ba830c0172f399887595714c5b18 --- lib/Cake/Controller/Component/SecurityComponent.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Cake/Controller/Component/SecurityComponent.php b/lib/Cake/Controller/Component/SecurityComponent.php index 39110b7c5..87e4211eb 100644 --- a/lib/Cake/Controller/Component/SecurityComponent.php +++ b/lib/Cake/Controller/Component/SecurityComponent.php @@ -470,8 +470,8 @@ class SecurityComponent extends Component { $multi = array(); foreach ($fieldList as $i => $key) { - if (preg_match('/(\.\d{1,10})+$/', $key)) { - $multi[$i] = preg_replace('/(\.\d{1,10})+$/', '', $key); + if (preg_match('/(\.\d+){1,10}$/', $key)) { + $multi[$i] = preg_replace('/(\.\d+){1,10}$/', '', $key); unset($fieldList[$i]); } }