Merge branch 'develop' into 11.0_https

This commit is contained in:
Alexandre SPANGARO
2019-10-01 06:11:43 +02:00
894 changed files with 75831 additions and 24232 deletions

View File

@@ -130,6 +130,24 @@ class SecurityTest extends PHPUnit\Framework\TestCase
print __METHOD__."\n";
}
/**
* testSetLang
*
* @return string
*/
public function testSetLang()
{
global $conf;
$conf=$this->savconf;
$tmplangs = new Translate('', $conf);
$_SERVER['HTTP_ACCEPT_LANGUAGE'] = "' malicious text with quote";
$tmplangs->setDefaultLang('auto');
print __METHOD__.' $tmplangs->defaultlang='.$tmplangs->defaultlang."\n";
$this->assertEquals($tmplangs->defaultlang, 'malicioustextwithquote_MALICIOUSTEXTWITHQUOTE');
}
/**
* testGETPOST
*