RC7620 and HTTPS

Hi @huydai2004,

What the login (“mms”) and password (“mms”) value in your AT command +KCNXCFG is used for?
Have you tried to set as below?

at+kcnxcfg=1,“GPRS”,“m3-world”

Thanks,

hi @jerdung

The carrier I am using is VINAPHONE.
“m3-world” is APN.
“mms” is a username
and “mms” is a password
You can refer to this link “Vinaphone Vietnam APN Configuration Settings - APN Settings Search Engine

I to try again as you ask (at+kcnxcfg=1,“GPRS”,“m3-world”,"","") . But I still received an error code (+KCNX_IND: 1,2,7,2,30).

You can see the detail in the attachment file. rc7620_faill_http.txt (1.5 KB)

Hi @huydai2004,

Can you excute command AT+CGPADDR then send me the result?

Thanks,

Thanks for your support! @jerdung

you can see in 107 line. rc7620_check_status.txt (4.4 KB)

Thanks and best regard!

Hi @huydai2004,

Can you check if your sim has data using for internet access? You can refer to below command and send me the result:

at+cusd=1,"*101#",15
at+cmgf=1
at+cnmi=1,1
at+cmgs="888"
> DATA<ctrl-Z/ESC>
at+cmgr=<index in URC +CMTI>

Beside that, please check your antenna, I see in your log, your network signal is not stable:


With:
+CEREG: 0 means: Not registered; MT is currently not searching for an operator to register to
+CEREG: 2 means: Not registered but MT is currently trying to attach or searching for an operator to
register to

Can you provide the result after sending command AT+CSQ? for me?

Thanks,

good afternoon @jerdung.

My SIM definitely has data for the internet. when I plug SIM into the smartphone I can normally access the internet.

Thanks.

Hi @huydai2004,

Are you mounting your module with Windows PC or Linux PC? If you are using Windows PC, you can disable Cellular created by your module as below:

Then you can try to create HTTP connection and send me the result.

Thanks

Hi @jerdung

My PC is Windows. below is the result when I turn off Cellular.
I have a new problem.
when I send the AT+KHTTPCFG=… command.
It responded +KHTTP_IND: 1,1
But after that: I continually send the at+khttpheader=1 command. I have received “CONNECT”. After a while, I receive an error code “+KHTTP_ERROR: 1,6”

You can check in the attachment file.http_header_fail.txt (1.9 KB)

Thanks!

Hi @jerdung

when I ignore the “at+khttpheader=1” . I can post data over the HTTP_post.

I do not know the meaning of “at+khttpheader”? And Why does the HTTP_POST works well when I ignore the “at+khttpheader=1” command? Please send me any document description of this feature.

Please view in the attactment file.http_post_ok.txt (2.8 KB)

And next step. I will test the HTTPS(get and post) please give me some examples.

Thanks!

Hi @huydai2004,

Following your log, I think error code “+KHTTP_ERROR: 1,6” displays because you missed a pattern used to notify the end of data (or file) during data or file transfer (–EOF–Pattern–).

However, +KHTTPHEADER and +KHTTPPOST commands are not mentioned in the latest AirPrime - RC76xx - AT Command Reference Guide here:
https://source.sierrawireless.com/resources/airprime/software/airprime---rc76xx---at-command-reference-guide/#sthash.HuDIYPiN.dpbs
So I strongly recommend you should not use +KHTTPHEADER and +KHTTPPOST commands until they are mentioned in document. These commands are not developed completely at this moment, so you can face the issues with current latest FW.

Thanks,

Hi @jerdung

Now, I am trying to connect to the “https://www.google.com/” over the 443 port, But I still receive an error code (+KHTTP_ERROR: 1,5).
Please check it for me! Detail https_fail.txt (908 Bytes)

Thanks!

Hi @huydai2004 ,

As the original issue has been answered. For another issue, you should create another new ticket for easy tracking. Then we will work on it.

Thanks,

Hi,
I have a problem with “AT+KHTTPCFG”.
The module response “+KHTTP_ERROR: 1,5” and retry “+KCNX_IND: 1,2,1,2,60”, “+KCNX_IND: 1,2,2,2,60”, … I cannot stop module retry, so I must restart the module.

The module call quite good and my SIM have many data.

Please help me resolve the issue.
Note: The command I do for RC7620 is similar with HL8548, that I have successful for HTTP

Thanks,
Toan

