xHarbour.org updated!

Re: xHarbour.org updated!

Postby Enrico Maria Giordano » Tue Sep 19, 2023 8:01 am

I need a reduced and self-contained sample that I can compile and execute here. In the meantime, you can try assigning these:

Code: Select all  Expand view  RUN
oCli:nDefaultPort = nPort
oCli:lSSL = .T.
User avatar
Enrico Maria Giordano
 
Posts: 8719
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 12:16 pm

Enrico Maria Giordano wrote:I need a reduced and self-contained sample that I can compile and execute here. In the meantime, you can try assigning these:

Code: Select all  Expand view  RUN
oCli:nDefaultPort = nPort
oCli:lSSL = .T.


Thanks Enrico.
The service integration manual does not say to define the port.

Code below:


#Include "Fivewin.ch"


Function Main()

LOCAL oDlg, oGet
LOCAL cCad := "Testing " // pad("Testing Gets",40)
LOCAL nNum := 0
LOCAL dDat := Date()


inicio := 0


Set Century on
Set Date To British
Set Epoch to 1960
Set Multiple On
Set Deleted On


DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION

@ 1, 2 SAY "Text..:" OF oDlg
@ 1, 6 GET oGet1 VAR Inicio OF oDlg SIZE 100, 10 COLOR "W/G" PICTURE "99999999"

@ 3, 7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION Averba()
@ 3, 16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL


ACTIVATE DIALOG oDlg CENTERED

Return nil



Static Function Averba()
LOCAL oUrl, oCli
LOCAL hQUery := Hash()

TRY
oUrl = TUrl():New( 'https://apis.averbeporto.com.br/php/conn.php' )
CATCH
CurSorArrow()
MsgInfo('Conection Error','Erro')
RETURN(.F.)
END

IF !EMPTY( oUrl )
oCli = TIPClientHttp():New( oUrl )
IF !EMPTY( oCli )
oCli:nConnTimeout = -1
oCli:lSSL = .T.
IF oCli:Open()
hQuery["mod"] := "login"
hQuery["comp"] := "5"
hQuery["user"] := "xxxxxxxxxxxx"
hQuery["pass"] := "xxxxxxxxxxxx"
oCli:cUserAgent:='Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)'
IF !oCli:PostMultiPart(hQuery)
CurSorArrow()
MsgInfo(oCli:lastErrorMessage,'Error')
ELSE
cNFSeResp := oCli:ReadAll()
RespC := oCli:GetCookies() // Get cookie
ENDIF
oCli:Close()
ENDIF
ENDIF
ENDIF

msginfo(cNFSeResp)
msginfo(RespC)

Return Nil
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby Enrico Maria Giordano » Tue Sep 19, 2023 1:35 pm

Sorry, I can't execute your sample. Anyway, I forgot to mention that you have to replace tip.lib with:

Code: Select all  Expand view  RUN
tipssl.lib
libssl.lib
libcrypto.lib


Try and let me know.
User avatar
Enrico Maria Giordano
 
Posts: 8719
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 1:44 pm

Enrico Maria Giordano wrote:Sorry, I can't execute your sample. Anyway, I forgot to mention that you have to replace tip.lib with:

Code: Select all  Expand view  RUN
tipssl.lib
libssl.lib
libcrypto.lib


Try and let me know.


Enrico,

If I remove tip.lib and leave only tipssl.lib I get the following errors.

Turbo Incremental Link 6.98 Copyright (c) 1997-2023 Embarcadero Technologies, Inc.
Error: Unresolved external '_HB_FUN_TIP_TIMESTAMP' referenced from D:\SISTEMAS\LINKFLEX\OBJ\FUNCTE.OBJ
Error: Unresolved external '_HB_FUN_TURL' referenced from D:\SISTEMAS\LINKFLEX\OBJ\PROG232.OBJ
Error: Unresolved external '_HB_FUN_HB_BASE64' referenced from D:\LANG\FWH1811\XH1.3.0\LIB\TIPSSL.LIB|client1
Error: Unresolved external '_HB_FUN_TIPENCODERURL_ENCODE' referenced from D:\LANG\FWH1811\XH1.3.0\LIB\TIPSSL.LIB|httpcln1
Error: Unresolved external '_HB_FUN_TIPENCODERBASE64' referenced from D:\LANG\FWH1811\XH1.3.0\LIB\TIPSSL.LIB|httpcln1
Error: Unable to perform link

Thanks!
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby Enrico Maria Giordano » Tue Sep 19, 2023 2:02 pm

Have you put libssl.lib and libcrypto.lib too?
User avatar
Enrico Maria Giordano
 
Posts: 8719
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: xHarbour.org updated!

Postby karinha » Tue Sep 19, 2023 3:03 pm

https://docwiki.embarcadero.com/RADStudio/Alexandria/en/IMPLIB.EXE,_the_Import_Library_Tool_for_Win32

Arteaga, ejemplo de como generar las *.LIBs

Code: Select all  Expand view  RUN

