Add 'Alphanumeric' rule type
authorSean Madsen <sean@seanmadsen.com>
Tue, 24 Apr 2018 20:38:23 +0000 (16:38 -0400)
committereileen <emcnaughton@wikimedia.org>
Tue, 5 Jun 2018 05:15:43 +0000 (17:15 +1200)
commitd22982f32b26ff16cfdd4980bb57f866f015abde
tree201f3a54befb74a0c20d610d506a4d451563b57e
parent708fac750d05f4223c89f9adaac9b6b3c0455f8a
Add 'Alphanumeric' rule type

This type is now available when reading GET parameters with
`CRM_Utils_Request::retrieve()` and it offers improved security over the
widely used 'String' type by being strict enough to reject just about
any conceivable attack payload, while still accepting relatively simple
strings.
CRM/Utils/Rule.php
CRM/Utils/Type.php
tests/phpunit/CRM/Utils/RuleTest.php