-
Content Count
2129 -
Joined
-
Last visited
-
Days Won
39
Everything posted by Angus Robertson
-
Power broadcasts give warnings when the system is about to close down, while designed for battery powered kit, they do work on desktops, my PCs have USB connection to the APC UPS so can close down early. Can not say specifically under what circumstances these messages appear, but belt and braces when saving data... PBT_APMBATTERYLOW: mess := 'Battery power is low' ; PBT_APMQUERYSUSPEND: mess := 'Request for permission to suspend' ; PBT_APMSUSPEND: mess := 'System is suspending operation' ; Angus
-
You should also listen for WM_POWERBROADCAST, but this has to be set-up to work, WM_ENDSESSION and WM_QUIT, lots of ways of closing down. Angus
-
OverbyteIcsWSocket.pas bug: PunyServerName filled with 8-bit data, even if it is a 16-bit UnicodeString
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Thanks, will be fixed today. Angus- 1 reply
-
- overbyteicswsocket.pas
- ics
-
(and 1 more)
Tagged with:
-
TSslHttpRest - 429 (Too Many Requests) - resend request
Angus Robertson replied to Anxich's topic in ICS - Internet Component Suite
You should be repeating RestRequest and not using DoRequestAsync so the request is properly initialised, missed that, other problems may occur attempting to make this a class. Angus -
OverbyteIcsLIBEAY.pas f_EVP_DigestSignInit() declaration mismatch
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Many thanks, also fixed EVP_DigestVarifyInit. That may get be closer to finding an ECDSA signing bug I've been looking for on and off for a couple of years, its shown up another error in code that was bypassed previously. Are you using the signing functions and finding problems, is that why you are finding all my API conversion errors? Angus- 1 reply
-
- overbyteicslibeay.pas
- bug
-
(and 1 more)
Tagged with:
-
TSslHttpRest - 429 (Too Many Requests) - resend request
Angus Robertson replied to Anxich's topic in ICS - Internet Component Suite
You should be using the onHttpRestProg event with DebugLeve=DebugBody so you can actually see any error messages and what is really happening. But please don't post long logs here, no more than a few pertinent lines. Angus -
TSslHttpRest - 429 (Too Many Requests) - resend request
Angus Robertson replied to Anxich's topic in ICS - Internet Component Suite
As I said, you are recursively starting a new HTTP request from the within an event called by that request, you need to start the next request outside the event, either from a timer as I suggested, or by sending a message to a function that starts the next request. Sleep stops messages being processed so defeats the concept of event driven programming, it should only generally only be used in threads that don't do anything else. Angus -
TSslHttpRest - 429 (Too Many Requests) - resend request
Angus Robertson replied to Anxich's topic in ICS - Internet Component Suite
Not looked closely at your code, only got as far as sleep in an event handler which is very bad design. You are also recursively starting a new request from the event, which calls the event again... To use async functionality properly, you should use a timer and triggers. ICS provides such functions in OverbyteIcsUtils, ie IcsGetTrgSecs, IcsGetTrgMins, IcsTestTrgTick which are used in OverbyteIcsSslMultiWebServ1.pas as an example. You set a trigger in the event to how every many seconds you want to wait, then test it in a timer triggering once a second or slower, then start the next request. Angus -
Filling and submitting a form programmatically with ICS
Angus Robertson replied to Carlos Tré's topic in ICS - Internet Component Suite
Also use TSslHttpRest instead of TSslHttpCli since this avoids you needing to use an SslContext in your application, look at the OverbyteIcsHttpRest sample. Angus -
From that extra information, I assume the first POST attempt succeeded, you then had a time out due to a bad connection and it died., This goes back to what I said yesterday, Windows keeps trying to open a TCP connection and you can not stop it early with a timeout, only by freeing the socket and starting again with a new socket. This is nothing to do with threads, just standard TCP connections. And why we recommend using a array of several hundred dynamically created THttpCli components all using async methods running in parallel sharing the same events for testing lots of remote sites. No threads necessary. Angus
-
Sorry, no idea. When used correctly, THttpCli just works. You ned to add some logging to see what you are not sending for what responses you are receiving. Angus
-
TIdThread is not an ICS component, probably Indy, which may mean you have mixed two libraries. May or may not be relevant to your problem. The only benefit of using threads with ICS to download multiple URLs is where the host is unavailable and Windows waits up to 30 seconds attempting to connect, blocking other actions. Apart from that, ICS will do several hundreds downloads in parallel. The most important issue if you really need to use threads is to make sure the ICS message pump is called in a solid loop if using async methods. Angus
-
And Microsoft says Windows will ship with MsQuic in the kernel, https://techcommunity.microsoft.com/t5/networking-blog/msquic-is-open-source/ba-p/1345441 Angus
-
Clouldfare supports QUIC/HTTP/3 now, so it's not just Google and has published speed comparisons. https://blog.cloudflare.com/http-3-vs-http-2/ We don;t expect any problem updating ICS to support OpenSSL 3.0, but won't do it until the API is stable with the first beta release in a month or two. OpenSSL plans QUIC/HTTP/3 for the release after 3.0, six to 12 months away. Hard to know how hard it will be to implement in ICS, but we'll certainly have a go. Supporting LibreSSL in ICS is possible, the API interface library is designed to support different OpenSSL versions dynamically, the main issue is LibreSSL has 'improved' some of the OpenSSL APIs, many macros are now function calls instead (good thing), So quite a lot of effort required to support LibreSSL with no obvious improvements to end user applications,
-
OpenSSL plans to add QUIC but not until stardardisation is closer, Google has been pushing this for 10 years or so and no standard yet. https://www.openssl.org/blog/blog/2020/02/17/QUIC-and-OpenSSL/ Angus
-
Links to OpenSSL 1.0.2u Windows binaries are broken
Angus Robertson replied to Silmor Senedlen's topic in ICS - Internet Component Suite
Sorry about that, must have forgotten to upload the 1.0.2u files to the wiki server, done now. However both 1.0.2t files come up as downloadable, not tried doing so. Angus -
Delphi 10.3 Rio on Windows Server 2008 R2
Angus Robertson replied to Tallys's topic in Delphi IDE and APIs
Windows Server 2008 R2 (aka Windows 7) support ceased earlier this year. Windows Servers usually install very basic display drivers which is probably your problem. Angus -
OverbyteIcsWSocket.SslWSocketCopyRight does not exist
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Those old files have gone from my local SVN and the zip list, easy to find errors when building project groups, but not things never in the group. But not in/out of the public SVN yet, lot of interconnected units still being tested. Angus- 3 replies
-
- bug
- non existing reference
-
(and 1 more)
Tagged with:
-
Memory leak in OverbyteIcsWSocket.pas
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Thanks, I did see an exception recently rebuilding stacks of root certificates to check chains, the quick solution was to avoid rebuilding stacks (which was also more efficient), but this is probably the root cause, will fix it. Angus- 1 reply
-
- ics
- memory leak
-
(and 1 more)
Tagged with:
-
OverbyteIcsLIBEAY.pas f_X509_check_ip_asc() declaration mismatch
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Thanks, will fix. Angus- 1 reply
-
- overbyteicslibeay.pas
- bug
-
(and 1 more)
Tagged with:
-
OverbyteIcsWSocket.SslWSocketCopyRight does not exist
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
That is an obsolete sample never updated for modern compilers and not in the project group, but the files are still there for some reason, but not for much longer. The current sample is OverbyteIcsSslWebServ,dpr. Angus- 3 replies
-
- bug
- non existing reference
-
(and 1 more)
Tagged with:
-
OverbyteIcsSSLEAY.pas f_SSL_set_msg_callback() declaration mismatch
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Technically it's wrong, but the actual callback does not attempt to return anything, it's really just for logging. Angus -
OverbyteIcsSSLEAY.pas f_SSL_clear() declaration mismatch
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Thanks, will fix but that function is never used by ICS. Angus -
OverbyteIcsSSLEAY.pas f_SSL_bytes_to_cipher_list() declaration mismatch
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
Thanks, that was added recently to SVN and is not yet used due to the warning 'not working yet ' will fix it. Angus -
Floating Point Overflow when retrieving a file using the ICS FTP Client
Angus Robertson replied to M-Brig's topic in VCL
Which specific FTP command causes the floating point error? Are you using a version of ICS from the last year? There have been issues in the distant past calculating the speed of downloads when they take zero seconds, but that is the only calculation that takes place. Angus