// https://docwiki.embarcadero.com/RADStud ... _for_Win32

/*
IMPLIB <options> <LibName>[.lib] [<DefFiles>... | <DLLs>... ]^
       [@<ResponseFile> | <sourcename> ] [<sourcename> ...]
*/


C:\BCC76\BIN\IMPLIB ACBrMail32.lib ACBrMail32.dll
C:\BCC76\BIN\IMPLIB tipssl.lib     tipssl.dll
C:\BCC76\BIN\IMPLIB libssl.lib     libssl.dll
C:\BCC76\BIN\IMPLIB libcrypto.lib  libcrypto.dll
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7846
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 5:02 pm

Enrico Maria Giordano wrote:Have you put libssl.lib and libcrypto.lib too?


Yes Enrico! My hbmake file:


#BCC
VERSION=BCB.01
!ifndef CC_DIR
CC_DIR = $(MAKE_DIR)
!endif

!ifndef HB_DIR
HB_DIR = $(HARBOUR_DIR)
!endif

RECURSE= NO

SHELL =
COMPRESS = NO
EXTERNALLIB = YES
XFWH = YES
FILESTOADD = 5
WARNINGLEVEL = 0
USERDEFINE =
USERINCLUDE =
USERLIBS = D:\lang\fwh1811\bcc760\lib\psdk\msimg32.lib D:\lang\fwh1811\bcc760\lib\psdk\psapi.lib D:\lang\fwh1811\bcc760\lib\psk\shell32.lib
EDITOR = notepad
FWH = D:\lang\fwh1811\fwh1811
CGI = NO
GUI = YES
MT = NO
OBJ = obj
PROJECT = transp32.exe $(PR)
OBJFILES = $(OBJ)\TRANSP.obj $(OBJ)\CALC.obj $(OBJ)\FASTREPH.obj $(OBJ)\FUNCTE.obj $(OBJ)\FUNMDFE.obj //
$(OBJ)\GO_CODE.obj $(OBJ)\INT25.obj $(OBJ)\PROG01.obj $(OBJ)\PROG02.obj $(OBJ)\PROG03.obj //
$(OBJ)\PROG04.obj $(OBJ)\PROG05.obj $(OBJ)\PROG06.obj $(OBJ)\PROG07.obj $(OBJ)\PROG08.obj //
$(OBJ)\PROG09.obj $(OBJ)\PROG10.obj $(OBJ)\PROG100.obj $(OBJ)\PROG101.obj $(OBJ)\PROG102.obj //
$(OBJ)\PROG104.obj $(OBJ)\PROG105.obj $(OBJ)\PROG106.obj $(OBJ)\PROG107.obj $(OBJ)\PROG108.obj //
$(OBJ)\PROG109.obj $(OBJ)\PROG11.obj $(OBJ)\PROG110.obj $(OBJ)\PROG111.obj $(OBJ)\PROG112.obj //
$(OBJ)\PROG113.obj $(OBJ)\PROG114.obj $(OBJ)\PROG115.obj $(OBJ)\PROG116.obj $(OBJ)\PROG117.obj //
$(OBJ)\PROG118.obj $(OBJ)\PROG119.obj $(OBJ)\PROG12.obj $(OBJ)\PROG120.obj $(OBJ)\PROG13.obj //
$(OBJ)\PROG14.obj $(OBJ)\PROG140.obj $(OBJ)\PROG144.obj $(OBJ)\PROG146.obj $(OBJ)\PROG147.obj //
$(OBJ)\PROG148.obj $(OBJ)\PROG149.obj $(OBJ)\PROG15.obj $(OBJ)\PROG150.obj $(OBJ)\PROG151.obj //
$(OBJ)\PROG152.obj $(OBJ)\PROG153.obj $(OBJ)\PROG154.obj $(OBJ)\PROG155.obj $(OBJ)\PROG156.obj //
$(OBJ)\PROG157.obj $(OBJ)\PROG159.obj $(OBJ)\PROG16.obj $(OBJ)\PROG160.obj $(OBJ)\PROG161.obj //
$(OBJ)\PROG162.obj $(OBJ)\PROG164.obj $(OBJ)\PROG165.obj $(OBJ)\PROG168.obj $(OBJ)\PROG169.obj //
$(OBJ)\PROG17.obj $(OBJ)\PROG170.obj $(OBJ)\PROG171.obj $(OBJ)\PROG172.obj $(OBJ)\PROG173.obj //
$(OBJ)\PROG174.obj $(OBJ)\PROG175.obj $(OBJ)\PROG176.obj $(OBJ)\PROG177.obj $(OBJ)\PROG178.obj //
$(OBJ)\PROG179.obj $(OBJ)\PROG18.obj $(OBJ)\PROG180.obj $(OBJ)\PROG181.obj $(OBJ)\PROG182.obj //
$(OBJ)\PROG183.obj $(OBJ)\PROG184.obj $(OBJ)\PROG185.obj $(OBJ)\PROG186.obj $(OBJ)\PROG187.obj //
$(OBJ)\PROG188.obj $(OBJ)\PROG189.obj $(OBJ)\PROG19.obj $(OBJ)\PROG190.obj $(OBJ)\PROG191.obj //
$(OBJ)\PROG192.obj $(OBJ)\PROG193.obj $(OBJ)\PROG194.obj $(OBJ)\PROG195.obj $(OBJ)\PROG196.obj //
$(OBJ)\PROG197.obj $(OBJ)\PROG198.obj $(OBJ)\PROG199.obj $(OBJ)\PROG20.obj $(OBJ)\PROG21.obj //
$(OBJ)\PROG214.obj $(OBJ)\PROG215.obj $(OBJ)\PROG216.obj $(OBJ)\PROG217.obj $(OBJ)\PROG219.obj //
$(OBJ)\PROG22.obj $(OBJ)\PROG220.obj $(OBJ)\PROG221.obj $(OBJ)\PROG222.obj $(OBJ)\PROG223.obj //
$(OBJ)\PROG224.obj $(OBJ)\PROG226.obj $(OBJ)\PROG227.obj $(OBJ)\PROG228.obj $(OBJ)\PROG229.obj //
$(OBJ)\PROG23.obj $(OBJ)\PROG230.obj $(OBJ)\PROG232.obj $(OBJ)\PROG233.obj $(OBJ)\PROG234.obj //
$(OBJ)\PROG235.obj $(OBJ)\PROG25.obj $(OBJ)\PROG26.obj $(OBJ)\PROG27.obj $(OBJ)\PROG28.obj //
$(OBJ)\PROG29.obj $(OBJ)\PROG30.obj $(OBJ)\PROG31.obj $(OBJ)\PROG32.obj $(OBJ)\PROG33.obj //
$(OBJ)\PROG34.obj $(OBJ)\PROG35.obj $(OBJ)\PROG36.obj $(OBJ)\PROG37.obj $(OBJ)\PROG38.obj //
$(OBJ)\PROG39.obj $(OBJ)\PROG40.obj $(OBJ)\PROG41.obj $(OBJ)\PROG42.obj $(OBJ)\PROG43.obj //
$(OBJ)\PROG45.obj $(OBJ)\PROG47.obj $(OBJ)\PROG48.obj $(OBJ)\PROG49.obj $(OBJ)\PROG50.obj //
$(OBJ)\PROG51.obj $(OBJ)\PROG52.obj $(OBJ)\PROG53.obj $(OBJ)\PROG56.obj $(OBJ)\PROG57.obj //
$(OBJ)\PROG58.obj $(OBJ)\PROG59.obj $(OBJ)\PROG60.obj $(OBJ)\PROG61.obj $(OBJ)\PROG62.obj //
$(OBJ)\PROG63.obj $(OBJ)\PROG64.obj $(OBJ)\PROG65.obj $(OBJ)\PROG66.obj $(OBJ)\PROG67.obj //
$(OBJ)\PROG68.obj $(OBJ)\PROG69.obj $(OBJ)\PROG70.obj $(OBJ)\PROG71.obj $(OBJ)\PROG72.obj //
$(OBJ)\PROG73.obj $(OBJ)\PROG74.obj $(OBJ)\PROG75.obj $(OBJ)\PROG76.obj $(OBJ)\PROG77.obj //
$(OBJ)\PROG78.obj $(OBJ)\PROG79.obj $(OBJ)\PROG80.obj $(OBJ)\PROG81.obj $(OBJ)\PROG82.obj //
$(OBJ)\PROG83.obj $(OBJ)\PROG84.obj $(OBJ)\PROG85.obj $(OBJ)\PROG86.obj $(OBJ)\PROG87.obj //
$(OBJ)\PROG88.obj $(OBJ)\PROG89.obj $(OBJ)\PROG90.obj $(OBJ)\PROG91.obj $(OBJ)\PROG92.obj //
$(OBJ)\PROG93.obj $(OBJ)\PROG94.obj $(OBJ)\PROG95.obj $(OBJ)\PROG96.obj $(OBJ)\PROG97.obj //
$(OBJ)\PROG98.obj $(OBJ)\PROG99.obj $(OBJ)\PROG998.obj $(OBJ)\PROG999.obj $(OBJ)\SSAY.obj //
$(OBJ)\TDOSPRN.obj $(OBJ)\TGET.obj $(OBJ)\TSMTP.obj $(OBJ)\TWORDHB.obj $(OBJ)\TXML.obj //
$(OBJ)\TXTPREV.obj $(OB)
PRGFILES = TRANSP.PRG CALC.PRG FASTREPH.PRG FUNCTE.PRG FUNMDFE.PRG //
GO_CODE.PRG INT25.PRG PROG01.PRG PROG02.PRG PROG03.PRG //
PROG04.PRG PROG05.PRG PROG06.PRG PROG07.PRG PROG08.PRG //
PROG09.PRG PROG10.PRG PROG100.PRG PROG101.PRG PROG102.PRG //
PROG104.PRG PROG105.PRG PROG106.PRG PROG107.PRG PROG108.PRG //
PROG109.PRG PROG11.PRG PROG110.PRG PROG111.PRG PROG112.PRG //
PROG113.PRG PROG114.PRG PROG115.PRG PROG116.PRG PROG117.PRG //
PROG118.PRG PROG119.PRG PROG12.PRG PROG120.PRG PROG13.PRG //
PROG14.PRG PROG140.PRG PROG144.PRG PROG146.PRG PROG147.PRG //
PROG148.PRG PROG149.PRG PROG15.PRG PROG150.PRG PROG151.PRG //
PROG152.PRG PROG153.PRG PROG154.PRG PROG155.PRG PROG156.PRG //
PROG157.PRG PROG159.PRG PROG16.PRG PROG160.PRG PROG161.PRG //
PROG162.PRG PROG164.PRG PROG165.PRG PROG168.PRG PROG169.PRG //
PROG17.PRG PROG170.PRG PROG171.PRG PROG172.PRG PROG173.PRG //
PROG174.PRG PROG175.PRG PROG176.PRG PROG177.PRG PROG178.PRG //
PROG179.PRG PROG18.PRG PROG180.PRG PROG181.PRG PROG182.PRG //
PROG183.PRG PROG184.PRG PROG185.PRG PROG186.PRG PROG187.PRG //
PROG188.PRG PROG189.PRG PROG19.PRG PROG190.PRG PROG191.PRG //
PROG192.PRG PROG193.PRG PROG194.PRG PROG195.PRG PROG196.PRG //
PROG197.PRG PROG198.PRG PROG199.PRG PROG20.PRG PROG21.PRG //
PROG214.PRG PROG215.PRG PROG216.PRG PROG217.PRG PROG219.PRG //
PROG22.PRG PROG220.PRG PROG221.PRG PROG222.PRG PROG223.PRG //
PROG224.PRG PROG226.PRG PROG227.PRG PROG228.PRG PROG229.PRG //
PROG23.PRG PROG230.PRG PROG232.PRG PROG233.PRG PROG234.PRG //
PROG235.PRG PROG25.PRG PROG26.PRG PROG27.PRG PROG28.PRG //
PROG29.PRG PROG30.PRG PROG31.PRG PROG32.PRG PROG33.PRG //
PROG34.PRG PROG35.PRG PROG36.PRG PROG37.PRG PROG38.PRG //
PROG39.PRG PROG40.PRG PROG41.PRG PROG42.PRG PROG43.PRG //
PROG45.PRG PROG47.PRG PROG48.PRG PROG49.PRG PROG50.PRG //
PROG51.PRG PROG52.PRG PROG53.PRG PROG56.PRG PROG57.PRG //
PROG58.PRG PROG59.PRG PROG60.PRG PROG61.PRG PROG62.PRG //
PROG63.PRG PROG64.PRG PROG65.PRG PROG66.PRG PROG67.PRG //
PROG68.PRG PROG69.PRG PROG70.PRG PROG71.PRG PROG72.PRG //
PROG73.PRG PROG74.PRG PROG75.PRG PROG76.PRG PROG77.PRG //
PROG78.PRG PROG79.PRG PROG80.PRG PROG81.PRG PROG82.PRG //
PROG83.PRG PROG84.PRG PROG85.PRG PROG86.PRG PROG87.PRG //
PROG88.PRG PROG89.PRG PROG90.PRG PROG91.PRG PROG92.PRG //
PROG93.PRG PROG94.PRG PROG95.PRG PROG96.PRG PROG97.PRG //
PROG98.PRG PROG99.PRG PROG998.PRG PROG999.PRG SSAY.PRG //
TDOSPRN.PRG TGET.PRG TSMTP.PRG TWORDHB.PRG TXML.PRG //
TXTPREV.PRG $(PS)
OBJCFILES = $(OBC)
CFILES = $(CF)
RESFILES = telas.res telas1.res
RESDEPEN = telas.res telas1.res
TOPMODULE = TRANSP.PRG
LIBFILES = $(FWH)\lib\fivehx.lib $(FWH)\lib\fivehc.lib lang.lib vm.lib rtl.lib rdd.lib macro.lib pp.lib dbfntx.lib dbfcdx.lib dbffpt.lib common.lib gtgui.lib codepage.lib ct.lib tipssl.lib libssl.lib libcrypto.lib pcrepos.lib hsx.lib hbsix.lib zlib.lib libmisc.lib hbzip.lib
EXTLIBFILES =
DEFFILE =
HARBOURFLAGS = -w0
CFLAG1 = -OS $(SHELL) $(CFLAGS) -d -c -L$(HB_DIR)\lib;$(FWH)\lib
CFLAG2 = -I$(HB_DIR)\include;$(CC_DIR)\include
RFLAGS =
LFLAGS = -L$(CC_DIR)\lib\obj;$(CC_DIR)\lib;$(HB_DIR)\lib -Gn -M -m -s -Tpe -x -aa -L$(FWH)\lib
IFLAGS =
LINKER = ilink32