Hi,
I tested http with rc7620, seem it doesn’t stable.
Almost, it return “+KHTTP_ERROR: 1,5” and retry. Sometimes, it can connect but when I use httpget, it work only short link (about 98 characters).

It’s very confuse to use rc7620 to our project. Can you help please resolve the problem.

Thankyou very much,
Toan

Hi @toan_tran123,

Which FW is your module using? Is it the latest offical FW?
a, If no, please upload FW for your module. You can get this FW at link: https://source.sierrawireless.com/resources/airprime/software/rc76xx/rc76xx-firmware-release-6,-d-,2/#sthash.hIlquh1n.dpbs
b, If yes, can you refer to this comment and try again?
RC7620 and HTTPS - #19 by jerdung
Please share me the log with step-by-step whether you cannot make HTTP connection on your module.

Thanks,

Dear @jerdung ,

Thanks for your support, I turn off PC manager cellular and HTTP works stable now.
issue http-https.txt (2.3 KB)

These current issues I got is:

  1. HTTPGGET success for the only short link, HTTPGET return error for long link
  2. HTTPS return error when config.

Please review the log and help me fix the issues.
Thanks,
Toan

Hi @toan_tran123,

1, With the first issue:

Refer your log, we have seen:

AT+KHTTPGET=1,"/ota/api/device/1.0/update/info?deviceID=3Am6whDM1E27&requestID=7238048251208992&signKey=d4124bb902d245872081785dd026fc4de963239a91d1ccc228dfb4624c1813fa&OSVersion=3.0.40&SBLVersion=3.0.40&STMVersion=3.0.2&dataVersion=2.0.9&textVersion=3.0.2&HWVersion=3.7.0"


+CME ERROR: 3

Please check that your URL is correct and try again. If this issue still happens, can you send me your HTTP server information (via message) that I can check and find the reason?

2, With the second issue:

Did you import certificate for your module? If you want to make HTTPS connection, you need to import certificate to module.
You can import certificate to your module for server authentication following below steps:
AT+KCERTSTORE=0
<File_data> //You must select all data in your certificate file then copy, paste into here.
<+++> //Press + key 3 times

Please try them and provide me the result.

Thanks,

1 Like

Hi,

Please check the message, I have been sent you the server and some information.

Can you clarify for me:
What is the “certificate file” you are mentioning?
Must it use this file to go to HTTPS and where can I get this file?
Does each server have a different certificate file? Do I set for module onetime or every time go to HTTPS?

Thanks,
Toan

Hi @toan_tran123,

1, About HTTPS, maybe you got confused here.
On RC7620, HTTPS means HTTP 1.1 over TLS.
What is the TLS? You can follow some information about TLS:

Once the client and server have agreed to use TLS, they negotiate a stateful connection by using a handshaking procedure. During this handshake, the client and server agree on various parameters used to establish the connection's security:
a, The handshake begins when a client connects to a TLS-enabled server requesting a secure connection and the client presents a list of supported cipher suites (ciphers and hash functions).
b, From this list, the server picks a cipher and hash function that it also supports and notifies the client of the decision.
c, The server usually then provides identification in the form of a digital certificate. The certificate contains the server name, the trusted certificate authority (CA) that vouches for the authenticity of the certificate, and the server's public encryption key.
d, The client confirms the validity of the certificate before proceeding.
e, To generate the session keys used for the secure connection, the client either:
- encrypts a random number (PreMasterSecret) with the server's public key and sends the result to the server (which only the server should be able to decrypt with its private key); both parties then use the random number to generate a unique session key for subsequent encryption and decryption of data during the session
- uses Diffie–Hellman key exchange to securely generate a random and unique session key for encryption and decryption that has the additional property of forward secrecy: if the server's private key is disclosed in future, it cannot be used to decrypt the current session, even if the session is intercepted and recorded by a third party.
This concludes the handshake and begins the secured connection, which is encrypted and decrypted with the session key until the connection closes. If any one of the above steps fails, then the TLS handshake fails and the connection is not created.
Beside that, there are 2 options for authenticating: server authentication and mutual authentication. You can research about them.

The server you provided me in message is using server authentication. So importing server certificate is a condition which should have to make HTTPS connection on your module. You can refer the log and certificate I have just sent you in message and try again.

2, With the problem when using command +HTTPGET for a long link, I also see the issue on my RC7620 module as same as your issue. So you should contact your distributor who sold this module to you for guidance in this regard.

Thanks,

1 Like

Hi @jerdung,
Thanks for your support, now https can be works.
I will contact to our distributor to fix the long link http/https

Thanks,
Toan