Page 1 of 1

ReceiveHTTPMemory fails a lot of time

Posted: Tue Apr 14, 2020 11:09 am
by Mesa
ReceiveHTTPMemory fails a lot of time but not all the time.
Is that a bug ?
It worked before pb 5.72

I use pb5.72 lts x86 on xp 32b.

Code: Select all

InitNetwork()
; url$="http://www.purebasic.com/index.php"; fails
; url$="https://www.google.com";ok
; url$="http://www.google.com";ok
url$="https://upload.wikimedia.org/wikipedia/commons/0/02/SVG_logo.svg"; fails

  *Buffer = ReceiveHTTPMemory(url$)
  If *Buffer
    Taille = MemorySize(*Buffer)
    Debug  PeekS(*Buffer, Taille, #PB_UTF8|#PB_ByteLength)
    FreeMemory(*Buffer)
  Else
    Debug "Failed"
  EndIf
M.

Re: ReceiveHTTPMemory fails a lot of time

Posted: Tue Apr 14, 2020 11:57 am
by Naheulf
Tested 2 times for each url : 8 success, 0 fail

I use PureBasic LTS 5.72 x64 on windows 8.1 64 bits

Re: ReceiveHTTPMemory fails a lot of time

Posted: Tue Apr 14, 2020 12:27 pm
by mk-soft
Does not run on XP (x86) with any version of PB.

Probably has to do with the SSL security level, which is no longer supported by XP.
Must find an update for XP.

Re: ReceiveHTTPMemory fails a lot of time

Posted: Tue Apr 14, 2020 12:46 pm
by kenmo
Check if Internet Explorer fails on the same HTTPS URLs.

See my post here
https://www.purebasic.fr/english/viewto ... 32#p517732

Internet Explorer on XP (and therefore PB, must use same API) could no longer handle newer HTTPS certs or something, so I resorted to "patching" my XP programs to call WGET instead. Firefox and Chrome handled the sites OK.

Re: ReceiveHTTPMemory fails a lot of time

Posted: Tue Apr 14, 2020 1:28 pm
by Mesa
Thanks
@kenmo: you're right, ie4 fails to.

M.

Re: ReceiveHTTPMemory fails a lot of time

Posted: Thu Apr 30, 2020 9:55 am
by Mesa