ALLOBJ = c0w32.obj $(OBJFILES) $(OBJCFILES)
ALLRES = $(RESDEPEN)
ALLLIB = $(USERLIBS) $(LIBFILES) import32.lib cw32.lib
.autodepend

#DEPENDS

#COMMANDS
.cpp.obj:
$(CC_DIR)\BIN\bcc32 $(CFLAG1) $(CFLAG2) -o$* $**

.c.obj:
$(CC_DIR)\BIN\bcc32 -I$(HB_DIR)\include $(CFLAG1) $(CFLAG2) -o$* $**

.prg.obj:
$(HB_DIR)\bin\harbour -D__EXPORT__ -n -go -I$(HB_DIR)\include $(HARBOURFLAGS) -I$(FWH)\include -o$* $**

.rc.res:
$(CC_DIR)\BIN\brcc32 $(RFLAGS) $<

#BUILD

$(PROJECT): $(CFILES) $(OBJFILES) $(RESDEPEN) $(DEFFILE)
$(CC_DIR)\BIN\$(LINKER) @&&!
$(LFLAGS) +
$(ALLOBJ), +
$(PROJECT),, +
$(ALLLIB), +
$(DEFFILE), +
$(ALLRES)
!
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 5:03 pm

karinha wrote:https://docwiki.embarcadero.com/RADStudio/Alexandria/en/IMPLIB.EXE,_the_Import_Library_Tool_for_Win32

Arteaga, ejemplo de como generar las *.LIBs

Code: Select all  Expand view  RUN

// https://docwiki.embarcadero.com/RADStud ... _for_Win32

/*
IMPLIB <options> <LibName>[.lib] [<DefFiles>... | <DLLs>... ]^
       [@<ResponseFile> | <sourcename> ] [<sourcename> ...]
*/


C:\BCC76\BIN\IMPLIB ACBrMail32.lib ACBrMail32.dll
C:\BCC76\BIN\IMPLIB tipssl.lib     tipssl.dll
C:\BCC76\BIN\IMPLIB libssl.lib     libssl.dll
C:\BCC76\BIN\IMPLIB libcrypto.lib  libcrypto.dll
 


Regards, saludos.


Karinha, thanks but the libs were generated this way.
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby karinha » Tue Sep 19, 2023 5:59 pm

Arteaga, mira si estas usando todas las LIBs:

Code: Select all  Expand view  RUN

C:\XHBBCC76\lib\vm.Lib               +
C:\XHBBCC76\lib\rdd.Lib              +
C:\XHBBCC76\lib\common.Lib           +
C:\XHBBCC76\lib\rtl.Lib              +
C:\XHBBCC76\lib\lang.Lib             +
C:\XHBBCC76\lib\macro.Lib            +
C:\XHBBCC76\lib\hbsix.Lib            +
C:\XHBBCC76\lib\dbfntx.Lib           +
C:\XHBBCC76\lib\PcRepos.Lib          +
C:\XHBBCC76\lib\dbffpt.Lib           +
C:\XHBBCC76\lib\dbfcdx.Lib           +
C:\XHBBCC76\lib\hbzip.Lib            +
C:\XHBBCC76\lib\hbmzip.Lib           +
C:\XHBBCC76\lib\zlib.Lib             +
C:\XHBBCC76\lib\ct.Lib               +
C:\XHBBCC76\lib\gtgui.Lib            +
C:\XHBBCC76\lib\tip.Lib              +
C:\XHBBCC76\lib\hbzebra.Lib          +
C:\XHBBCC76\lib\codepage.Lib         +
C:\XHBBCC76\lib\png.Lib              +
C:\XHBBCC76\lib\pp.Lib               +
c:\XHBBCC76\lib\libcrypto.lib        +
c:\XHBBCC76\lib\libssl.lib           +
c:\XHBBCC76\lib\tipssl.lib           +
C:\BCC76\lib\cw32.Lib                +
C:\BCC76\lib\uuid.lib                +
C:\BCC76\lib\ws2_32.lib              +
C:\BCC76\lib\import32.lib            +
C:\BCC76\lib\psdk\msimg32.Lib        +
C:\BCC76\lib\psdk\odbc32.Lib         +
C:\BCC76\lib\psdk\rasapi32.Lib       +
C:\BCC76\lib\psdk\nddeapi.Lib        +
C:\BCC76\lib\psdk\psapi.Lib          +
C:\BCC76\lib\psdk\gdiplus.lib        +
C:\BCC76\lib\psdk\iphlpapi.Lib       +
C:\BCC76\lib\psdk\shell32.lib        +
C:\BCC76\lib\psdk\wininet.Lib        +
C:\BCC76\lib\import32.Lib
 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7846
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 6:39 pm

