[aur-dev] [PATCH] aurjson: Allow underscores in JSONP callback names
Lukas Fleischer
lfleischer at archlinux.org
Sat Oct 24 16:03:42 UTC 2015
Signed-off-by: Lukas Fleischer <lfleischer at archlinux.org>
---
web/lib/aurjson.class.php | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/web/lib/aurjson.class.php b/web/lib/aurjson.class.php
index 1548232..9097035 100644
--- a/web/lib/aurjson.class.php
+++ b/web/lib/aurjson.class.php
@@ -119,7 +119,7 @@ class AurJSON {
if (isset($http_data['callback'])) {
$callback = $http_data['callback'];
- if (!preg_match('/^[a-zA-Z0-9().]{1,128}$/D', $callback)) {
+ if (!preg_match('/^[a-zA-Z0-9()_.]{1,128}$/D', $callback)) {
return $this->json_error('Invalid callback name.');
}
header('content-type: text/javascript');
--
2.6.2
More information about the aur-dev
mailing list