GNOME Bugzilla – Bug 747377
Cannot enter Letters in IBAN for SEPA transaction
Last modified: 2018-06-29 23:40:10 UTC
A Netherland IBAN can contain letters but I cannot enter them, only the country code. http://www.iban-bic.com/sample_accounts.html I think in some older version that was working but not for 2.6.5 and 2.6.6
Where exactly are you trying to enter this?
Menu Aktion->Online Aktion->SEPA Einzelüberweisung sorry don't know the english translation There was a version where you could enter lowercase letters and there I was able to enter correct IBAN.
The bug report is correct. I modified the input filter of the respective IBAN text entry box in 8edb303143 (2014-09-01) to allow only two alphabetic characters in the beginning, then only numeric numbers for the rest. As the link in comment #0 says, this is correct for IBANs of the most countries such as Germany, but not for some, such as from the Netherlands. Hence, the gnc_ab_trans_dialog_ibanentry_filter_cb() has to be changed to allow alphas depending on the initial country code in the respective places. http://en.wikipedia.org/wiki/International_Bank_Account_Number#Structure Currently it implicitly allows only the German form, but this should be changed so that by default it allows arbitrary alphanumeric characters, and impose additional constraints only for known country codes in the beginning such as Germany's "DE".
Christian, is there an issue with sending an incorrectly-formatted IBAN other than that it will fail? Seems excessively complex to localize the filter unless there's a good reason to.
Before Christian modified the input filter my Deutsche Bank did not accept any IBAN with lower case letters. Maybe the simplest way is just to make all letters uppercase and remove all whitespaces. Is there any check for correct IBAN in gnucash?
(In reply to Burkhard Hoche from comment #5) > Before Christian modified the input filter my Deutsche Bank did not accept > any IBAN with lower case letters. It still doesn't. The filter function just uppercases the first two characters for you. > Maybe the simplest way is just to make all > letters uppercase and remove all whitespaces. Yes, that seems reasonable. > Is there any check for correct IBAN in gnucash? The only check is the one we're discussing here, and it's wrong. Only the bank can determine if the IBAN is correct; the best GnuCash could do is to ensure that it is in a valid format for the country code. Even doing that is quite complicated and as Christian points out must be tailored per-country. The wikipedia article says that there are 57 countries now using IBANs. That's likely to grow and it would be a maintenance headache to keep up. I think the uppercase-and-no-spaces rule you propose above is as far as we should go.
(In reply to John Ralls from comment #6) > (In reply to Burkhard Hoche from comment #5) > > Is there any check for correct IBAN in gnucash? > > The only check is the one we're discussing here, and it's wrong. Only the > bank can determine if the IBAN is correct; the best GnuCash could do is to > ensure that it is in a valid format for the country code. Even doing that is > quite complicated and as Christian points out must be tailored per-country. > The wikipedia article says that there are 57 countries now using IBANs. > That's likely to grow and it would be a maintenance headache to keep up. I > think the uppercase-and-no-spaces rule you propose above is as far as we > should go. Checking if a IBAN is correct by country code is a big headache but it is possible to validate a given IBAN: http://en.wikipedia.org/wiki/International_Bank_Account_Number#Validating_the_IBAN I think that would be a nice feature
Fixed in c46c0a9e7 (today) for the unstable series. The patch should apply cleanly in "maint", too, but I would like to hear some 1-2 weeks of feedback whether this still works. As for the discussion above: John, this is not your area of expertise. Please refrain from overly bold statements about the things that are happening and that should happen. Thanks. As for IBAN validation: The validation itself is already implemented in gnc_ab_trans_dialog_verify_values() and gives the user immediate feedback by the icon next to the number (it changes from "invalid" to "valid" once the focus moves to the next field). The bug here concerns the additional input filter that filtered out everything that to my knowledge shouldn't appear in an IBAN. Alas, contrary to my initial idea the specification didn't restrict numerics vs. alpha-numerics as clearly as I thought for the IBAN, except for position 1 and 2 (alpha) and 3 and 4 (numeric), but only for some countries it is clear. This is now implemented correctly.
Christian, why do you not just use the checks from iban.h in libktoblzcheck1-devel?
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=747377. Please update any external references or bookmarks.