karinha wrote:Arteaga, mira si estas usando todas las LIBs:

Code: Select all  Expand view  RUN

C:\XHBBCC76\lib\vm.Lib               +
C:\XHBBCC76\lib\rdd.Lib              +
C:\XHBBCC76\lib\common.Lib           +
C:\XHBBCC76\lib\rtl.Lib              +
C:\XHBBCC76\lib\lang.Lib             +
C:\XHBBCC76\lib\macro.Lib            +
C:\XHBBCC76\lib\hbsix.Lib            +
C:\XHBBCC76\lib\dbfntx.Lib           +
C:\XHBBCC76\lib\PcRepos.Lib          +
C:\XHBBCC76\lib\dbffpt.Lib           +
C:\XHBBCC76\lib\dbfcdx.Lib           +
C:\XHBBCC76\lib\hbzip.Lib            +
C:\XHBBCC76\lib\hbmzip.Lib           +
C:\XHBBCC76\lib\zlib.Lib             +
C:\XHBBCC76\lib\ct.Lib               +
C:\XHBBCC76\lib\gtgui.Lib            +
C:\XHBBCC76\lib\tip.Lib              +
C:\XHBBCC76\lib\hbzebra.Lib          +
C:\XHBBCC76\lib\codepage.Lib         +
C:\XHBBCC76\lib\png.Lib              +
C:\XHBBCC76\lib\pp.Lib               +
c:\XHBBCC76\lib\libcrypto.lib        +
c:\XHBBCC76\lib\libssl.lib           +
c:\XHBBCC76\lib\tipssl.lib           +
C:\BCC76\lib\cw32.Lib                +
C:\BCC76\lib\uuid.lib                +
C:\BCC76\lib\ws2_32.lib              +
C:\BCC76\lib\import32.lib            +
C:\BCC76\lib\psdk\msimg32.Lib        +
C:\BCC76\lib\psdk\odbc32.Lib         +
C:\BCC76\lib\psdk\rasapi32.Lib       +
C:\BCC76\lib\psdk\nddeapi.Lib        +
C:\BCC76\lib\psdk\psapi.Lib          +
C:\BCC76\lib\psdk\gdiplus.lib        +
C:\BCC76\lib\psdk\iphlpapi.Lib       +
C:\BCC76\lib\psdk\shell32.lib        +
C:\BCC76\lib\psdk\wininet.Lib        +
C:\BCC76\lib\import32.Lib
 


