Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

Cisco Employee

Passing Cookies from Previous Web HTTP Request to the Next

Hi,

I have two Web Http Requests. The first one performs a Login and the second one executes another method called ListRecoveryPlans.

First SOAP calls for Login looks like this:

<?xml version="1.0" encoding="UTF-8"?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap-url>https://srm-app-003:9007</soap-url>

<connection>

<name>srm_connection_test_01</name>

<terminate-on-exit>false</terminate-on-exit>

</connection>

<SOAP-ENV:Body>

<urn:SrmLogin xmlns:urn="urn:srm0">

<urn:_this xmlns:urn="urn" type="SrmApi">Srm</urn:_this>

<urn:username>cisco\xxx</urn:username>

<urn:password>xxx</urn:password>

</urn:SrmLogin>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

The second soap looks like this:

<?xml version="1.0" encoding="UTF-8"?>

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">

<soap-url>https://srm-app-003:9007</soap-url>

<connection>

<name>srm_connection_test_01</name>

<terminate-on-exit>false</terminate-on-exit>

</connection>

<connectionCookie>

<name>

<xsl:text disable-output-escaping="no">DE78D964-DDF4-40B6-BCB7-BEB44624826D</xsl:text>

</name>

</connectionCookie>

<SOAP-ENV:Body>

<urn:ListRecoveryPlans xmlns:urn="urn:srm0">

<urn:_this xmlns:urn="urn" type="SrmApi">

<xsl:text disable-output-escaping="no">Srm</xsl:text>

</urn:_this>

</urn:ListRecoveryPlans>

</SOAP-ENV:Body>

</SOAP-ENV:Envelope>

In addition, under the Cookies tab for the ListRecoveryPlans request, I passed the cookies from the previous request:

passCookie.PNG

However, I am getting a "session is not authenticated" error.

The remote server returned an error: (500) Internal Server Error.

<?xml version="1.0" encoding="UTF-8"?>

<soapenv:Envelope xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"

xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsd="http://www.w3.org/2001/XMLSchema"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

<soapenv:Body>

<soapenv:Fault><faultcode>ServerFaultCode</faultcode><faultstring>The session is not authenticated.</faultstring><detail><SecurityErrorFault xmlns="urn:srm0" xsi:type="SecurityError"></SecurityErrorFault></detail></soapenv:Fault>

</soapenv:Body>

</soapenv:Envelope>

Can you shed some light on how I can fix this issue? I am using CPO v. 2.2.0.1409.

Thank you.

Regards,

Mary Jane Cofino

Everyone's tags (4)
3 REPLIES
Cisco Employee

Passing Cookies from Previous Web HTTP Request to the Next

On the first request, did you check to accept cookies from it? Can you try viewing the cookie table and making sure you are getting it in the first call?

If you need more help, open a TAC case.

-shaun

--Shaun Roberts shaurobe@cisco.com CIAC Adoption Pilot Engineering Lead
Cisco Employee

Passing Cookies from Previous Web HTTP Request to the Next

Hi,

Thank you for the prompt reply.

For the first request, here is the response header I am getting

I checked the "Accept cookies from this request" checkbox button and am now getting a new error:

The remote server returned an error: (500) Internal Server Error.

http://schemas.xmlsoap.org/soap/encoding/"

xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:xsd="http://www.w3.org/2001/XMLSchema"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

ServerFaultCodeThe object has already been deleted or has not been completely created

Regards,

Mary Jane Cofino

Cisco Employee

Passing Cookies from Previous Web HTTP Request to the Next

A 500 error means an error on the application you are calling.

Have you tested this with like SOAP UI or some other manual soap engine?

-shaun

--Shaun Roberts shaurobe@cisco.com CIAC Adoption Pilot Engineering Lead
536
Views
5
Helpful
3
Replies
CreatePlease login to create content