(libofx bug 45) Account matching fails during OFX import

Bug #1443234 reported by Yury
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
HomeBank
Invalid
Undecided
Maxime DOYEN

Bug Description

Bank generated OFX files with headers that describe account specifically as Credit Card fail to match to the existing Homebank account.

Example:

1) This header matches by "myaccountnumber" automatically, without any problems

<BANKACCTFROM>
<BANKID>AUGCB
<ACCTID> myaccountnumber
<ACCTTYPE>CREDITLINE
</BANKACCTFROM>

2) This fails to match by "myotheraccountnumber" automatically (you can still import, but into the new account or after manually selecting the target)

<CCACCTFROM>
<ACCTID>myotheraccountnumber
<ACCTTYPE>CREDITLINE
</CCACCTFROM>

Suggestion - make Homebank check ACCTID within CCACCTFROM too, not just BANKACCTFROM.

Regards,
Yury

Tags: libofx
Revision history for this message
Maxime DOYEN (mdoyen) wrote :

HomeBank do uses libofx to load ofx/qfx file.
Normally is should manage this: source: http://libofx.sourceforge.net/html/structOfxAccountData.html

I did a test with a fake file inserting the few line you provided into a normal bank acocutn file, and did not get the accid in that case, but as i edited the file manually it might be not relevant.
Can you provide a very small file to confirm that libofx is in cause or not ?

Changed in homebank:
status: New → Incomplete
Revision history for this message
Yury (yury-kryv) wrote :

Maxime,

Please find the two genuine bank-generated files in the attachment (I've just changed account numbers in the interest of privacy)

If you would create two test accounts, one with the number 1111222233334444, and another 5555666677778888, and then try importing OFX files -- one would match automatically, the other would not.

The only principle difference is where ACCTID is placed -- within BANKACTFROM or CCACCTFROM.

Well, another difference is that beyond headers one file is described within
<CREDITCARDMSGSRSV1>....</CREDITCARDMSGSRSV1>

while another within
<BANKMSGSRSV1>....</BANKMSGSRSV1>

But since transactions are detected successfully it does not seem to be an issue.

P.S. -- the way account type is described in Homebank (no type, bank or credit card) makes no difference.

Maxime DOYEN (mdoyen)
Changed in homebank:
assignee: nobody → Maxime Doyen (mdoyen)
status: Incomplete → New
Revision history for this message
Maxime DOYEN (mdoyen) wrote :

This is a libofx bug, I opend one:
https://sourceforge.net/p/libofx/bugs/45/

summary: - Account matching fails during OFX import
+ (libofx bug 45) Account matching fails during OFX import
Changed in homebank:
status: New → Triaged
tags: added: libofx
Maxime DOYEN (mdoyen)
Changed in homebank:
importance: Undecided → Low
Revision history for this message
Maxime DOYEN (mdoyen) wrote :

reply from libofx tem

Hi there

I suspect that the problem lies with the OFX for the creditline account. Specifically the inclusion of the <ACCTTYPE> element in the <CCACCTFROM> element.

<CCACCTFROM>
<ACCTID>5555666677778888
<ACCTTYPE>CREDITLINE
</CCACCTFROM>

According to the documentation I have been able to find, while <ACCTTYPE> is a mandatory part of a <BANKACCTFROM> element, it is not even an optional part of the <CCACCTFROM> element.

The <BANKACCTFROM> element definition

    Tag Description
    <BANKACCTFROM> Bank-account-from aggregate
    <BANKID> Routing and transit number, A-9
    <BRANCHID> Bank identifier for international banks, A-22
    <ACCTID> Account number, A-22
    <ACCTTYPE> Type of account, see section 11.3.1.1

    <ACCTKEY> Checksum for international banks, A-22
    </BANKACCTFROM>

The <CCACCTFROM> definition

    Tag Description
    <CCACCTFROM> Credit-card-account-from aggregate
    <ACCTID> Account number, A-22
    <ACCTKEY> Checksum for international banks, A-22
    </CCACCTFROM>

LibOFX is probably rejecting the creditline account because the OFX is malformed.

For what it's worth, I have the same problem, viz a credit card account at a bank where the generated OFX is incorrect :-(

Geoff

Revision history for this message
Maxime DOYEN (mdoyen) wrote :

And I confirm this, after some checkings this morning.
the dtd do not allow ACCTTYPE into CCACCTFROM
if you do an ofxdump with your file (unregonizable.ofx), the error is cleary mentionned.

Complain to your financial institution ;D

Changed in homebank:
status: Triaged → Invalid
Maxime DOYEN (mdoyen)
Changed in homebank:
importance: Low → Undecided
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.