Commit d9ab5aaf authored by Vincent Ardisson's avatar Vincent Ardisson Committed by Romain Bignon

tools.capabilities.bank.iban: iban checksum should be digits

parent b5dbd25b
......@@ -38,7 +38,7 @@ def clean(iban):
def is_iban_valid(iban):
# Ensure upper alphanumeric input.
iban = clean(iban)
if not re.match(r'^[\dA-Z]+$', iban):
if not re.match(r'^[A-Z]{2}\d{2}[\dA-Z]+$', iban):
return False
# Validate country code against expected length.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment