nsmission收到TPE 1105是因为在将数据写入连接时,我正在用Java中的转换器“缩进”我的xml。这导致soap消息无法识别为MIME类型的消息。希望这能帮助别人

nsmission收到TPE 1105是因为在将数据写入连接时,我正在用Java中的转换器“缩进”我的xml。这导致soap消息无法识别为MIME类型的消息。希望这能帮助别人,java,xml,soap,irs,Java,Xml,Soap,Irs,编辑——所以我的第二个问题,遇到1122,是由org.w3.dom文档是Java中的一级文档而不是二级文档引起的。这与javadsig库结合在一起,并没有正确地对xml进行签名(我相信)。一旦我将代码升级为使用2级文档,一切正常。希望有人会觉得这很有用,因为这会节省我大量的时间。你说得对,先生。有趣的是,他们的文档显示了带有acaheader名称空间的UserId。谢谢你的接球!很高兴我能帮上忙,实际上我已经给他们发了电子邮件,告诉他们完全相同的问题,看起来还没有得到解决。嘿@Das我一直在查看

编辑——所以我的第二个问题,遇到1122,是由org.w3.dom文档是Java中的一级文档而不是二级文档引起的。这与javadsig库结合在一起,并没有正确地对xml进行签名(我相信)。一旦我将代码升级为使用2级文档,一切正常。希望有人会觉得这很有用,因为这会节省我大量的时间。

