ArduinoGeneral

SIM7600CE how to send a cookie??

userHead Account cancelled 2022-02-10 18:20:20 365 Views0 Replies

When sending a HTTP(S) POST, I need to send a cookie for authentication. It is very common to send cookies, so there must be a way to do this with SIM7600CE.

HTTPPARA with "USERDATA" is the logical way to do it, but it never seems to work. Transcript:

AT+HTTPINIT
OK

AT+HTTPPARA="USERDATA","Cookie: JSESSIONID=2C7799B7B1FA67CE54A252447FBAF7B6"
OK

AT+HTTPDATA=351,10000OK
DOWNLOAD
...here comes my data to send...
OK

AT+HTTPACTION=1
OK

=> The server receives the posted data, but not the USERDATA! Authentication fails all along. The cookie has not been added to the HTTP header. How to do this?