summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Grekas <nicolas.grekas@gmail.com>2015-06-18 18:14:27 +0200
committerNicolas Grekas <nicolas.grekas@gmail.com>2015-06-18 18:14:27 +0200
commite92b6d4fee8cb5a22a33230897153bf290b3c4c9 (patch)
tree7ff59492198b0edf2a11c7a856817068df8dbe94
parentbb80188e3b42a85f6c4ead17332098cab3f62aac (diff)
parentfd0b8b96fe220887ba93535742343df84078cd93 (diff)
downloadsymfony-security-e92b6d4fee8cb5a22a33230897153bf290b3c4c9.zip
symfony-security-e92b6d4fee8cb5a22a33230897153bf290b3c4c9.tar.gz
symfony-security-e92b6d4fee8cb5a22a33230897153bf290b3c4c9.tar.bz2
Merge branch '2.7' into 2.8
* 2.7: (36 commits) [DoctrineBridge] Bypass the db when no valid identifier is provided in ORMQueryBuilderLoader [Serializer] Fixed typo in comment [Form] Fixed: Filter non-integers when selecting entities by int ID Fix merge Fix merge Add test for HHVM FatalErrors [2.6][Debug] Fix fatal-errors handling on HHVM [Debug] Fix log level of stacked errors [VarDumper] Fix uninitialized id in HtmlDumper Fixed fluent interface [Console] Fix tests on Windows [2.7] Fix unsilenced deprecation notices [2.3][Debug] Fix fatal-errors handling on HHVM [Debug] fix debug class loader case test on windows Standardize the name of the exception variables [Debug+VarDumper] Fix handling of PHP7 exception/error model Do not trigger deprecation error in ResolveParameterPlaceHoldersPass [2.3] Static Code Analysis for Components Added a small Upgrade note regarding security.context added missing deprecation in CHANGELOG ... Conflicts: src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/logger.html.twig src/Symfony/Component/HttpKernel/Kernel.php
-rw-r--r--Acl/Dbal/AclProvider.php4
-rw-r--r--Acl/Dbal/MutableAclProvider.php12
-rw-r--r--Acl/Domain/ObjectIdentity.php4
-rw-r--r--Acl/Domain/ObjectIdentityRetrievalStrategy.php2
-rw-r--r--Acl/Domain/PermissionGrantingStrategy.php16
-rw-r--r--Acl/Domain/SecurityIdentityRetrievalStrategy.php2
-rw-r--r--Acl/Permission/MaskBuilder.php2
-rw-r--r--Acl/Tests/Dbal/AclProviderTest.php8
-rw-r--r--Acl/Tests/Dbal/MutableAclProviderTest.php6
-rw-r--r--Acl/Tests/Domain/PermissionGrantingStrategyTest.php2
-rw-r--r--Acl/Voter/AclVoter.php4
-rw-r--r--CHANGELOG.md1
-rw-r--r--Core/Authentication/Provider/DaoAuthenticationProvider.php14
-rw-r--r--Core/Authentication/Provider/UserAuthenticationProvider.php8
-rw-r--r--Core/Resources/translations/security.bg.xlf71
-rw-r--r--Core/Resources/translations/security.da.xlf2
-rw-r--r--Core/Resources/translations/security.fr.xlf12
-rw-r--r--Core/Resources/translations/security.hr.xlf71
-rw-r--r--Core/Resources/translations/security.id.xlf71
-rw-r--r--Core/Resources/translations/security.ja.xlf71
-rw-r--r--Core/Resources/translations/security.lt.xlf71
-rw-r--r--Core/Resources/translations/security.no.xlf2
-rw-r--r--Core/Resources/translations/security.pt_BR.xlf8
-rw-r--r--Core/Resources/translations/security.pt_PT.xlf6
-rw-r--r--Core/Resources/translations/security.th.xlf71
-rw-r--r--Core/Resources/translations/security.vi.xlf71
-rw-r--r--Core/Resources/translations/security.zh_CN.xlf71
-rw-r--r--Core/User/ChainUserProvider.php12
-rw-r--r--Http/Firewall/AbstractPreAuthenticatedListener.php8
-rw-r--r--Http/Firewall/BasicAuthenticationListener.php6
-rw-r--r--Http/Firewall/ContextListener.php12
-rw-r--r--Http/Firewall/DigestAuthenticationListener.php2
-rw-r--r--Http/Firewall/RememberMeListener.php6
-rw-r--r--Http/RememberMe/AbstractRememberMeServices.php12
-rw-r--r--Http/RememberMe/RememberMeServicesInterface.php4
-rw-r--r--Http/RememberMe/TokenBasedRememberMeServices.php8
-rw-r--r--Http/Session/SessionAuthenticationStrategyInterface.php2
-rw-r--r--Http/Tests/RememberMe/PersistentTokenBasedRememberMeServicesTest.php2
38 files changed, 661 insertions, 96 deletions
diff --git a/Acl/Dbal/AclProvider.php b/Acl/Dbal/AclProvider.php
index 19b902f..989e40b 100644
--- a/Acl/Dbal/AclProvider.php
+++ b/Acl/Dbal/AclProvider.php
@@ -177,13 +177,13 @@ class AclProvider implements AclProviderInterface
if ($currentBatchesCount > 0 && (self::MAX_BATCH_SIZE === $currentBatchesCount || ($i + 1) === $c)) {
try {
$loadedBatch = $this->lookupObjectIdentities($currentBatch, $sids, $oidLookup);
- } catch (AclNotFoundException $aclNotFoundException) {
+ } catch (AclNotFoundException $e) {
if ($result->count()) {
$partialResultException = new NotAllAclsFoundException('The provider could not find ACLs for all object identities.');
$partialResultException->setPartialResult($result);
throw $partialResultException;
} else {
- throw $aclNotFoundException;
+ throw $e;
}
}
foreach ($loadedBatch as $loadedOid) {
diff --git a/Acl/Dbal/MutableAclProvider.php b/Acl/Dbal/MutableAclProvider.php
index 7d802d4..9129e8b 100644
--- a/Acl/Dbal/MutableAclProvider.php
+++ b/Acl/Dbal/MutableAclProvider.php
@@ -63,10 +63,10 @@ class MutableAclProvider extends AclProvider implements MutableAclProviderInterf
$this->connection->executeQuery($this->getInsertObjectIdentityRelationSql($pk, $pk));
$this->connection->commit();
- } catch (\Exception $failed) {
+ } catch (\Exception $e) {
$this->connection->rollBack();
- throw $failed;
+ throw $e;
}
// re-read the ACL from the database to ensure proper caching, etc.
@@ -91,10 +91,10 @@ class MutableAclProvider extends AclProvider implements MutableAclProviderInterf
$this->deleteObjectIdentity($oidPK);
$this->connection->commit();
- } catch (\Exception $failed) {
+ } catch (\Exception $e) {
$this->connection->rollBack();
- throw $failed;
+ throw $e;
}
// evict the ACL from the in-memory identity map
@@ -338,10 +338,10 @@ class MutableAclProvider extends AclProvider implements MutableAclProviderInterf
}
$this->connection->commit();
- } catch (\Exception $failed) {
+ } catch (\Exception $e) {
$this->connection->rollBack();
- throw $failed;
+ throw $e;
}
$this->propertyChanges->offsetSet($acl, array());
diff --git a/Acl/Domain/ObjectIdentity.php b/Acl/Domain/ObjectIdentity.php
index fc5b9c6..871bda7 100644
--- a/Acl/Domain/ObjectIdentity.php
+++ b/Acl/Domain/ObjectIdentity.php
@@ -68,8 +68,8 @@ final class ObjectIdentity implements ObjectIdentityInterface
} elseif (method_exists($domainObject, 'getId')) {
return new self((string) $domainObject->getId(), ClassUtils::getRealClass($domainObject));
}
- } catch (\InvalidArgumentException $invalid) {
- throw new InvalidDomainObjectException($invalid->getMessage(), 0, $invalid);
+ } catch (\InvalidArgumentException $e) {
+ throw new InvalidDomainObjectException($e->getMessage(), 0, $e);
}
throw new InvalidDomainObjectException('$domainObject must either implement the DomainObjectInterface, or have a method named "getId".');
diff --git a/Acl/Domain/ObjectIdentityRetrievalStrategy.php b/Acl/Domain/ObjectIdentityRetrievalStrategy.php
index 21ac812..80de6e0 100644
--- a/Acl/Domain/ObjectIdentityRetrievalStrategy.php
+++ b/Acl/Domain/ObjectIdentityRetrievalStrategy.php
@@ -28,7 +28,7 @@ class ObjectIdentityRetrievalStrategy implements ObjectIdentityRetrievalStrategy
{
try {
return ObjectIdentity::fromDomainObject($domainObject);
- } catch (InvalidDomainObjectException $failed) {
+ } catch (InvalidDomainObjectException $e) {
return;
}
}
diff --git a/Acl/Domain/PermissionGrantingStrategy.php b/Acl/Domain/PermissionGrantingStrategy.php
index ef80a20..742c4e5 100644
--- a/Acl/Domain/PermissionGrantingStrategy.php
+++ b/Acl/Domain/PermissionGrantingStrategy.php
@@ -55,21 +55,21 @@ class PermissionGrantingStrategy implements PermissionGrantingStrategyInterface
}
return $this->hasSufficientPermissions($acl, $aces, $masks, $sids, $administrativeMode);
- } catch (NoAceFoundException $noObjectAce) {
+ } catch (NoAceFoundException $e) {
$aces = $acl->getClassAces();
if (!$aces) {
- throw $noObjectAce;
+ throw $e;
}
return $this->hasSufficientPermissions($acl, $aces, $masks, $sids, $administrativeMode);
}
- } catch (NoAceFoundException $noClassAce) {
+ } catch (NoAceFoundException $e) {
if ($acl->isEntriesInheriting() && null !== $parentAcl = $acl->getParentAcl()) {
return $parentAcl->isGranted($masks, $sids, $administrativeMode);
}
- throw $noClassAce;
+ throw $e;
}
}
@@ -86,20 +86,20 @@ class PermissionGrantingStrategy implements PermissionGrantingStrategyInterface
}
return $this->hasSufficientPermissions($acl, $aces, $masks, $sids, $administrativeMode);
- } catch (NoAceFoundException $noObjectAces) {
+ } catch (NoAceFoundException $e) {
$aces = $acl->getClassFieldAces($field);
if (!$aces) {
- throw $noObjectAces;
+ throw $e;
}
return $this->hasSufficientPermissions($acl, $aces, $masks, $sids, $administrativeMode);
}
- } catch (NoAceFoundException $noClassAces) {
+ } catch (NoAceFoundException $e) {
if ($acl->isEntriesInheriting() && null !== $parentAcl = $acl->getParentAcl()) {
return $parentAcl->isFieldGranted($field, $masks, $sids, $administrativeMode);
}
- throw $noClassAces;
+ throw $e;
}
}
diff --git a/Acl/Domain/SecurityIdentityRetrievalStrategy.php b/Acl/Domain/SecurityIdentityRetrievalStrategy.php
index 708c633..a08f67e 100644
--- a/Acl/Domain/SecurityIdentityRetrievalStrategy.php
+++ b/Acl/Domain/SecurityIdentityRetrievalStrategy.php
@@ -51,7 +51,7 @@ class SecurityIdentityRetrievalStrategy implements SecurityIdentityRetrievalStra
if (!$token instanceof AnonymousToken) {
try {
$sids[] = UserSecurityIdentity::fromToken($token);
- } catch (\InvalidArgumentException $invalid) {
+ } catch (\InvalidArgumentException $e) {
// ignore, user has no user security identity
}
}
diff --git a/Acl/Permission/MaskBuilder.php b/Acl/Permission/MaskBuilder.php
index 74ecaf6..4788a1f 100644
--- a/Acl/Permission/MaskBuilder.php
+++ b/Acl/Permission/MaskBuilder.php
@@ -82,7 +82,7 @@ class MaskBuilder extends AbstractMaskBuilder
if ('1' === $bitmask[$i]) {
try {
$pattern[$i] = self::getCode(1 << ($length - $i - 1));
- } catch (\Exception $notPredefined) {
+ } catch (\Exception $e) {
$pattern[$i] = self::ON;
}
}
diff --git a/Acl/Tests/Dbal/AclProviderTest.php b/Acl/Tests/Dbal/AclProviderTest.php
index 9470d80..becfb51 100644
--- a/Acl/Tests/Dbal/AclProviderTest.php
+++ b/Acl/Tests/Dbal/AclProviderTest.php
@@ -45,11 +45,11 @@ class AclProviderTest extends \PHPUnit_Framework_TestCase
$this->getProvider()->findAcls($oids);
$this->fail('Provider did not throw an expected exception.');
- } catch (\Exception $ex) {
- $this->assertInstanceOf('Symfony\Component\Security\Acl\Exception\AclNotFoundException', $ex);
- $this->assertInstanceOf('Symfony\Component\Security\Acl\Exception\NotAllAclsFoundException', $ex);
+ } catch (\Exception $e) {
+ $this->assertInstanceOf('Symfony\Component\Security\Acl\Exception\AclNotFoundException', $e);
+ $this->assertInstanceOf('Symfony\Component\Security\Acl\Exception\NotAllAclsFoundException', $e);
- $partialResult = $ex->getPartialResult();
+ $partialResult = $e->getPartialResult();
$this->assertTrue($partialResult->contains($oids[0]));
$this->assertFalse($partialResult->contains($oids[1]));
}
diff --git a/Acl/Tests/Dbal/MutableAclProviderTest.php b/Acl/Tests/Dbal/MutableAclProviderTest.php
index edf64ba..37e1d77 100644
--- a/Acl/Tests/Dbal/MutableAclProviderTest.php
+++ b/Acl/Tests/Dbal/MutableAclProviderTest.php
@@ -88,7 +88,7 @@ class MutableAclProviderTest extends \PHPUnit_Framework_TestCase
try {
$provider->findAcl($oid);
$this->fail('ACL has not been properly deleted.');
- } catch (AclNotFoundException $notFound) {
+ } catch (AclNotFoundException $e) {
}
}
@@ -104,7 +104,7 @@ class MutableAclProviderTest extends \PHPUnit_Framework_TestCase
try {
$provider->findAcl(new ObjectIdentity(1, 'Foo'));
$this->fail('Child-ACLs have not been deleted.');
- } catch (AclNotFoundException $notFound) {
+ } catch (AclNotFoundException $e) {
}
}
@@ -290,7 +290,7 @@ class MutableAclProviderTest extends \PHPUnit_Framework_TestCase
try {
$provider->updateAcl($acl1);
$this->fail('Provider failed to detect a concurrent modification.');
- } catch (ConcurrentModificationException $ex) {
+ } catch (ConcurrentModificationException $e) {
}
}
diff --git a/Acl/Tests/Domain/PermissionGrantingStrategyTest.php b/Acl/Tests/Domain/PermissionGrantingStrategyTest.php
index c7675ea..34ef690 100644
--- a/Acl/Tests/Domain/PermissionGrantingStrategyTest.php
+++ b/Acl/Tests/Domain/PermissionGrantingStrategyTest.php
@@ -154,7 +154,7 @@ class PermissionGrantingStrategyTest extends \PHPUnit_Framework_TestCase
try {
$strategy->isGranted($acl, array($requiredMask), array($sid));
$this->fail('The ACE is not supposed to match.');
- } catch (NoAceFoundException $noAce) {
+ } catch (NoAceFoundException $e) {
}
} else {
$this->assertTrue($strategy->isGranted($acl, array($requiredMask), array($sid)));
diff --git a/Acl/Voter/AclVoter.php b/Acl/Voter/AclVoter.php
index 7022231..ec6024a 100644
--- a/Acl/Voter/AclVoter.php
+++ b/Acl/Voter/AclVoter.php
@@ -113,13 +113,13 @@ class AclVoter implements VoterInterface
}
return self::ACCESS_DENIED;
- } catch (AclNotFoundException $noAcl) {
+ } catch (AclNotFoundException $e) {
if (null !== $this->logger) {
$this->logger->debug('No ACL found for the object identity. Voting to deny access.');
}
return self::ACCESS_DENIED;
- } catch (NoAceFoundException $noAce) {
+ } catch (NoAceFoundException $e) {
if (null !== $this->logger) {
$this->logger->debug('ACL found, no ACE applicable. Voting to deny access.');
}
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 052f883..22eb9cd 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -19,6 +19,7 @@ CHANGELOG
2.4.0
-----
+ * Translations in the `src/Symfony/Component/Security/Resources/translations/` directory are deprecated, ones in `src/Symfony/Component/Security/Core/Resources/translations/` must be used instead.
* The switch user listener now preserves the query string when switching a user
* The remember-me cookie hashes now use HMAC, which means that current cookies will be invalidated
* added simpler customization options
diff --git a/Core/Authentication/Provider/DaoAuthenticationProvider.php b/Core/Authentication/Provider/DaoAuthenticationProvider.php
index b7b4917..90cba25 100644
--- a/Core/Authentication/Provider/DaoAuthenticationProvider.php
+++ b/Core/Authentication/Provider/DaoAuthenticationProvider.php
@@ -87,13 +87,13 @@ class DaoAuthenticationProvider extends UserAuthenticationProvider
}
return $user;
- } catch (UsernameNotFoundException $notFound) {
- $notFound->setUsername($username);
- throw $notFound;
- } catch (\Exception $repositoryProblem) {
- $ex = new AuthenticationServiceException($repositoryProblem->getMessage(), 0, $repositoryProblem);
- $ex->setToken($token);
- throw $ex;
+ } catch (UsernameNotFoundException $e) {
+ $e->setUsername($username);
+ throw $e;
+ } catch (\Exception $e) {
+ $e = new AuthenticationServiceException($e->getMessage(), 0, $e);
+ $e->setToken($token);
+ throw $e;
}
}
}
diff --git a/Core/Authentication/Provider/UserAuthenticationProvider.php b/Core/Authentication/Provider/UserAuthenticationProvider.php
index 55ebed4..ded53e4 100644
--- a/Core/Authentication/Provider/UserAuthenticationProvider.php
+++ b/Core/Authentication/Provider/UserAuthenticationProvider.php
@@ -68,13 +68,13 @@ abstract class UserAuthenticationProvider implements AuthenticationProviderInter
try {
$user = $this->retrieveUser($username, $token);
- } catch (UsernameNotFoundException $notFound) {
+ } catch (UsernameNotFoundException $e) {
if ($this->hideUserNotFoundExceptions) {
- throw new BadCredentialsException('Bad credentials.', 0, $notFound);
+ throw new BadCredentialsException('Bad credentials.', 0, $e);
}
- $notFound->setUsername($username);
+ $e->setUsername($username);
- throw $notFound;
+ throw $e;
}
if (!$user instanceof UserInterface) {
diff --git a/Core/Resources/translations/security.bg.xlf b/Core/Resources/translations/security.bg.xlf
new file mode 100644
index 0000000..06692ea
--- /dev/null
+++ b/Core/Resources/translations/security.bg.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>Грешка при автентикация.</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>Удостоверението за автентикация не е открито.</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>Заявката за автентикация не може да бъде обработената поради системна грешка.</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>Невалидно удостоверение за автентикация.</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Това cookie вече се ползва от някой друг.</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>Нямате права за достъп до този ресурс.</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>Невалиден CSRF токен.</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Digest nonce е изтекъл.</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>Не е открит провайдър, който да поддържа този токен за автентикация.</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Сесията не е достъпна, или времето за достъп е изтекло, или кукитата не са разрешени.</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>Токена не е открит.</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>Потребителското име не е открито.</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>Акаунта е изтекъл.</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>Удостоверението за автентикация е изтекло.</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>Акаунта е деактивиран.</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>Акаунта е заключен.</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.da.xlf b/Core/Resources/translations/security.da.xlf
index 9c7b886..2ac4150 100644
--- a/Core/Resources/translations/security.da.xlf
+++ b/Core/Resources/translations/security.da.xlf
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
- <file source-language="no" datatype="plaintext" original="file.ext">
+ <file source-language="en" datatype="plaintext" original="file.ext">
<body>
<trans-unit id="1">
<source>An authentication exception occurred.</source>
diff --git a/Core/Resources/translations/security.fr.xlf b/Core/Resources/translations/security.fr.xlf
index f3965d3..5a77c6e 100644
--- a/Core/Resources/translations/security.fr.xlf
+++ b/Core/Resources/translations/security.fr.xlf
@@ -8,7 +8,7 @@
</trans-unit>
<trans-unit id="2">
<source>Authentication credentials could not be found.</source>
- <target>Les droits d'authentification n'ont pas pu être trouvés.</target>
+ <target>Les identifiants d'authentification n'ont pas pu être trouvés.</target>
</trans-unit>
<trans-unit id="3">
<source>Authentication request could not be processed due to a system problem.</source>
@@ -16,7 +16,7 @@
</trans-unit>
<trans-unit id="4">
<source>Invalid credentials.</source>
- <target>Droits invalides.</target>
+ <target>Identifiants invalides.</target>
</trans-unit>
<trans-unit id="5">
<source>Cookie has already been used by someone else.</source>
@@ -24,7 +24,7 @@
</trans-unit>
<trans-unit id="6">
<source>Not privileged to request the resource.</source>
- <target>Pas de privilèges pour accéder à la ressource.</target>
+ <target>Privilèges insuffisants pour accéder à la ressource.</target>
</trans-unit>
<trans-unit id="7">
<source>Invalid CSRF token.</source>
@@ -40,7 +40,7 @@
</trans-unit>
<trans-unit id="10">
<source>No session available, it either timed out or cookies are not enabled.</source>
- <target>Pas de session disponible, celle-ci a expiré ou les cookies ne sont pas activés.</target>
+ <target>Aucune session disponible, celle-ci a expiré ou les cookies ne sont pas activés.</target>
</trans-unit>
<trans-unit id="11">
<source>No token could be found.</source>
@@ -48,7 +48,7 @@
</trans-unit>
<trans-unit id="12">
<source>Username could not be found.</source>
- <target>Le nom d'utilisateur ne peut pas être trouvé.</target>
+ <target>Le nom d'utilisateur n'a pas pu être trouvé.</target>
</trans-unit>
<trans-unit id="13">
<source>Account has expired.</source>
@@ -56,7 +56,7 @@
</trans-unit>
<trans-unit id="14">
<source>Credentials have expired.</source>
- <target>Les droits ont expirés.</target>
+ <target>Les identifiants ont expiré.</target>
</trans-unit>
<trans-unit id="15">
<source>Account is disabled.</source>
diff --git a/Core/Resources/translations/security.hr.xlf b/Core/Resources/translations/security.hr.xlf
new file mode 100644
index 0000000..147b6e3
--- /dev/null
+++ b/Core/Resources/translations/security.hr.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>Dogodila se autentifikacijske iznimka.</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>Autentifikacijski podaci nisu pronađeni.</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>Autentifikacijski zahtjev nije moguće provesti uslijed sistemskog problema.</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>Neispravni akreditacijski podaci.</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie je već netko drugi iskoristio.</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>Nemate privilegije zahtijevati resurs.</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>Neispravan CSRF token.</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Digest nonce je isteko.</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>Nije pronađen autentifikacijski provider koji bi podržao autentifikacijski token.</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Sesija nije dostupna, ili je istekla ili cookies nisu omogućeni.</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>Token nije pronađen.</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>Korisničko ime nije pronađeno.</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>Račun je isteko.</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>Akreditacijski podaci su istekli.</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>Račun je onemogućen.</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>Račun je zaključan.</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.id.xlf b/Core/Resources/translations/security.id.xlf
new file mode 100644
index 0000000..ab1153b
--- /dev/null
+++ b/Core/Resources/translations/security.id.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>Terjadi sebuah pengecualian otentikasi.</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>Kredensial otentikasi tidak bisa ditemukan.</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>Permintaan otentikasi tidak bisa diproses karena masalah sistem.</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>Kredensial salah.</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie sudah digunakan oleh orang lain.</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>Tidak berhak untuk meminta sumber daya.</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>Token CSRF salah.</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Digest nonce telah berakhir.</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>Tidak ditemukan penyedia otentikasi untuk mendukung token otentikasi.</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Tidak ada sesi yang tersedia, mungkin waktu sudah habis atau cookie tidak diaktifkan</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>Tidak ada token yang bisa ditemukan.</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>Username tidak bisa ditemukan.</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>Akun telah berakhir.</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>Kredensial telah berakhir.</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>Akun dinonaktifkan.</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>Akun terkunci.</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.ja.xlf b/Core/Resources/translations/security.ja.xlf
new file mode 100644
index 0000000..6a6b062
--- /dev/null
+++ b/Core/Resources/translations/security.ja.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>認証エラーが発生しました。</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>認証資格がありません。</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>システムの問題により認証要求を処理できませんでした。</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>資格が無効です。</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie が別のユーザーで使用されています。</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>リソースをリクエストする権限がありません。</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>CSRF トークンが無効です。</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Digest の nonce 値が期限切れです。</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>認証トークンをサポートする認証プロバイダーが見つかりません。</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>利用可能なセッションがありません。タイムアウトしたか、Cookie が無効になっています。</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>トークンが見つかりません。</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>ユーザー名が見つかりません。</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>アカウントが有効期限切れです。</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>資格が有効期限切れです。</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>アカウントが無効です。</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>アカウントはロックされています。</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.lt.xlf b/Core/Resources/translations/security.lt.xlf
new file mode 100644
index 0000000..da6c332
--- /dev/null
+++ b/Core/Resources/translations/security.lt.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>Įvyko autentifikacijos klaida.</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>Nepavyko rasti autentifikacijos duomneų.</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>Autentifikacijos užklausos nepavyko įvykdyti dėl sistemos klaidų.</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>Klaidingi duomenys.</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Slapukas buvo panaudotas kažkam kitam.</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>Neturite teisių pasiektį resursą.</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>Neteisingas CSRF raktas.</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Prieigos kodas yra pasibaigęs.</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>Nerastas autentifikacijos tiekėjas, kuris palaikytų autentifikacijos raktą.</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Sesija yra nepasiekiama, pasibaigė galiojimo laikas arba slapukai yra išjungti.</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>Nepavyko rasti rakto.</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>Tokio naudotojo vardo nepavyko rasti.</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>Paskyros galiojimo laikas baigėsi.</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>Autentifikacijos duomenų galiojimo laikas baigėsi.</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>Paskyra yra išjungta.</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>Paskyra yra užblokuota.</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.no.xlf b/Core/Resources/translations/security.no.xlf
index 3857ab4..3369d43 100644
--- a/Core/Resources/translations/security.no.xlf
+++ b/Core/Resources/translations/security.no.xlf
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
- <file source-language="no" datatype="plaintext" original="file.ext">
+ <file source-language="en" datatype="plaintext" original="file.ext">
<body>
<trans-unit id="1">
<source>An authentication exception occurred.</source>
diff --git a/Core/Resources/translations/security.pt_BR.xlf b/Core/Resources/translations/security.pt_BR.xlf
index 846fd49..61685d9 100644
--- a/Core/Resources/translations/security.pt_BR.xlf
+++ b/Core/Resources/translations/security.pt_BR.xlf
@@ -20,7 +20,7 @@
</trans-unit>
<trans-unit id="5">
<source>Cookie has already been used by someone else.</source>
- <target>Este cookie já esta em uso.</target>
+ <target>Este cookie já está em uso.</target>
</trans-unit>
<trans-unit id="6">
<source>Not privileged to request the resource.</source>
@@ -40,7 +40,7 @@
</trans-unit>
<trans-unit id="10">
<source>No session available, it either timed out or cookies are not enabled.</source>
- <target>Nenhuma sessão disponível, ela expirou ou cookies estão desativados.</target>
+ <target>Nenhuma sessão disponível, ela expirou ou os cookies estão desativados.</target>
</trans-unit>
<trans-unit id="11">
<source>No token could be found.</source>
@@ -52,7 +52,7 @@
</trans-unit>
<trans-unit id="13">
<source>Account has expired.</source>
- <target>A conta esta expirada.</target>
+ <target>A conta está expirada.</target>
</trans-unit>
<trans-unit id="14">
<source>Credentials have expired.</source>
@@ -64,7 +64,7 @@
</trans-unit>
<trans-unit id="16">
<source>Account is locked.</source>
- <target>A conta esta travada.</target>
+ <target>A conta está travada.</target>
</trans-unit>
</body>
</file>
diff --git a/Core/Resources/translations/security.pt_PT.xlf b/Core/Resources/translations/security.pt_PT.xlf
index e661000..f2af13e 100644
--- a/Core/Resources/translations/security.pt_PT.xlf
+++ b/Core/Resources/translations/security.pt_PT.xlf
@@ -4,7 +4,7 @@
<body>
<trans-unit id="1">
<source>An authentication exception occurred.</source>
- <target>Ocorreu um excepção durante a autenticação.</target>
+ <target>Ocorreu uma excepção durante a autenticação.</target>
</trans-unit>
<trans-unit id="2">
<source>Authentication credentials could not be found.</source>
@@ -20,7 +20,7 @@
</trans-unit>
<trans-unit id="5">
<source>Cookie has already been used by someone else.</source>
- <target>Este cookie já esta em uso.</target>
+ <target>Este cookie já está em uso.</target>
</trans-unit>
<trans-unit id="6">
<source>Not privileged to request the resource.</source>
@@ -64,7 +64,7 @@
</trans-unit>
<trans-unit id="16">
<source>Account is locked.</source>
- <target>A conta esta trancada.</target>
+ <target>A conta está trancada.</target>
</trans-unit>
</body>
</file>
diff --git a/Core/Resources/translations/security.th.xlf b/Core/Resources/translations/security.th.xlf
new file mode 100644
index 0000000..a8cb8d5
--- /dev/null
+++ b/Core/Resources/translations/security.th.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>พบความผิดพลาดในการรับรองตัวตน</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>ไม่พบข้อมูลในการรับรองตัวตน (credentials) </target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>คำร้องในการรับรองตัวตนไม่สามารถดำเนินการได้ เนื่องมาจากปัญหาของระบบ</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>ข้อมูลการรับรองตัวตนไม่ถูกต้อง</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie ถูกใช้งานไปแล้วด้วยผู้อื่น</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>ไม่ได้รับสิทธิ์ให้ใช้งานส่วนนี้ได้</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>CSRF token ไม่ถูกต้อง</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Digest nonce หมดอายุ</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>ไม่พบ authentication provider ที่รองรับสำหรับ authentication token</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>ไม่มี session ที่พร้อมใช้งาน, Session หมดอายุไปแล้วหรือ cookies ไม่ถูกเปิดใช้งาน</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>ไม่พบ token</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>ไม่พบ Username</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>บัญชีหมดอายุไปแล้ว</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>ข้อมูลการระบุตัวตนหมดอายุแล้ว</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>บัญชีถูกระงับแล้ว</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>บัญชีถูกล็อกแล้ว</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.vi.xlf b/Core/Resources/translations/security.vi.xlf
new file mode 100644
index 0000000..b85a439
--- /dev/null
+++ b/Core/Resources/translations/security.vi.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>Có lỗi trong quá trình xác thực.</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>Thông tin dùng để xác thực không tìm thấy.</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>Yêu cầu xác thực không thể thực hiện do lỗi của hệ thống.</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>Thông tin dùng để xác thực không hợp lệ.</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie đã được dùng bởi người dùng khác.</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>Không được phép yêu cầu tài nguyên.</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>Mã CSRF không hợp lệ.</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>Mã dùng một lần đã hết hạn.</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>Không tìm thấy nhà cung cấp dịch vụ xác thực nào cho mã xác thực mà bạn sử dụng.</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Không tìm thấy phiên làm việc. Phiên làm việc hoặc cookie có thể bị tắt.</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>Không tìm thấy mã token.</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>Không tìm thấy tên người dùng username.</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>Tài khoản đã hết hạn.</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>Thông tin xác thực đã hết hạn.</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>Tài khoản bị tạm ngừng.</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>Tài khoản bị khóa.</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/Resources/translations/security.zh_CN.xlf b/Core/Resources/translations/security.zh_CN.xlf
new file mode 100644
index 0000000..2d6affe
--- /dev/null
+++ b/Core/Resources/translations/security.zh_CN.xlf
@@ -0,0 +1,71 @@
+<?xml version="1.0"?>
+<xliff version="1.2" xmlns="urn:oasis:names:tc:xliff:document:1.2">
+ <file source-language="en" datatype="plaintext" original="file.ext">
+ <body>
+ <trans-unit id="1">
+ <source>An authentication exception occurred.</source>
+ <target>身份验证发生异常。</target>
+ </trans-unit>
+ <trans-unit id="2">
+ <source>Authentication credentials could not be found.</source>
+ <target>没有找到身份验证的凭证。</target>
+ </trans-unit>
+ <trans-unit id="3">
+ <source>Authentication request could not be processed due to a system problem.</source>
+ <target>由于系统故障,身份验证的请求无法被处理。</target>
+ </trans-unit>
+ <trans-unit id="4">
+ <source>Invalid credentials.</source>
+ <target>无效的凭证。</target>
+ </trans-unit>
+ <trans-unit id="5">
+ <source>Cookie has already been used by someone else.</source>
+ <target>Cookie 已经被其他人使用。</target>
+ </trans-unit>
+ <trans-unit id="6">
+ <source>Not privileged to request the resource.</source>
+ <target>没有权限请求此资源。</target>
+ </trans-unit>
+ <trans-unit id="7">
+ <source>Invalid CSRF token.</source>
+ <target>无效的 CSRF token 。</target>
+ </trans-unit>
+ <trans-unit id="8">
+ <source>Digest nonce has expired.</source>
+ <target>摘要随机串(digest nonce)已过期。</target>
+ </trans-unit>
+ <trans-unit id="9">
+ <source>No authentication provider found to support the authentication token.</source>
+ <target>没有找到支持此 token 的身份验证服务提供方。</target>
+ </trans-unit>
+ <trans-unit id="10">
+ <source>No session available, it either timed out or cookies are not enabled.</source>
+ <target>Session 不可用。会话超时或没有启用 cookies 。</target>
+ </trans-unit>
+ <trans-unit id="11">
+ <source>No token could be found.</source>
+ <target>找不到 token 。</target>
+ </trans-unit>
+ <trans-unit id="12">
+ <source>Username could not be found.</source>
+ <target>找不到用户名。</target>
+ </trans-unit>
+ <trans-unit id="13">
+ <source>Account has expired.</source>
+ <target>帐号已过期。</target>
+ </trans-unit>
+ <trans-unit id="14">
+ <source>Credentials have expired.</source>
+ <target>凭证已过期。</target>
+ </trans-unit>
+ <trans-unit id="15">
+ <source>Account is disabled.</source>
+ <target>帐号已被禁用。</target>
+ </trans-unit>
+ <trans-unit id="16">
+ <source>Account is locked.</source>
+ <target>帐号已被锁定。</target>
+ </trans-unit>
+ </body>
+ </file>
+</xliff>
diff --git a/Core/User/ChainUserProvider.php b/Core/User/ChainUserProvider.php
index 6e14a4f..8604ddc 100644
--- a/Core/User/ChainUserProvider.php
+++ b/Core/User/ChainUserProvider.php
@@ -47,7 +47,7 @@ class ChainUserProvider implements UserProviderInterface
foreach ($this->providers as $provider) {
try {
return $provider->loadUserByUsername($username);
- } catch (UsernameNotFoundException $notFound) {
+ } catch (UsernameNotFoundException $e) {
// try next one
}
}
@@ -67,18 +67,18 @@ class ChainUserProvider implements UserProviderInterface
foreach ($this->providers as $provider) {
try {
return $provider->refreshUser($user);
- } catch (UnsupportedUserException $unsupported) {
+ } catch (UnsupportedUserException $e) {
// try next one
- } catch (UsernameNotFoundException $notFound) {
+ } catch (UsernameNotFoundException $e) {
$supportedUserFound = true;
// try next one
}
}
if ($supportedUserFound) {
- $ex = new UsernameNotFoundException(sprintf('There is no user with name "%s".', $user->getUsername()));
- $ex->setUsername($user->getUsername());
- throw $ex;
+ $e = new UsernameNotFoundException(sprintf('There is no user with name "%s".', $user->getUsername()));
+ $e->setUsername($user->getUsername());
+ throw $e;
} else {
throw new UnsupportedUserException(sprintf('The account "%s" is not supported.', get_class($user)));
}
diff --git a/Http/Firewall/AbstractPreAuthenticatedListener.php b/Http/Firewall/AbstractPreAuthenticatedListener.php
index 5ed8aa7..b793310 100644
--- a/Http/Firewall/AbstractPreAuthenticatedListener.php
+++ b/Http/Firewall/AbstractPreAuthenticatedListener.php
@@ -58,8 +58,8 @@ abstract class AbstractPreAuthenticatedListener implements ListenerInterface
try {
list($user, $credentials) = $this->getPreAuthenticatedData($request);
- } catch (BadCredentialsException $exception) {
- $this->clearToken($exception);
+ } catch (BadCredentialsException $e) {
+ $this->clearToken($e);
return;
}
@@ -90,8 +90,8 @@ abstract class AbstractPreAuthenticatedListener implements ListenerInterface
$loginEvent = new InteractiveLoginEvent($request, $token);
$this->dispatcher->dispatch(SecurityEvents::INTERACTIVE_LOGIN, $loginEvent);
}
- } catch (AuthenticationException $failed) {
- $this->clearToken($failed);
+ } catch (AuthenticationException $e) {
+ $this->clearToken($e);
}
}
diff --git a/Http/Firewall/BasicAuthenticationListener.php b/Http/Firewall/BasicAuthenticationListener.php
index 11ae8f9..ebe96ea 100644
--- a/Http/Firewall/BasicAuthenticationListener.php
+++ b/Http/Firewall/BasicAuthenticationListener.php
@@ -73,21 +73,21 @@ class BasicAuthenticationListener implements ListenerInterface
try {
$token = $this->authenticationManager->authenticate(new UsernamePasswordToken($username, $request->headers->get('PHP_AUTH_PW'), $this->providerKey));
$this->tokenStorage->setToken($token);
- } catch (AuthenticationException $failed) {
+ } catch (AuthenticationException $e) {
$token = $this->tokenStorage->getToken();
if ($token instanceof UsernamePasswordToken && $this->providerKey === $token->getProviderKey()) {
$this->tokenStorage->setToken(null);
}
if (null !== $this->logger) {
- $this->logger->info('Basic authentication failed for user.', array('username' => $username, 'exception' => $failed));
+ $this->logger->info('Basic authentication failed for user.', array('username' => $username, 'exception' => $e));
}
if ($this->ignoreFailure) {
return;
}
- $event->setResponse($this->authenticationEntryPoint->start($request, $failed));
+ $event->setResponse($this->authenticationEntryPoint->start($request, $e));
}
}
}
diff --git a/Http/Firewall/ContextListener.php b/Http/Firewall/ContextListener.php
index 013586c..9ac37cd 100644
--- a/Http/Firewall/ContextListener.php
+++ b/Http/Firewall/ContextListener.php
@@ -101,7 +101,7 @@ class ContextListener implements ListenerInterface
}
/**
- * Writes the SecurityContext to the session.
+ * Writes the security token into the session.
*
* @param FilterResponseEvent $event A FilterResponseEvent instance
*/
@@ -121,10 +121,6 @@ class ContextListener implements ListenerInterface
$request = $event->getRequest();
$session = $request->getSession();
- if (null === $session) {
- return;
- }
-
if ((null === $token = $this->tokenStorage->getToken()) || ($token instanceof AnonymousToken)) {
if ($request->hasPreviousSession()) {
$session->remove($this->sessionKey);
@@ -164,11 +160,11 @@ class ContextListener implements ListenerInterface
}
return $token;
- } catch (UnsupportedUserException $unsupported) {
+ } catch (UnsupportedUserException $e) {
// let's try the next user provider
- } catch (UsernameNotFoundException $notFound) {
+ } catch (UsernameNotFoundException $e) {
if (null !== $this->logger) {
- $this->logger->warning('Username could not be found in the selected user provider.', array('username' => $notFound->getUsername(), 'provider' => get_class($provider)));
+ $this->logger->warning('Username could not be found in the selected user provider.', array('username' => $e->getUsername(), 'provider' => get_class($provider)));
}
return;
diff --git a/Http/Firewall/DigestAuthenticationListener.php b/Http/Firewall/DigestAuthenticationListener.php
index c5aaca3..9a6fbfe 100644
--- a/Http/Firewall/DigestAuthenticationListener.php
+++ b/Http/Firewall/DigestAuthenticationListener.php
@@ -93,7 +93,7 @@ class DigestAuthenticationListener implements ListenerInterface
}
$serverDigestMd5 = $digestAuth->calculateServerDigest($user->getPassword(), $request->getMethod());
- } catch (UsernameNotFoundException $notFound) {
+ } catch (UsernameNotFoundException $e) {
$this->fail($event, $request, new BadCredentialsException(sprintf('Username %s not found.', $digestAuth->getUsername())));
return;
diff --git a/Http/Firewall/RememberMeListener.php b/Http/Firewall/RememberMeListener.php
index e34627c..f5ec8c7 100644
--- a/Http/Firewall/RememberMeListener.php
+++ b/Http/Firewall/RememberMeListener.php
@@ -83,19 +83,19 @@ class RememberMeListener implements ListenerInterface
if (null !== $this->logger) {
$this->logger->debug('Populated the token storage with a remember-me token.');
}
- } catch (AuthenticationException $failed) {
+ } catch (AuthenticationException $e) {
if (null !== $this->logger) {
$this->logger->warning(
'The token storage was not populated with remember-me token as the'
.' AuthenticationManager rejected the AuthenticationToken returned'
- .' by the RememberMeServices.', array('exception' => $failed)
+ .' by the RememberMeServices.', array('exception' => $e)
);
}
$this->rememberMeServices->loginFail($request);
if (!$this->catchExceptions) {
- throw $failed;
+ throw $e;
}
}
}
diff --git a/Http/RememberMe/AbstractRememberMeServices.php b/Http/RememberMe/AbstractRememberMeServices.php
index 5df82fa..3673ff1 100644
--- a/Http/RememberMe/AbstractRememberMeServices.php
+++ b/Http/RememberMe/AbstractRememberMeServices.php
@@ -123,21 +123,21 @@ abstract class AbstractRememberMeServices implements RememberMeServicesInterface
}
return new RememberMeToken($user, $this->providerKey, $this->key);
- } catch (CookieTheftException $theft) {
+ } catch (CookieTheftException $e) {
$this->cancelCookie($request);
- throw $theft;
- } catch (UsernameNotFoundException $notFound) {
+ throw $e;
+ } catch (UsernameNotFoundException $e) {
if (null !== $this->logger) {
$this->logger->info('User for remember-me cookie not found.');
}
- } catch (UnsupportedUserException $unSupported) {
+ } catch (UnsupportedUserException $e) {
if (null !== $this->logger) {
$this->logger->warning('User class for remember-me cookie not supported.');
}
- } catch (AuthenticationException $invalid) {
+ } catch (AuthenticationException $e) {
if (null !== $this->logger) {
- $this->logger->debug('Remember-Me authentication failed.', array('exception' => $invalid));
+ $this->logger->debug('Remember-Me authentication failed.', array('exception' => $e));
}
}
diff --git a/Http/RememberMe/RememberMeServicesInterface.php b/Http/RememberMe/RememberMeServicesInterface.php
index 7adb827..5750a8c 100644
--- a/Http/RememberMe/RememberMeServicesInterface.php
+++ b/Http/RememberMe/RememberMeServicesInterface.php
@@ -36,8 +36,8 @@ interface RememberMeServicesInterface
const COOKIE_ATTR_NAME = '_security_remember_me_cookie';
/**
- * This method will be called whenever the SecurityContext does not contain
- * an TokenInterface object and the framework wishes to provide an implementation
+ * This method will be called whenever the TokenStorage does not contain
+ * a TokenInterface object and the framework wishes to provide an implementation
* with an opportunity to authenticate the request using remember-me capabilities.
*
* No attempt whatsoever is made to determine whether the browser has requested
diff --git a/Http/RememberMe/TokenBasedRememberMeServices.php b/Http/RememberMe/TokenBasedRememberMeServices.php
index 65bac0a..d68ada5 100644
--- a/Http/RememberMe/TokenBasedRememberMeServices.php
+++ b/Http/RememberMe/TokenBasedRememberMeServices.php
@@ -42,12 +42,12 @@ class TokenBasedRememberMeServices extends AbstractRememberMeServices
}
try {
$user = $this->getUserProvider($class)->loadUserByUsername($username);
- } catch (\Exception $ex) {
- if (!$ex instanceof AuthenticationException) {
- $ex = new AuthenticationException($ex->getMessage(), $ex->getCode(), $ex);
+ } catch (\Exception $e) {
+ if (!$e instanceof AuthenticationException) {
+ $e = new AuthenticationException($e->getMessage(), $e->getCode(), $e);
}
- throw $ex;
+ throw $e;
}
if (!$user instanceof UserInterface) {
diff --git a/Http/Session/SessionAuthenticationStrategyInterface.php b/Http/Session/SessionAuthenticationStrategyInterface.php
index 9cb95d8..dd0c381 100644
--- a/Http/Session/SessionAuthenticationStrategyInterface.php
+++ b/Http/Session/SessionAuthenticationStrategyInterface.php
@@ -27,7 +27,7 @@ interface SessionAuthenticationStrategyInterface
/**
* This performs any necessary changes to the session.
*
- * This method is called before the SecurityContext is populated with a
+ * This method is called before the TokenStorage is populated with a
* Token, and only by classes inheriting from AbstractAuthenticationListener.
*
* @param Request $request
diff --git a/Http/Tests/RememberMe/PersistentTokenBasedRememberMeServicesTest.php b/Http/Tests/RememberMe/PersistentTokenBasedRememberMeServicesTest.php
index 6aee1b1..2fea626 100644
--- a/Http/Tests/RememberMe/PersistentTokenBasedRememberMeServicesTest.php
+++ b/Http/Tests/RememberMe/PersistentTokenBasedRememberMeServicesTest.php
@@ -115,7 +115,7 @@ class PersistentTokenBasedRememberMeServicesTest extends \PHPUnit_Framework_Test
try {
$service->autoLogin($request);
$this->fail('Expected CookieTheftException was not thrown.');
- } catch (CookieTheftException $theft) {
+ } catch (CookieTheftException $e) {
}
$this->assertTrue($request->attributes->has(RememberMeServicesInterface::COOKIE_ATTR_NAME));