Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parsing issue with MX Message Type pacs.002.001.08 #11

Closed
winsen21 opened this issue Dec 21, 2020 · 1 comment
Closed

Parsing issue with MX Message Type pacs.002.001.08 #11

winsen21 opened this issue Dec 21, 2020 · 1 comment
Assignees
Labels
help wanted Extra attention is needed

Comments

@winsen21
Copy link

Hi ,

We try to parse Message Type pacs.002.001.08 using AbstractMX method / MxSwiftMessage.parse.
Both showing exception unable to complete parsing.

Would appreciate you can advise how we can parse given xml data with the sample message given.
samplemsg.002.001.08.txt

@zubri
Copy link
Member

zubri commented Dec 22, 2020

Your sample message has namespace binding issues. Take a look at this test and the associated samples:

https://github.com/prowide/prowide-iso20022/blob/develop/iso20022-core/src/test/java/com/prowidesoftware/issues/Issue11.java

First of all, within the Supplementary Data Envelop, you are adding some elements with the main prefix "Doc"

<Doc:Envlp>
<Doc:InstrForCdtrAcct>
<Doc:RsdntSts>1</Doc:RsdntSts>
<Doc:PrdTp>C</Doc:PrdTp>
<Doc:Dtls>1</Doc:Dtls>
</Doc:InstrForCdtrAcct>
</Doc:Envlp>

Only the Envlp elements belongs to the pacs. The envelop internal elements should be bounded to a different namespace. Notice, that even if you fix the namespace our parser will ignore that part of the content because it is unstructured from the pacs model perspective. In the schema that part is defined as "any (lax = true)" so it could be anything.

Then you have a similar issue in the header. The Signature element should be bounded to the https://www.w3.org/2000/09/xmldsig# namespace and not to the business application header namespace

@zubri zubri self-assigned this Dec 22, 2020
@zubri zubri added the help wanted Extra attention is needed label Dec 22, 2020
@zubri zubri closed this as completed Dec 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants