oData X-CSRF Token (Cloud Foundry)

2
Hi all, we are trying to implement an App, hosted on the SAP Cloud Foundry Environment (CF), which uses the oData Connector from the App Store. We have 3 Operations provided by SAP (2x GET and 1x PUT) – the 2 GET Operations can be called successfully from within our Mendix App – they return the Objects we expect, so this works fine. The Problem is the PUT Operation – here we get a response which shows a company internal Login Page which indicates that the X-CSRF Token we send is not valid. As far as I have understood, the oData Connector Module takes care of the CSRF Token as soon as you perform a “Get Entry” or “Get List” Call and stores this Token in the CSRFToken Entity of the oData Connector Module. This seems to work, we get a Token but the Problem is that the Token looks different than expected – e.g. if I perform the Operation from Postman, I get a Token in a Format like TGXqd5Jw-LUFeXj0Nkdcuw== But Token I can see in the oData Connector Module looks like  913BB8E3CCB71B97E5551A541720B456 To Perform the PUT Operation we use the UPDATE Activity from the oData Module – there we added the CSRF Token (Add Header) as Part of the Request Params.   The difference of course is, that with Postman I use the “Original” oData URL provided by SAP and within the Mendix App I use the URL which the “Get Destination” Activity provides (https://gwaas-XXXXXXXXX.hana.ondemand.com/).   Any Ideas? Thanks in advance, Michael  
asked
1 answers
1

Hi Michael,
I am having the same question now, I can get CSRFToken instead of x-csrf-token, they have different format, and the former one doesn't work for post http method, do you have any pregress here? thanks in advance!Hi Michael,
I am having the same question now, I can get CSRFToken instead of x-csrf-token, they have different format, and the former one doesn't work for post http method, do you have any pregress here? thanks in advance!

answered