TPE1122:使用BulkRequestTransmitterService的消息中的“ WS Security Header无效。”

时间:2019-01-11 21:47:48

标签: soapui ws-client irs

在通过A2A向IRS发送BulkRequestTransmitterService时,我们收到TPE1122错误消息。

我已经审查了几篇文章,但似乎都没有解决这个问题。看起来每个人都有一个独特的问题,或者也许我只需要我的消息头换成新的眼睛即可。

您能看看这个SOAP消息,看看我是否想念任何东西。

it('should not show navigation if not logged in', () => {
  spyOn(dataServiceMock,'getCurrentUser').and.callFake(() => {
    console.log('IN CALL FAKE')
    //  throwError(new Error('induced error'))
    return of({username: 'test'})
  });
  fixture.detectChanges();
  expect(component.currentUser.username).toEqual('test');
});

1 个答案:

答案 0 :(得分:3)

最后,他开始研究更多内容,这可能不仅仅是评论的价值!大声笑

为回答您先前的评论,我依次引用了TimestampACATransmitterManifestReqDtlACABusinessHeader。有传言说订购可能有用,而且刚好与美国国税局的订购相匹配。

并且看起来您只是根据已经存在的参考ID来丢失ACATransmitterManifestReqDtl的参考。

编辑:添加了更多探究性问题,您是否能够在过去几年中进行传播,或者这是第一个?您确定要在生成肥皂中的所有内容之后计算签名吗?我知道其他人的共同点是将肥皂中的所有东西都堆积起来,然后回去再将签名值放进去,以获得IRS想要的计算值。

额外编辑:还添加了最近使用过的肥皂信封,也许可以帮助您交叉引用

