<p dir="auto">There may already be a "standard" in some of the formats for this (e.g. XLIFF), or maybe it's a bad idea for some reason I don't see. Here's the situation:</p>
<p dir="auto">Imagine you're using translation "keys" (e.g. <code class="notranslate">-&gt;trans('first_name')</code> instead of <code class="notranslate">-&gt;trans('First Name')</code>). When you do this, you may often get duplicate keys that should be translated to the same word, causing a translation resource that might look like this:</p>
<div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="registration_first_name: First Name
profile_first_name: First Name"><pre class="notranslate"><span class="pl-ent">registration_first_name</span>: <span class="pl-s">First Name</span>
<span class="pl-ent">profile_first_name</span>: <span class="pl-s">First Name</span></pre></div>
<p dir="auto">This is a DX issue, because it means you have duplicated keys that you need to manage. It also makes you want to stop using more descriptive keys to try to have less duplicates. Also, with a bundle like <code class="notranslate">FOSUserBundle</code> where form labels are turned into keys, you can't avoid duplication (<a href="https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Resources/translations/FOSUserBundle.en.yml">https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Resources/translations/FOSUserBundle.en.yml</a>).</p>
<p dir="auto">I propose that we can "alias" a translation key to use the value of another:</p>
<div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="registration_first_name: &quot;@profile_first_name&quot;
profile_first_name: First Name"><pre class="notranslate"><span class="pl-ent">registration_first_name</span>: <span class="pl-s"><span class="pl-pds">"</span>@profile_first_name<span class="pl-pds">"</span></span>
<span class="pl-ent">profile_first_name</span>: <span class="pl-s">First Name</span></pre></div>
<p dir="auto">Thoughts?</p>
<p dir="auto"><strong>Symfony version(s) affected</strong>: all</p>
<p dir="auto"><strong>Description</strong><br>
Current IBAN validator uses general IBAN checksum only, while some countries use internal check digit algorithms to validate domestic BBAN. What this means is that some invalid IBANs pass the Symfony validation.</p>
<p dir="auto"><strong>How to reproduce</strong><br>
following should return &gt; 0, instead it returns 0</p>
<div class="highlight highlight-text-html-php notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="use Symfony\Component\Validator\Constraints\Iban;
use Symfony\Component\Validator\Constraints\IbanValidator;
use Symfony\Component\Validator\Validation;

echo count(Validation::createValidator()-&gt;validate('SK1211115351562002977968', [new Iban]));
"><pre class="notranslate"><span class="pl-k">use</span> <span class="pl-v">Symfony</span>\<span class="pl-v">Component</span>\<span class="pl-v">Validator</span>\<span class="pl-v">Constraints</span>\<span class="pl-v">Iban</span>;
<span class="pl-k">use</span> <span class="pl-v">Symfony</span>\<span class="pl-v">Component</span>\<span class="pl-v">Validator</span>\<span class="pl-v">Constraints</span>\<span class="pl-v">IbanValidator</span>;
<span class="pl-k">use</span> <span class="pl-v">Symfony</span>\<span class="pl-v">Component</span>\<span class="pl-v">Validator</span>\<span class="pl-v">Validation</span>;

<span class="pl-k">echo</span> count(<span class="pl-v">Validation</span>::<span class="pl-en">createValidator</span>()-&gt;<span class="pl-en">validate</span>(<span class="pl-s">'SK1211115351562002977968'</span>, [<span class="pl-k">new</span> <span class="pl-v">Iban</span>]));</pre></div>
<p dir="auto"><strong>Possible Solution</strong><br>
Unfortunately I wasn't successful in finding these country specific algorithms, help needed.</p>
<p dir="auto"><strong>Additional context</strong><br>
<a href="https://www.iban.com/iban-validation-help.html" rel="nofollow">https://www.iban.com/iban-validation-help.html</a> provides some basic info about this<br>
<a href="https://www.ibancalculator.com/iban_validieren.html" rel="nofollow">https://www.ibancalculator.com/iban_validieren.html</a> First result in google for iban validation, it does these country specific validations too, but they sell API for this service.</p>