xHarbour with SSL/TLS - Master Enrico.

User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: xHarbour with SSL/TLS - Master Enrico.

Post by Enrico Maria Giordano »

karinha wrote:Seriously? You have my password, send me a test email from your example, please.
Done.
karinha wrote:Does anyone else testify that this example from Mr. Enrico works? Where do I find these updated LIBS?
http://forums.fivetechsupport.com/viewt ... 20&t=36588
karinha wrote:When I post an example, I post complete and working. Thanks.
For the example to work you have a full [x]Harbour with the OpenSSL libs and dll. I can't attached them here. Moreover, the libs must be generated with the C compiler you are using. Please check the instructions in the [x]Harbour package or in the above link. I can't do more than this, sorry.

EMG
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

Ok, many thanks Enrico.

Download:

06/12/2020 11:14 57.809.314 Win32OpenSSL-1_1_1h.exe

Libs:

Code: Select all

C:\OPENSSL2\lib

23/09/2020  05:49             1.840 capi.lib
23/09/2020  05:49             1.866 dasync.lib
23/09/2020  05:49           986.112 libapps.lib
23/09/2020  05:49         1.015.854 libcrypto.lib
23/09/2020  05:49        34.719.028 libcrypto_static.lib
23/09/2020  05:49            14.033 libssl.def
23/09/2020  05:49           122.290 libssl.lib
23/09/2020  05:49         7.066.282 libssl_static.lib
23/09/2020  05:49           448.974 libtestutil.lib
23/09/2020  05:49             1.734 openssl.lib
23/09/2020  05:49             1.892 ossltest.lib
23/09/2020  05:49             1.880 padlock.lib
23/09/2020  05:49             1.722 uitest.lib
 
Libs Extras:

Code: Select all

C:\OPENSSL2\lib\VC

23/09/2020  05:49         1.015.854 libcrypto32MD.lib
23/09/2020  05:49         1.015.854 libcrypto32MDd.lib
23/09/2020  05:49         1.015.854 libcrypto32MT.lib
23/09/2020  05:49         1.015.854 libcrypto32MTd.lib
23/09/2020  05:49           122.290 libssl32MD.lib
23/09/2020  05:49           122.290 libssl32MDd.lib
23/09/2020  05:49           122.290 libssl32MT.lib
23/09/2020  05:49           122.290 libssl32MTd.lib
 
Enrico, I was confused. Which LIBs should I use for the project? Is there any more LIB? Thank you very much for the explanation!

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

Enrico, que version de xHarbour tengo que usar? Mira:

Code: Select all

Borland Resource Compiler  Version 5.40
Copyright (c) 1990, 1999 Inprise Corporation.  All rights reserved.
Turbo Incremental Link 6.90 Copyright (c) 1997-2017 Embarcadero Technologies, In
c.
Error: 'C:\XHBBCC74\LIB\LIBSSL.LIB' contains invalid OMF record, type 0x21 (poss
ibly COFF)
* Linking errors *
 
Gracias.

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: xHarbour with SSL/TLS - Master Enrico.

Post by Enrico Maria Giordano »

You are probably using the libs for MSC. You have to generate that libs using your C compiler. The syntax is:

Code: Select all

implib -a libssl.lib libssl-1_1.dll
implib -a libcrypto.lib libcrypto-1_1.dll
EMG
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

Ok. Thanks. Voy intentar... What a difficulty ... jajajajajajaja.

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

No funciona Enrico. Your example and LIBs.

Download:

https://mega.nz/file/hV9w3LBR#t20ppM4t0 ... 9cf9nAT158

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: xHarbour with SSL/TLS - Master Enrico.

Post by Enrico Maria Giordano »

It works. You just forgot to set the password:
LOCAL cPassword := "yourpassword"
And you didn't link the correct libs:

Code: Select all

tipssl.lib
libssl.lib
libcrypto.lib
And last, where are the dlls?

EMG
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

No funciona Master. Que me falta?

Download complete:

https://mega.nz/file/RI12lbpJ#QAxxb9m5u ... h0gjXmTDNA

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: xHarbour with SSL/TLS - Master Enrico.

Post by Enrico Maria Giordano »

Please, check your password (currently is "xxxxxxxxxxxxx"):

Code: Select all

// By Enrico.  EMAILOT.PRG - Para OutLook.com

#include "Fivewin.ch"

FUNCTION MAIN()

   LOCAL cFrom         := "karinhafwh@outlook.com"
   //LOCAL cServer       := "smtp.office365.com"  // Pago?
   LOCAL cServer       := "smtp-mail.outlook.com"
   // LOCAL cTo           := "e.m.giordano@emagsoftware.it"
   LOCAL cTo           := "kapiabfwh@gmail.com"
   LOCAL cSubject      := "Test message by Enrico"
   LOCAL cMessage      := "This is a test message. Enrico"
   LOCAL cUser         := "karinhafwh@outlook.com"
   LOCAL cPassword     := "xxxxxxxxxxxxx"
   LOCAL cPort         := "587"
   LOCAL lSSL          := .F.
   LOCAL lTLS          := .T.

   ? HB_SENDMAIL( cServer, VAL( cPort ), cFrom, { cTo }, , , cMessage, cSubject, , cUser, cPassword, , , , , , , , , , , , lTLS )

RETURN NIL
EMG
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

Master Enrico, my password is correct. I declare in the PRG, when compiling.
I can't put it in the source, so that the whole internet can find out.

Regards, saludos.
João Santos - São Paulo - Brasil
User avatar
Enrico Maria Giordano
Posts: 7355
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: xHarbour with SSL/TLS - Master Enrico.

Post by Enrico Maria Giordano »

There is something wrong in one of your libs:

This is your lib:

Code: Select all

06/12/2020  15:23           551.424 libcrypto.lib
This is my lib:

Code: Select all

25/07/2020  11:28           608.768 libcrypto.lib
If you want my working libs please send me an email.

EMG
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour with SSL/TLS - Master Enrico.

Post by karinha »

Enrico Maria Giordano wrote:There is something wrong in one of your libs:

This is your lib:

Code: Select all

06/12/2020  15:23           551.424 libcrypto.lib
This is my lib:

Code: Select all

25/07/2020  11:28           608.768 libcrypto.lib
If you want my working libs please send me an email.

EMG

Ok. Thanks. I'll send an email in a moment.
João Santos - São Paulo - Brasil
Post Reply