Regards, saludos.


Karinha,

I'm linking all the necessary libs, some that you use I don't use like zebra and others. What it seems is that tipssl.lib does not have all the functions of tip.lib. If I stop linking to tip.lib, it gives an error saying that some functions are missing. Do you have something working with https?
Thanks!
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby karinha » Tue Sep 19, 2023 7:08 pm

Arteaga, I don't have an example that uses SSL with HTTPS, do you have anything to send me?

Arteaga, no tengo un ejemplo que use SSL con HTTPS, ¿tienes algo para enviarme?

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7846
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour.org updated!

Postby wartiaga » Tue Sep 19, 2023 7:57 pm

karinha wrote:Arteaga, I don't have an example that uses SSL with HTTPS, do you have anything to send me?

Arteaga, no tengo un ejemplo que use SSL con HTTPS, ¿tienes algo para enviarme?

Regards, saludos.


Karinha, try this sample:


#Include "Fivewin.ch"

Function Main()

LOCAL oDlg, oGet
LOCAL cCad := "Testing " // pad("Testing Gets",40)
LOCAL nNum := 0
LOCAL dDat := Date()


inicio := 0


Set Century on
Set Date To British
Set Epoch to 1960
Set Multiple On
Set Deleted On


DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION

@ 1, 2 SAY "Text..:" OF oDlg
@ 1, 6 GET oGet1 VAR Inicio OF oDlg SIZE 100, 10 COLOR "W/G" PICTURE "99999999"

@ 3, 7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION Averba()
@ 3, 16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL


ACTIVATE DIALOG oDlg CENTERED

Return nil



Static Function Averba()
LOCAL oUrl, oCli
LOCAL hQUery := Hash()

TRY
oUrl = TUrl():New( 'https://apis.averbeporto.com.br/php/conn.php' )
CATCH
CurSorArrow()
MsgInfo('Conection Error','Erro')
RETURN(.F.)
END

IF !EMPTY( oUrl )
oCli = TIPClientHttp():New( oUrl )
IF !EMPTY( oCli )
oCli:nConnTimeout = -1
oCli:lSSL = .T.
IF oCli:Open()
hQuery["mod"] := "login"
hQuery["comp"] := "5"
hQuery["user"] := "xxxxxxxxxxxx"
hQuery["pass"] := "xxxxxxxxxxxx"
oCli:cUserAgent:='Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)'
IF !oCli:PostMultiPart(hQuery)
CurSorArrow()
MsgInfo(oCli:lastErrorMessage,'Error')
ELSE
cNFSeResp := oCli:ReadAll()
RespC := oCli:GetCookies() // Get cookie
ENDIF
oCli:Close()
ENDIF
ENDIF
ENDIF

