Page 4 of 6

Re: Implement a full SSL/TLS library

Posted: Tue May 10, 2022 10:50 pm
by RichAlgeni
plouf wrote: Mon May 09, 2022 7:23 pm I suggest the "easy" way, already used by competive languanges

Is to use the curl library "layer" and/or just a curl library
I use libcurl to read multiple email accounts, of many different providers. I've found the latest versions of curl to be buggy, and their developers lackadaisical. I've had to resort to version 7.64.1 to get code that works. I'd avoid curl as a library for PureBasic.

Re: Implement a full SSL/TLS library

Posted: Wed May 11, 2022 7:09 am
by infratec
plouf wrote: Mon May 09, 2022 7:23 pm I suggest the "easy" way, already used by competive languanges

Is to use the curl library "layer" and/or just a curl library
This is impossible :wink:
libcurl handles only the client stuff, but not the server side.

@RichAlgeni
if libcurl is so bad, why is it used by any linux distribution that I know?
Btw. did you apply a fix to the problem and send to them via

https://github.com/curl/curl/pulls

Re: Implement a full SSL/TLS library

Posted: Thu May 12, 2022 4:21 pm
by plouf
infratec wrote: Wed May 11, 2022 7:09 am
plouf wrote: Mon May 09, 2022 7:23 pm I suggest the "easy" way, already used by competive languanges

Is to use the curl library "layer" and/or just a curl library
This is impossible :wink:
libcurl handles only the client stuff, but not the server side.

@RichAlgeni
if libcurl is so bad, why is it used by any linux distribution that I know?
Btw. did you apply a fix to the problem and send to them via

https://github.com/curl/curl/pulls
then just a libcurl library? curl has some build in stuff , ready out-of-the-box if you are making a client app (which is the majority anyway)

Re: Implement a full SSL/TLS library

Posted: Thu May 12, 2022 7:18 pm
by the.weavster
Fred wrote: Mon May 09, 2022 2:34 pmAbout creating your own HTTPS socket, I agree it can be useful and I will look into it.
:D 8)

Re: Implement a full SSL/TLS library

Posted: Thu May 12, 2022 8:09 pm
by RichAlgeni
infratec wrote: Wed May 11, 2022 7:09 am @RichAlgeni
if libcurl is so bad, why is it used by any linux distribution that I know?
Btw. did you apply a fix to the problem and send to them via

https://github.com/curl/curl/pulls
I didn't say it was necessarily bad, just that it was buggy. For that, I can't explain. Possibly because it is the Windows version? I provided detailed logs to the curl developers. I showed the differences between the versions. I asked them what more information I could provide. There response was sanctimonious, to say the least. I responded by asking them to reference the logs I provided. Their response was to chastise me for including user data. The user data I included was a test email account. While I was born at night, it wasn't last night. When I did not hear from them further, I followed up, again asking what more information I could provide. When again, I did not hear from them, I left, entirely appropriate in my opinion, a sarcastic response. Their response was to block me.

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 7:12 am
by infratec
plouf wrote: Thu May 12, 2022 4:21 pm then just a libcurl library? curl has some build in stuff , ready out-of-the-box if you are making a client app (which is the majority anyway)
The libcurl library is already included and used :wink:

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 10:59 am
by plouf
infratec wrote: Fri May 13, 2022 7:12 am
plouf wrote: Thu May 12, 2022 4:21 pm then just a libcurl library? curl has some build in stuff , ready out-of-the-box if you are making a client app (which is the majority anyway)
The libcurl library is already included and used :wink:
By already included you mean the "on linux curl is used blah blah blah"

I meanused as a high level layer. I.e. retrievehttpfile("rtsp:/blahblah") can used ? Since curl can

If an 3rd party libcurl exist please link..

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 11:15 am
by infratec
It is used by the inbuild HTTPRequest() stuff.

And you can also use it by your own via libcurl.pbi

https://www.purebasic.fr/english/viewto ... 71#p566971

With this libcurl.pbi you can also use the latest libcurl.dll file.
I use it also to access imaps.

FTPS example:
https://www.purebasic.fr/english/viewto ... 74#p562174

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 6:11 pm
by RichAlgeni
infratec wrote: Fri May 13, 2022 11:15 am It is used by the inbuild HTTPRequest() stuff.

And you can also use it by your own via libcurl.pbi

https://www.purebasic.fr/english/viewto ... 71#p566971

With this libcurl.pbi you can also use the latest libcurl.dll file.
I use it also to access imaps.

FTPS example:
https://www.purebasic.fr/english/viewto ... 74#p562174
I don't know what to tell you. I used the same exact code, except for the version of curl. I even downloaded the curl dll's from the curl github site. The newer version would not connect, or would fail during the curl commands, with godaddy, outlook and gmail email servers. The older version works, but sometimes does not delete or copy the email. I ended up writing a work around for that.

I'm sorry I haven't gotten back to you on your TLS code, I am in the process of remodeling a house.

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 6:16 pm
by RichAlgeni
infratec wrote: Fri May 13, 2022 11:15 am It is used by the inbuild HTTPRequest() stuff.

And you can also use it by your own via libcurl.pbi

https://www.purebasic.fr/english/viewto ... 71#p566971

With this libcurl.pbi you can also use the latest libcurl.dll file.
I use it also to access imaps.

FTPS example:
https://www.purebasic.fr/english/viewto ... 74#p562174
I apologize if I wasn't clear, this was for IMAP retrieving email messages only that I had a problem with Curl. But, it still gives me pause to use it elsewhere.

Re: Implement a full SSL/TLS library

Posted: Fri May 13, 2022 7:16 pm
by infratec
My answer was primary for plouf.

Re: Implement a full SSL/TLS library

Posted: Sat May 14, 2022 10:14 pm
by RichAlgeni
infratec wrote: Fri May 13, 2022 7:16 pm My answer was primary for plouf.
:D

Re: Implement a full SSL/TLS library

Posted: Mon May 23, 2022 1:06 pm
by Quin
+1

Re: Implement a full SSL/TLS library

Posted: Tue Sep 27, 2022 10:26 am
by the.weavster
@Fred
How close this is to the top of your TODO list?

Re: Implement a full SSL/TLS library

Posted: Mon Oct 03, 2022 4:55 am
by Opcode
+1 Built in TLS support with PB network functions would compliment my current project that relies on TLS v1.2.

Code: Select all

OpenNetworkConnection()
CreateNetworkServer()