<soapenv:Envelope xmlns:oas1="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" 
    xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" 
    xmlns:urn="urn:us:gov:treasury:irs:ext:aca:air:ty18" 
    xmlns:urn1="urn:us:gov:treasury:irs:common" 
    xmlns:urn2="urn:us:gov:treasury:irs:msg:acabusinessheader" 
    xmlns:urn3="urn:us:gov:treasury:irs:msg:acasecurityheader" 
    xmlns:urn4="urn:us:gov:treasury:irs:msg:irsacabulkrequesttransmitter">
    <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
        <wsse:Security xmlns:wsse="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">
            <Signature Id="SIG-79188D350E3148E4AAADCC17640B4F96" 
                xmlns="http://www.w3.org/2000/09/xmldsig#">
                <SignedInfo>
                    <CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#WithComments" />
                    <SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256" />
                    <Reference URI="#TS-94B326365FA1402DA4C41C902754D2D7">
                        <Transforms>
                            <Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                                <InclusiveNamespaces PrefixList="wsse wsa oas1 soapenv urn urn1 urn2 urn3 urn4" 
                                    xmlns="http://www.w3.org/2001/10/xml-exc-c14n#" />
                            </Transform>
                        </Transforms>
                        <DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" />
                        <DigestValue>[Digest Value]</DigestValue>
                    </Reference>
                    <Reference URI="#id-2BD7DF65324343D5A4DE701DC5CE1359">
                        <Transforms>
                            <Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                                <InclusiveNamespaces PrefixList="wsa oas1 soapenv urn1 urn2 urn3 urn4" 
                                    xmlns="http://www.w3.org/2001/10/xml-exc-c14n#" />
                            </Transform>
                        </Transforms>
                        <DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" />
                        <DigestValue>[Digest Value]</DigestValue>
                    </Reference>
                    <Reference URI="#id-41CCE5EA3C17412AA664A0FDF01831A5">
                        <Transforms>
                            <Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#">
                                <InclusiveNamespaces PrefixList="wsa oas1 soapenv urn urn1 urn3 urn4" 
                                    xmlns="http://www.w3.org/2001/10/xml-exc-c14n#" />
                            </Transform>
                        </Transforms>
                        <DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" />
                        <DigestValue>[Digest Value]</DigestValue>
                    </Reference>
                </SignedInfo>
                <SignatureValue>[Signature Value]</SignatureValue>
                <KeyInfo Id="KI-7B3114DF0CD6420CBCB647BCFE12F3F8">
                    <wsse:SecurityTokenReference wsu:Id="STR-EC2D02C5C7C744599FE9D25C188EE1F2">
                        <wsse: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">[KeyDetails]</wsse:KeyIdentifier>
                    </wsse:SecurityTokenReference>
                </KeyInfo>
            </Signature>
            <wsu:Timestamp wsu:Id="TS-94B326365FA1402DA4C41C902754D2D7">
                <wsu:Created>2019-01-11T21:18:58.560Z</wsu:Created>
                <wsu:Expires>2019-01-11T21:28:58.560Z</wsu:Expires>
            </wsu:Timestamp>
        </wsse:Security>
        <urn:ACATransmitterManifestReqDtl wsu:Id="id-2BD7DF65324343D5A4DE701DC5CE1359" 
            xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
            <urn:PaymentYr>2018</urn:PaymentYr>
            <urn:PriorYearDataInd>0</urn:PriorYearDataInd>
            <urn1:EIN>[Value]</urn1:EIN>
            <urn:TransmissionTypeCd>O</urn:TransmissionTypeCd>
            <urn:TestFileCd>T</urn:TestFileCd>
            <urn:TransmitterNameGrp>
                <urn:BusinessNameLine1Txt>[Value]</urn:BusinessNameLine1Txt>
            </urn:TransmitterNameGrp>
            <urn:CompanyInformationGrp>
                <urn:CompanyNm>[Value]</urn:CompanyNm>
                <urn:MailingAddressGrp>
                    <urn:USAddressGrp>
                        <urn:AddressLine1Txt>[Value]</urn:AddressLine1Txt>
                        <urn1:CityNm>[Value]</urn1:CityNm>
                        <urn:USStateCd>[ST]</urn:USStateCd>
                        <urn1:USZIPCd>[Value]</urn1:USZIPCd>
                    </urn:USAddressGrp>
                </urn:MailingAddressGrp>
                <urn:ContactNameGrp>
                    <urn:PersonFirstNm>[Value]</urn:PersonFirstNm>
                    <urn:PersonLastNm>[Value]</urn:PersonLastNm>
                </urn:ContactNameGrp>
                <urn:ContactPhoneNum>[Value]</urn:ContactPhoneNum>
            </urn:CompanyInformationGrp>
            <urn:VendorInformationGrp>
                <urn:VendorCd>I</urn:VendorCd>
                <urn:ContactNameGrp>
                    <urn:PersonFirstNm>[Value]</urn:PersonFirstNm>
                    <urn:PersonLastNm>[Value]</urn:PersonLastNm>
                </urn:ContactNameGrp>
                <urn:ContactPhoneNum>[Value]</urn:ContactPhoneNum>
            </urn:VendorInformationGrp>
            <urn:TotalPayeeRecordCnt>1</urn:TotalPayeeRecordCnt>
            <urn:TotalPayerRecordCnt>1</urn:TotalPayerRecordCnt>
            <urn:SoftwareId>[Value]</urn:SoftwareId>
            <urn:FormTypeCd>1094/1095C</urn:FormTypeCd>
            <urn1:BinaryFormatCd>application/xml</urn1:BinaryFormatCd>
            <urn1:ChecksumAugmentationNum>E64127F513987230ADE5C862326791A450811F0E710754D54AB32B639E07F377</urn1:ChecksumAugmentationNum>
            <urn1:AttachmentByteSizeNum>5527</urn1:AttachmentByteSizeNum>
            <urn:DocumentSystemFileNm>1094C_Request_BB36D_20190111T211858528Z.xml</urn:DocumentSystemFileNm>
        </urn:ACATransmitterManifestReqDtl>
        <urn2:ACABusinessHeader wsu:Id="id-41CCE5EA3C17412AA664A0FDF01831A5" 
            xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
            <urn:UniqueTransmissionId>fbf74017-329b-4967-b724-f8a6dea08733:SYS12:BBBBB::T</urn:UniqueTransmissionId>
            <urn1:Timestamp>2019-01-11T21:18:58Z</urn1:Timestamp>
        </urn2:ACABusinessHeader>
        <urn3:ACASecurityHeader>
            <urn1:UserId>[UserID]</urn1:UserId>
        </urn3:ACASecurityHeader>
        <wsa:Action>BulkRequestTransmitter</wsa:Action>
    </soapenv:Header>
    <soapenv:Body>
        <urn4:ACABulkRequestTransmitter version="1.0">
            <urn1:BulkExchangeFile>
                <inc:Include href="cid:1094C_Request_BBBBB_20190111T211858528Z.xml" 
                    xmlns:inc="http://www.w3.org/2004/08/xop/include" />
            </urn1:BulkExchangeFile>
        </urn4:ACABulkRequestTransmitter>
    </soapenv:Body>
</soapenv:Envelope>