msginfo(cNFSeResp)
msginfo(RespC)

Return Nil
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby karinha » Tue Sep 19, 2023 8:19 pm

Intente ahoha:

http://fivewin.com.br/index.php?/topic/26897-ip-p%C3%BAblico/


Code: Select all  Expand view  RUN

// C:\FWH..\SAMPLES\WARTIAG4.PRG

#include "Fivewin.ch"
#include "tip.ch"     // ARISTON.PRG

FUNCTION Main()

   LOCAL oDlg, oGet
   LOCAL cCad := "Testing " // pad("Testing Gets",40)
   LOCAL nNum := 0
   LOCAL dDat := Date()

   inicio := 0

   SET CENTURY ON
   SET DATE TO BRITISH
   SET EPOCH TO 1960
   SET Multiple ON
   SET DELETED ON

   DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION

   @ 1, 2 SAY "Text..:" OF oDlg

   @ 1, 6 GET oGet1 VAR Inicio OF oDlg SIZE 100, 10 COLOR "W/G" PICTURE "99999999"

   @ 3, 7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION Averba()
   @ 3, 16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL

   ACTIVATE DIALOG oDlg CENTERED

RETURN NIL

STATIC FUNCTION Averba()

   LOCAL oUrl, oCli, url
   LOCAL hQUery := Hash()

   url := "https://apis.averbeporto.com.br/php/conn.php"

   TRY

      // oUrl = TUrl():New( 'https://apis.averbeporto.com.br/php/conn.php' )

      oUrl := TUrl():New( url ) // From tip.lib

      oCli := TipClientHttp():New( oUrl, .f. ) // From tip.lib

      // oCli = TIPClientHttp():New( oUrl )

   CATCH

      MsgInfo('Conection Error','Erro')

      RETURN NIL

   END

   IF .NOT. Empty( oUrl )

      // oCli = TIPClientHttp():New( oUrl )

      IF .NOT. Empty( oCli )

         oCli:nConnTimeout = -1

         oCli:lSSL = .T.

         IF oCli:Open()

            hQuery[ "mod" ] := "login"

            hQuery[ "comp" ] := "5"

            hQuery[ "user" ] := "xxxxxxxxxxxx"

            hQuery[ "pass" ] := "xxxxxxxxxxxx"

            oCli:cUserAgent := 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)'

            IF !oCli:PostMultiPart( hQuery )

               CurSorArrow()

               MsgInfo( oCli:lastErrorMessage, 'Error' )

            ELSE

               cNFSeResp := oCli:ReadAll()

               RespC := oCli:GetCookies() // Get cookie

            ENDIF

            oCli:Close()

         ENDIF

      ENDIF

   ENDIF

   msginfo( cNFSeResp )

   msginfo( RespC )

RETURN NIL

//--------------------------------------------------------------------------//
DLL Function DeleteUrlCacheEntry(lpszUrlName AS STRING) AS LONG PASCAL FROM "DeleteUrlCacheEntryA" LIB "wininet.dll"
//--------------------------------------------------------------------------//

/* // teste
#include "FiveWin.ch"
#include "tip.ch"

        FUNCTION RetPublicIP()
       LOCAL cPubIP := "", cxHtml := "", url, oUrl, oHttp, oErr
       url := "http://checkip.dyndns.org"

           try
      oUrl:=TUrl():New( url ) // From tip.lib
      oHttp := TipClientHttp():New( oUrl , .f. ) // From tip.lib

   catch oErr
      ? "Erro: "+oErr:Description
   end try
       Try
      oHttp:Open()
      cxHtml := oHttp:ReadAll() // Baixa todo o conteúdo do site.
      cPubIP := allTrim( substr( substr( cxHtml, rat( "<body>", cxHtml ) + 26 ), 1, At( "<", substr( cxHtml, rat( "<body>", cxHtml ) + 26 ) ) - 1 ) )
   catch oErr
      ? "Erro: "+oErr:Description
   End
       oHttp:Close()
       DeleteUrlCacheEntry(url) // Lipar Cache
       ? cPubIP
    Return Nil
    //----------------------------------------------------------------------------------------------------------------------//
DLL Function DeleteUrlCacheEntry(lpszUrlName AS STRING) AS LONG PASCAL FROM "DeleteUrlCacheEntryA" LIB "wininet.dll"
//----------------------------------------------------------------------------------------------------------------------//
*/

 


Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7846
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: xHarbour.org updated!

Postby wartiaga » Wed Sep 20, 2023 12:59 am

karinha wrote:Intente ahoha:

http://fivewin.com.br/index.php?/topic/26897-ip-p%C3%BAblico/


Code: Select all  Expand view  RUN

// C:\FWH..\SAMPLES\WARTIAG4.PRG

#include "Fivewin.ch"
#include "tip.ch"     // ARISTON.PRG

