-
Content Count
1812 -
Joined
-
Last visited
-
Days Won
33
Everything posted by Angus Robertson
-
Invalid Compiler Directive: 'MESSAGES'
Angus Robertson replied to Incus J's topic in ICS - Internet Component Suite
Side tracking slightly, what was the last ICS version you successfully built with MacOS32? I believe V8.62 at least was successful for MacOS from reports here. While I understand the ASM problems, not sure why all these LongInt problems are happening when Win64 is happy. In CRC, function Endian can be killed, no longer used, don't think it worked anyway. Might be better to wait until you have found all the compiler errors before sending anything, but I'm quite happy to update as you report them. Angus -
Invalid Compiler Directive: 'MESSAGES'
Angus Robertson replied to Incus J's topic in ICS - Internet Component Suite
Sorry, can not help with InterlockedIncrement, that code was written by a developer that is no longer with us, and appears to be using some CPU feature for a few functions like Posix.Messages, TIcsThreadTimer and web sessions, The last assembler I wrote was Z80 for Wang Word Processing, over 30 years ago. Hopefully some watching here might have a clue what this interlocking is all about? Angus -
Invalid Compiler Directive: 'MESSAGES'
Angus Robertson replied to Incus J's topic in ICS - Internet Component Suite
Have you built and installed the three packages for FMX without any more errors. That is the most important and useful test. Ideally from the overnight zip, but there will be more changes before the next release. Angus -
Invalid Compiler Directive: 'MESSAGES'
Angus Robertson replied to Incus J's topic in ICS - Internet Component Suite
I've fixed the $MESSAGE issue, I added that but it is not tested by building FMX packages. PUREPASCAL was defined OverbyteIcsUtils.pas for CPUX64 but is currently suppressed since we now have the necessary assembler. I'll set it for MacOS64 I've fixed the AddSorted mismatch, does not show up under Win64. Please let me know of any other MacOS errors you find, I can not test this since I don't have any Mac hardware. Won't be in SVN for a few days. Angus -
THWClient.RequestDone
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
There are several httperr constants in OverbyteIcsHttpProt,pas that reflect the operation result, httperrNoError = 0 being the most common result. There are no literals for these constants. Angus -
Remove/disable .NET personality from RAD Studio 2007
Angus Robertson replied to dummzeuch's topic in Delphi IDE and APIs
My main problem with .net and D2007 is that every time I install a new version of Windows (twice a year with 10), Microsoft deletes the four Borland.x.Targets files it installs under \Microsoft.Net\, but learnt my lesson a long time ago and keep copies to restore. Angus -
TWSocketThrdClient and THttpCli.Post in socket thread
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
In general, ICS servers will support a few hundred clients doing simple downloads or uploads, before threads are needed to use multiple CPUs. That may change if ARM based server chips appear with dozens of lower spec cores than current Xeon chips with just a few cores (unless you pay silly money). Only think about threads when it slows down. Angus -
TWSocketThrdClient and THttpCli.Post in socket thread
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
I've never looked at the OverbyteIcsThrdSrvV2 sample so can not comment on, I'd only say don't use a thread unless you really need it. Making HTTP requests with GET and POST are asynchronous so are not blocking your client unless you need many milliseconds of processor time to read through hundreds of megs of response. Threads are sometimes needed for database access to process large query results, but my own database driven web server does not yet need threads for it's load, SQL queries usually only take 50ms or less. Angus -
TWSocketThrdClient and THttpCli.Post in socket thread
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
Beware that TWSocketThrdServer has not been updated or tested for over 10 years, and specifically not with the latest OpenSSL which changed the way thread locking works. Nor does it have any of the many new features in TWSocketServer. You may be better off retaining TWSocketServer and only starting a thread if you expect a long query, which is how TFtpServer works, look at Client.ProcessingThread which is used for processor heavy functions. Really do need to bring TWSocketThrdServer up to date, but very few people need it. Angus -
superobject fails to parse this json string
Angus Robertson replied to RaelB's topic in Delphi Third-Party
The ICS version of superobject now reports 'Error teDepth at line 1 column 6067 at depth 31' for the Json block, little more useful than nil result. The information is all there internally, just not reported. Not in SVN yet. Angus -
superobject fails to parse this json string
Angus Robertson replied to RaelB's topic in Delphi Third-Party
Thanks, I shall update the superobject included with ICS appropriately. I did try the Json file on two web site parsers yesterday, one worked, one failed with an error but did not mention object depth, ran out of time to look further. Angus -
superobject fails to parse this json string
Angus Robertson replied to RaelB's topic in Delphi Third-Party
Did you see any downside to increasing SUPER_TOKENER_MAX_DEPTH. does it require more memory for every parse or something? Really need a way for tok.err to be exposed on failure, it's frustrating when superobject just fails for no obvious reason, although usually badly formatted json. Angus -
Look in the TIcsFtpMulti component to see how it logs using the OnResponse and OnDisplayFile. events. As Francois suggests, you can build the OverbyteIcsXferTst sample that uses that component, check it yourself, then get your client to transfer the same file on their system with it, to see if it fails. How large or small is this file? The sample creates a log file. Angus
-
Someone else mentioned a similar bug recently, but can not find the message. I fixed a bug calculating the speed of zero second FTP transfers 15 years ago that resulted in a similar error, but this would not happen with more recent releases. ICS does have a n TicsLogger component that developers can add to their applications, but it is primarily for internal debugging of SSL applications, older components needed to be updated to log events and that was never done consistently. Newer components like TIcsFtpMulti and TSslHttpRest have ProgressEvent or OnHttpRestProg events, and LogLevel or DebugLevel properties that can be used for screen display and file logging. If you continue using the older TFtpCli component you will need to add logging the onFtpClientDisplay and OnFtpResponse events to log the FTP protocol commands and responses so you can see at which point the error is happening. Angus
-
Switching TLS on/off on Server
Angus Robertson replied to Mark Williams's topic in Network, Cloud and Web
If you mean you only want to accept LAN connections on port 80 or something, you can can do as you suggest, but this is irrelevant to SSL/TLS. It is quite normal nowadays to respond with a redirection to the correct HTTPS URL. Angus -
Windows 10 vs Windows 7 SMTP/Winsock issue
Angus Robertson replied to GillesL.'s topic in ICS - Internet Component Suite
Try building and running the sample OverbyteIcsMailQuTst.dpr in .\Samples\delphi\sslinternet\ and see if you get an error sending emails. This is now the recommended way for sending SMTP emails, it tries multiple SMTP servers with attempts over several days to ensure email is sent. Angus -
The main issue is you rarely want to put a lot of data into a memo, you can not view it while being received since it is updated so often, unless you only want to see the last few lines or are receiving data slowly, like alarm signals or something. The most efficient way to update a log window is to write data for display to a buffer (simple string is fine) and then use a timer in the application to empty the buffer to the TMemo every one to two seconds, which is about as often you can see it. That is exactly what more recent ICS samples do, like OverbyteIcsHttpRestTst1.pas, the AddLog proc builds the line and writes a file, the TimerLogTimer event updates the TMemo. In some applications I simply discard most of the log lines if there are hundreds arriving each second. Angus
-
Most ICS applications do not use threads so synchronise is not needed, However receiving data is blocked while you do anything in the OnDataAvailable event so not a good idea to update a memo if you are expecting to receive a lot of data. Angus
-
OverbyteIcsLIBEAY.pas: f_CRYPTO_get_ex_data should return Pointer, not Integer
Angus Robertson replied to Ralf Junker's topic in ICS - Internet Component Suite
The CRYPTO_get_ex_new_index and similar functions have never been used by ICS. Angus -
SSL_CTX_use_certificate:ee key too small
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
IcsLogger output is intended for internal debugging of ICS components, not end user applications, and is always used with extra logging in the application. So I have no idea what components you are using, with what IP addresses, ports or protocols, nor which of the numerous ways you have setup the module. If you have setup the module as an SSL TCP client, you need an SSL/TLS certificate for the ICS SSL server or it will not start. It is more normal to set-up IOT modules as servers, so you contact them, but then they need a certificate. Suggest you read my earlier message again. Angus -
SSL_CTX_use_certificate:ee key too small
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
Rather than looking at OverbyteIcsSimpleSslServer and OverbyteIcsSimpleSslClient. which I assumed you wanted to talk to each other,. I suggest you look at OverbyteIcsIpStmLogTst instead, which can be configured as a server or client and handles all the SSL stuff for you, just setting SslCliSecurity or SslSrvSecurity as I mentioned above from combo boxes. You should be able to talk to your Ethernet module with the demo. It does not support SSL client certificates, but you probably don't need them. Angus -
SSL_CTX_use_certificate:ee key too small
Angus Robertson replied to Dmytro Lendel's topic in ICS - Internet Component Suite
The declaration for sslSecLevel128bits has the comment 'RSA/DH keys=>3072, ECC=>256, FS forced, no TLS/1.0' which means you SSL/TLS certificate must have an RSA key length of 3,072 or later or EC-256. You probably have a common RSA 2,048 bit certificate. In recent version of ICS with modern components, you generally don't set the OpenSSL security level, instead you set the client or server security level SslCliSecurity or SslSrvSecurity which set the ciphers, TLS version and security level for various scenarios. Angus -
To save me looking at lots of old compilers, does anyone know in which version of Delphi that Pos got an extra argument to become equivalent to PosEx in D2007? Hopefully D2009? Angus
-
When did Pos become PosEx?
Angus Robertson replied to Angus Robertson's topic in RTL and Delphi Object Pascal
PosEx was available in Delphi 2007, but became obsolete in XE3 when Pos got a third offset argument. function Pos(const SubStr, Str: UnicodeString; Offset: Integer = 1): Integer; Abgus -
bug Odd (OpenSSL?) bug and types in X509 certs
Angus Robertson replied to merijnb's topic in ICS - Internet Component Suite
The osslsigncode project is an alternative to signtool, I'd like to play with it, but I'm not a C developer. Currently I have to enter a password for every single EXE or DLL I sign with the ICS open source certificate because the key is only a secure dongle, it's a pain. Angus