你说得对,先生。有趣的是,他们的文档显示了带有acaheader名称空间的UserId。谢谢你的接球!很高兴我能帮上忙,实际上我已经给他们发了电子邮件,告诉他们完全相同的问题,看起来还没有得到解决。嘿@Das我一直在查看他们的文档、我的文件,并且实际查看了您发布的问题,问题主题相同-您是否知道id格式对于BusinessHeader和ManifestReqDetail元素有多重要?我使用的结构与我见过的不同,只是不确定是否需要采用这种格式。我想不会,但这是空气系统,所以谁知道..你是指参考wsu:IDs吗?我认为格式不重要,它应该只匹配安全细节。我注意到的另一件事是
bulkRequestTransmiterService
在您的信封中,正在进行操作。我目前将其设置为
BulkRequestTransmitter
,这也是我在wsu:Id上的想法。至于操作,当我看到示例中的差异时,我实际上将其更新为
BulkRequestTransmitter
。谢谢
    POST [AATS_URL] HTTP/1.1
    Content-Encoding: gzip
    Accept-Encoding: gzip,deflate
    Content-Type: multipart/related; type="application/xop+xml"; start="<root_part>"; boundary="--=_part_85c4167d-966b-4dfd-b6f9-c7a5aa410517"; start-info="text/xml"
    SOAPAction: "BulkRequestTransmitter"
    MIME-Version: 1.0
    Accept: text/xml,multipart/related
    Expect: 100-continue
    Cache-Control: no-cache
    Pragma: no-cache
    User-Agent: Java/1.8.0_111
    Host: la.www4.irs.gov
    Connection: keep-alive
    Content-Length: 16299

    ----=_part_85c4167d-966b-4dfd-b6f9-c7a5aa410517
    Content-Type: application/xop+xml; charset=UTF-8; type="text/xml"
    Content-Transfer-Encoding: 8bit
    Content-Id: <root_part>

    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <soapenv:Envelope xmlns:air="urn:us:gov:treasury:irs:ext:aca:air:ty18" xmlns:com="urn:us:gov:treasury:irs:common" xmlns:hdr="urn:us:gov:treasury:irs:msg:acabusinessheader" xmlns:oas1="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:req="urn:us:gov:treasury:irs:msg:irsacabulkrequesttransmitter" xmlns:sec="urn:us:gov:treasury:irs:msg:acasecurityheader" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
        <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
            <wse:Security xmlns:wse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" Id="SH-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                <ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#" Id="SIG-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                    <ds:SignedInfo>
                        <ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#WithComments"/>
                        <ds:SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"/>
                        <ds:Reference URI="#TS-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                            <ds:Transforms>
                                <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#WithComments">
                                    <ds:InclusiveNamespaces xmlns:ds="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="wse wsa osa1 soapenv air com hdr sec req"/>
                                </ds:Transform>
                            </ds:Transforms>
                        <ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/>
                        <ds:DigestValue>FqYS/pHdN05mKKccxqM4jmEwJNRR+ikRPB7HuyvbGQY=</ds:DigestValue>
                        </ds:Reference>
                        <ds:Reference URI="#MH-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                            <ds:Transforms>
                                <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                                    <ds:InclusiveNamespaces xmlns:ds="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="wse wsa osa1 soapenv com hdr sec req"/>
                                </ds:Transform>
                            </ds:Transforms>
                        <ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/>
                        <ds:DigestValue>qlWuAbD2PwDmvK7/KzU56ZWsKhBH2PYW/v2eW/30/4E=</ds:DigestValue>
                        </ds:Reference>
                        <ds:Reference URI="#BH-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                            <ds:Transforms>
                                <ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                                    <ds:InclusiveNamespaces xmlns:ds="http://www.w3.org/2001/10/xml-exc-c14n#" PrefixList="wse wsa osa1 soapenv air com sec req"/>
                                </ds:Transform>
                            </ds:Transforms>
                            <ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/>
                            <ds:DigestValue>E2cw4uavSk8RGQeewG04q3tcBRwM6dnMQmSctdJl4k8=</ds:DigestValue>
                        </ds:Reference>
                    </ds:SignedInfo>
                    <ds:SignatureValue>[SIGNATURE_VALUE]</ds:SignatureValue>
                    <ds:KeyInfo Id="KI-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                        <wse:SecurityTokenReference wsu:Id="STR-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                            <wse:KeyIdentifier EncodingType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary" ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3">[CERT_VALUE]</wse:KeyIdentifier>
                        </wse:SecurityTokenReference>
                    </ds:KeyInfo>
                </ds:Signature>
                <wsu:Timestamp wsu:Id="TS-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                    <wsu:Created>2019-02-15T15:41:01Z</wsu:Created>
                    <wsu:Expires>2019-02-15T15:51:01Z</wsu:Expires>
                </wsu:Timestamp>
            </wse:Security>
            <air:ACATransmitterManifestReqDtl xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="MH-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
                <air:PaymentYr>2018</air:PaymentYr>
                <air:PriorYearDataInd>0</air:PriorYearDataInd>
                <com:EIN>[REDACTED]</com:EIN>
                <air:TransmissionTypeCd>O</air:TransmissionTypeCd>
                <air:TestFileCd>T</air:TestFileCd>
                <air:TransmitterForeignEntityInd>0</air:TransmitterForeignEntityInd>
                <air:TransmitterNameGrp>
                    <air:BusinessNameLine1Txt>[REDACTED]</air:BusinessNameLine1Txt>
                </air:TransmitterNameGrp>
                <air:CompanyInformationGrp>
                    <air:CompanyNm>[REDACTED]</air:CompanyNm>
                    <air:MailingAddressGrp>
                        <air:USAddressGrp>
                            <air:AddressLine1Txt>[REDACTED]</air:AddressLine1Txt>
                            <com:CityNm>[REDACTED]</com:CityNm>
                            <air:USStateCd>[REDACTED]</air:USStateCd>
                            <com:USZIPCd>[REDACTED]</com:USZIPCd>
                        </air:USAddressGrp>
                    </air:MailingAddressGrp>
                    <air:ContactNameGrp>
                        <air:PersonFirstNm>[REDACTED]</air:PersonFirstNm>
                        <air:PersonMiddleNm>[REDACTED]</air:PersonMiddleNm>
                        <air:PersonLastNm>[REDACTED]</air:PersonLastNm>
                    </air:ContactNameGrp>
                    <air:ContactPhoneNum>[REDACTED]</air:ContactPhoneNum>
                </air:CompanyInformationGrp>
                <air:VendorInformationGrp>
                    <air:VendorCd>I</air:VendorCd>
                    <air:ContactNameGrp>
                        <air:PersonFirstNm>[REDACTED]</air:PersonFirstNm>
                        <air:PersonMiddleNm>[REDACTED]</air:PersonMiddleNm>
                        <air:PersonLastNm>[REDACTED]</air:PersonLastNm>
                    </air:ContactNameGrp>
                    <air:ContactPhoneNum>[REDACTED]</air:ContactPhoneNum>
                </air:VendorInformationGrp>
                <air:TotalPayeeRecordCnt>2</air:TotalPayeeRecordCnt>
                <air:TotalPayerRecordCnt>1</air:TotalPayerRecordCnt>
                <air:SoftwareId>[REDACTED]</air:SoftwareId>
                <air:FormTypeCd>1094/1095B</air:FormTypeCd>
                <com:BinaryFormatCd>application/xml</com:BinaryFormatCd>
                <com:ChecksumAugmentationNum>25fbebd1143d8aa935a445db998eb374761113af8b17d67b3a95af9ad73e17bc</com:ChecksumAugmentationNum>
                <com:AttachmentByteSizeNum>7245</com:AttachmentByteSizeNum>
                <air:DocumentSystemFileNm>1094B_Request_[TCC]_20190215T154101026Z.xml</air:DocumentSystemFileNm>
            </air:ACATransmitterManifestReqDtl>
            <hdr:ACABusinessHeader xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="BH-3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7">
            <air:UniqueTransmissionId>3f88e9e4-c4ea-4473-ad04-0b567e2a4bf7:SYS12:[TCC]::T</air:UniqueTransmissionId>
            <com:Timestamp>2019-02-15T15:41:01Z</com:Timestamp>
            </hdr:ACABusinessHeader>
            <sec:ACASecurityHeader>
            <hdr:UserId>[REDACTED]</hdr:UserId>
            </sec:ACASecurityHeader>
            <wsa:Action>BulkRequestTransmitterService</wsa:Action>
        </soapenv:Header>
        <soapenv:Body>
            <req:ACABulkRequestTransmitter version="1.0">
                <com:BulkExchangeFile>
                    <xop:Include xmlns:xop="http://www.w3.org/2004/08/xop/include" href="cid:1094B_Request_[TCC]_20190215T154101026Z.xml"/>
                </com:BulkExchangeFile>
            </req:ACABulkRequestTransmitter>
        </soapenv:Body>
    </soapenv:Envelope>

    ----=_part_85c4167d-966b-4dfd-b6f9-c7a5aa410517
    Content-Type: application/xml
    Content-Transfer-Encoding: 7bit
    Content-Id: <1094B_Request_[TCC]_20190215T154101026Z.xml>
    Content-Disposition: attachment; filename="1094B_Request_[TCC]_20190215T154101026Z.xml"

    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <msg:Form109495BTransmittalUpstream xmlns:air="urn:us:gov:treasury:irs:ext:aca:air:ty18" xmlns:com="urn:us:gov:treasury:irs:common" xmlns:msg="urn:us:gov:treasury:irs:msg:form1094-1095Btransmitterupstreammessage" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:us:gov:treasury:irs:msg:form1094-1095Btransmitterupstreammessage ../MSG/IRS-Form1094-1095BTransmitterUpstreamMessage.xsd">
    [REMOVED TO SAVE SPACE]
    </msg:Form109495BTransmittalUpstream>

    ----=_part_85c4167d-966b-4dfd-b6f9-c7a5aa410517-- 
<sec:ACASecurityHeader>
   <com:UserId>[REDACTED]</com:UserId>
</sec:ACASecurityHeader>