FUNCTION Main()

   LOCAL oDlg, oGet
   LOCAL cCad := "Testing " // pad("Testing Gets",40)
   LOCAL nNum := 0
   LOCAL dDat := Date()

   inicio := 0

   SET CENTURY ON
   SET DATE TO BRITISH
   SET EPOCH TO 1960
   SET Multiple ON
   SET DELETED ON

   DEFINE DIALOG oDlg TITLE "TGet from " + FWDESCRIPTION

   @ 1, 2 SAY "Text..:" OF oDlg

   @ 1, 6 GET oGet1 VAR Inicio OF oDlg SIZE 100, 10 COLOR "W/G" PICTURE "99999999"

   @ 3, 7 BUTTON "&Ok" OF oDlg SIZE 30, 12 ACTION Averba()
   @ 3, 16 BUTTON "&Cancel" SIZE 30, 12 OF oDlg ACTION oDlg:End() CANCEL

   ACTIVATE DIALOG oDlg CENTERED

RETURN NIL

STATIC FUNCTION Averba()

   LOCAL oUrl, oCli, url
   LOCAL hQUery := Hash()

   url := "https://apis.averbeporto.com.br/php/conn.php"

   TRY

      // oUrl = TUrl():New( 'https://apis.averbeporto.com.br/php/conn.php' )

      oUrl := TUrl():New( url ) // From tip.lib

      oCli := TipClientHttp():New( oUrl, .f. ) // From tip.lib

      // oCli = TIPClientHttp():New( oUrl )

   CATCH

      MsgInfo('Conection Error','Erro')

      RETURN NIL

   END

   IF .NOT. Empty( oUrl )

      // oCli = TIPClientHttp():New( oUrl )

      IF .NOT. Empty( oCli )

         oCli:nConnTimeout = -1

         oCli:lSSL = .T.

         IF oCli:Open()

            hQuery[ "mod" ] := "login"

            hQuery[ "comp" ] := "5"

            hQuery[ "user" ] := "xxxxxxxxxxxx"

            hQuery[ "pass" ] := "xxxxxxxxxxxx"

            oCli:cUserAgent := 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)'

            IF !oCli:PostMultiPart( hQuery )

               CurSorArrow()

               MsgInfo( oCli:lastErrorMessage, 'Error' )

            ELSE

               cNFSeResp := oCli:ReadAll()

               RespC := oCli:GetCookies() // Get cookie

            ENDIF

            oCli:Close()

         ENDIF

      ENDIF

   ENDIF

   msginfo( cNFSeResp )

   msginfo( RespC )

RETURN NIL

//--------------------------------------------------------------------------//
DLL Function DeleteUrlCacheEntry(lpszUrlName AS STRING) AS LONG PASCAL FROM "DeleteUrlCacheEntryA" LIB "wininet.dll"
//--------------------------------------------------------------------------//

/* // teste
#include "FiveWin.ch"
#include "tip.ch"

        FUNCTION RetPublicIP()
       LOCAL cPubIP := "", cxHtml := "", url, oUrl, oHttp, oErr
       url := "http://checkip.dyndns.org"

           try
      oUrl:=TUrl():New( url ) // From tip.lib
      oHttp := TipClientHttp():New( oUrl , .f. ) // From tip.lib

   catch oErr
      ? "Erro: "+oErr:Description
   end try
       Try
      oHttp:Open()
      cxHtml := oHttp:ReadAll() // Baixa todo o conteúdo do site.
      cPubIP := allTrim( substr( substr( cxHtml, rat( "<body>", cxHtml ) + 26 ), 1, At( "<", substr( cxHtml, rat( "<body>", cxHtml ) + 26 ) ) - 1 ) )
   catch oErr
      ? "Erro: "+oErr:Description
   End
       oHttp:Close()
       DeleteUrlCacheEntry(url) // Lipar Cache
       ? cPubIP
    Return Nil
    //----------------------------------------------------------------------------------------------------------------------//
DLL Function DeleteUrlCacheEntry(lpszUrlName AS STRING) AS LONG PASCAL FROM "DeleteUrlCacheEntryA" LIB "wininet.dll"
//----------------------------------------------------------------------------------------------------------------------//
*/

 


Regards, saludos.


Thanks Karinha, but the line  IF oCli:Open() returns .F.
Works with you?
wartiaga
 
Posts: 212
Joined: Wed May 25, 2016 1:04 am

Re: xHarbour.org updated!

Postby karinha » Wed Sep 20, 2023 12:38 pm

Usando HTTP, funciona. Usando HTTPS, Error: Operation Not Supported. Que classe controla tipclienthttp()?

Mismo usando TIPSSL.LIB no funciona con ninguna URL que tenga HTTPS. Inclui SEVENZIP.LIB tampoco funciona.

Regards, saludos.
João Santos - São Paulo - Brasil - Phone: +55(11)95150-7341
User avatar
karinha
 
Posts: 7846
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

PreviousNext

Return to WhatsNew / Novedades

Who is online

Users browsing this forum: No registered users and 6 guests