• AVR Freaks

Hot!How to configure secure connection on HTTP_NET ?

Author
arpatel
Starting Member
  • Total Posts : 63
  • Reward points : 0
  • Joined: 2019/01/09 23:24:14
  • Location: 0
  • Status: offline
2019/07/12 00:06:43 (permalink)
0

How to configure secure connection on HTTP_NET ?

I have created a project with HTTP_NET demo which is working fine over port 80.
Now, I want to turn on secure connection over 443 TLS. Can anyone tell me how to do/configure?
I am new to security, so knows little about encryption and cyphers.
 
I have enabled WolfSSL and ticked options that were in provided demo. Additionally, ticked support encryption in NET_PRES layer.
I have ticked on fast math option on .
I can ping to the board but I can not access web pages. Is there anything that I am missing?
DO I need to replace TCPIP_HTTP_NET call with somethis else?
Please guide me.
Thanks
 
XC32 2.15
MCU:PIC32MZ2048EFM064

Attached Image(s)

#1
rainad
Moderator
  • Total Posts : 1202
  • Reward points : 0
  • Joined: 2009/05/01 13:39:25
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/12 08:23:56 (permalink)
0
I suggest you start with a HTTP_NET demo that's part of the Harmony distribution.
Once you get that one working, you can check the differences in the wolfSSL/crypto/NET_PRES settings.
#2
BillP
Super Member
  • Total Posts : 320
  • Reward points : 0
  • Joined: 2014/09/28 07:53:35
  • Location: CA
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/12 08:24:56 (permalink)
0

@arpatel,
You are taking on an almost impossible project.  There are so many interdependent check boxes affecting the https server and all of them must be set correctly for the server to work.  I can see from the image you posted that you chose a number of options that are not in the working demo.  Without Harmony documentation, you are limited to trial-and-error testing.

I did this same thing a few years ago but I approached it differently.  I used the demo project to get the port 443 (https) working.  Then I unchecked options to get the http (port 80) server working.  Then I could do either one by changing the port number.  My approach and results are documented.  Do a Google search on "Learn Harmony".

BTW - the https option does not work in Hv3 (yet), so stick with Hv2_06.
BillP


#3
arpatel
Starting Member
  • Total Posts : 63
  • Reward points : 0
  • Joined: 2019/01/09 23:24:14
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/14 18:09:17 (permalink)
0
thanks for swift reply.
Yesterday I applied your idea to run demo first with default option and found its working as below image.
I can now access the web page on port 443. However, My browser says "connection not secure". Is this related to harmony or web browser setting?
 
After investigating I found that wolfssl certificate expired on 9 May 2019. Can you please tell me how to get latest certificate or how to change the date ? I am using it only on LAN.
Please advice me .
Thank you
post edited by arpatel - 2019/07/14 19:06:54

Attached Image(s)

#4
NKurzman
A Guy on the Net
  • Total Posts : 17596
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/15 05:58:18 (permalink)
0
You can't change the date on a certificate.
At some point you would need to purchase your own anyway. That can be done on the Internet.
Google “how do I buy a security certificate”
 
<edit>
post edited by NKurzman - 2019/07/15 17:42:08
#5
arpatel
Starting Member
  • Total Posts : 63
  • Reward points : 0
  • Joined: 2019/01/09 23:24:14
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/15 17:23:20 (permalink)
0
Can you please send me any guide or document on how to change date ?
I have tried but isn't succeed.
#6
NKurzman
A Guy on the Net
  • Total Posts : 17596
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/15 17:44:26 (permalink)
0
Sorry you Can Not change the date on an expired certificate.  You will need to get a new one.
#7
arpatel
Starting Member
  • Total Posts : 63
  • Reward points : 0
  • Joined: 2019/01/09 23:24:14
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/15 17:47:57 (permalink)
0
Thank you for your swift reply.
I am planning to run server only on LAN so it would be better to create new self signed certificate.
Can you please tell me how to replace certificate in MPLAB harmony?
I have noticed the certificate array in certs_test.h file.
Is that the only location I should change or is there other things as well?
Thank you
#8
NKurzman
A Guy on the Net
  • Total Posts : 17596
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: offline
Re: How to configure secure connection on HTTP_NET ? 2019/07/15 18:53:27 (permalink)
0
I have not used the security in harmony.  You can see if there is any details in the Harmony Help File.
#9
Jump to:
© 2019 APG vNext Commercial Version 4.5