tbrehm
2010-03-03 61c77268159454a8db8b52b7494b451cadf9f698
Fixed: FS#1083 - Make some validation for Redirect paths.
5 files modified
14 ■■■■■ changed files
interface/web/sites/form/web_aliasdomain.tform.php 4 ●●●● patch | view | raw | blame | history
interface/web/sites/form/web_domain.tform.php 4 ●●●● patch | view | raw | blame | history
interface/web/sites/form/web_subdomain.tform.php 4 ●●●● patch | view | raw | blame | history
interface/web/sites/lib/lang/en_web_domain.lng 1 ●●●● patch | view | raw | blame | history
interface/web/sites/lib/lang/en_web_subdomain.lng 1 ●●●● patch | view | raw | blame | history
interface/web/sites/form/web_aliasdomain.tform.php
@@ -111,6 +111,10 @@
        'redirect_path' => array (
            'datatype'    => 'VARCHAR',
            'formtype'    => 'TEXT',
            'validators'    => array (     0 => array (    'type'    => 'REGEX',
                                                        'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
                                                        'errmsg'=> 'redirect_error_regex'),
                                    ),
            'default'    => '',
            'value'        => '',
            'width'        => '30',
interface/web/sites/form/web_domain.tform.php
@@ -223,6 +223,10 @@
        ),
        'redirect_path' => array (
            'datatype'    => 'VARCHAR',
            'validators'    => array (     0 => array (    'type'    => 'REGEX',
                                                        'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
                                                        'errmsg'=> 'redirect_error_regex'),
                                    ),
            'formtype'    => 'TEXT',
            'default'    => '',
            'value'        => '',
interface/web/sites/form/web_subdomain.tform.php
@@ -111,6 +111,10 @@
        'redirect_path' => array (
            'datatype'    => 'VARCHAR',
            'formtype'    => 'TEXT',
            'validators'    => array (     0 => array (    'type'    => 'REGEX',
                                                        'regex' => '@^(([.]{0})|(https?://([-\w\.]+)+(:\d+)?(/([\w/_\.]*(\?\S+)?)?)?)|(/[\w/_\.\-]{1,255}/))$@',
                                                        'errmsg'=> 'redirect_error_regex'),
                                    ),
            'default'    => '',
            'value'        => '',
            'width'        => '30',
interface/web/sites/lib/lang/en_web_domain.lng
@@ -55,4 +55,5 @@
$wb["ssl_organistaion_unit_error_regex"] = 'Invalid SSL Organisation Unit. Valid characters are: a-z, 0-9 and .,-_';
$wb["ssl_country_error_regex"] = 'Invalid SSL Country. Valid characters are: A-Z';
$wb["limit_traffic_quota_free_txt"] = 'Max. available Traffic Quota';
$wb["redirect_error_regex"] = 'Invalid redirect path. Valid redirects are for example: /test/ or http://www.domain.tld/test/';
?>
interface/web/sites/lib/lang/en_web_subdomain.lng
@@ -36,4 +36,5 @@
$wb["domain_error_unique"] = 'There is already a website or sub / aliasdomain with this domain name.';
$wb["domain_error_regex"] = 'Domain name invalid.';
$wb["host_txt"] = 'Host';
$wb["redirect_error_regex"] = 'Invalid redirect path. Valid redirects are for example: /test/ or http://www.domain.tld/test/';
?>