The use of the ESP8266 in the world of IoT

User avatar
By reidkersey
#62996 I am running into an interesting (and very annoying) problem. I am attempting to post to an Amazon API Gateway (REST). Like most REST services it requires the use of HTTPS. The code works with some websites but not others. I am using the latest AT command set on an ESP8266 WROOM-02.

I am sending the chip the following commands. The commands are successful with some sites, but apparently not with the one I am trying to test (app.sniffergps.com). They do however work when the web address is http://www.posttestserver.com and google.com. sparkfun.com and cnn.com also fail.

What am I doing wrong, and how can I make this work with my website?

This is what I am sending and receiving:
Code: Select allATE0\r\n
--> ATE0\r\r\n\r\nOK\r\n
AT\r\n
--> \r\nOK\r\n
AT+CWMODE=3\r\n
--> \r\nOK\r\n
AT+CWQAP\r\n
--> \r\nOK\r\n
AT+CWJAP="<ssid>","<password>"\r\n
--> WIFI CONNECTED\r\n
--> WIFI GOT IP\r\n
--> \r\nOK\r\n
AT+CIPSSLSIZE=4096\r\n
--> \r\nOK\r\n
AT+CIPSTART="SSL","app.sniffergps.com",443\r\n
--> CLOSED\r\n\r\nOK\r\n
AT+CIPSEND=170\r\n
--> link is not valid\r\n\r\nERROR\r\n


We have also tried
Code: Select allAT+CIPSTART="SSL","app.sniffergps.com",443,1000\r\n


------UPDATE----------
I found out through sniffing the packets when the command AT+CIPSTART was issued that I was receiving a Handshake Failed (40) error.

Apparently this chip does not support SNI, and that is causing the server to error.

Does anyone know if there is a way to make this chip support SNI?
User avatar
By bialabs
#83230 I fixed in the past using a dedicated IP on my hosting but suddently three days ago my sketch has stopped working. Now i get

Code: Select all>> AT+CIPSTART=3,"SSL","www.myhosting.it",443

ERROR
---------------------------------------------- > 1

Unable to connect to server


nothing is changed, the hosting still has a dedicated IP address and the sketch is working with google address . Anyone can help me?