Jump to content

Angus Robertson

Members
  • Content Count

    2010
  • Joined

  • Last visited

  • Days Won

    36

Everything posted by Angus Robertson

  1. Your Win64 fixes are now in SVN thanks, with a couple more that you missed because they were LongInt. Fortunately most PostMessages already casted pointers correctly, just these older samples. Angus
  2. Angus Robertson

    ICS V8.66 announced

    Sorry, your redirection problem needs actual testing and not had time in the last two weeks for anything new. Angus
  3. Angus Robertson

    Twsocket udp how to get the exact buffersize that received ? ?

    I agree that UDP should send whole packets, but when they arrive two or more may be buffered before they are read in the DataAvailable event. Also, they may not be sent as complete packets, for instance a record may be sent in one send/packet then a CRLF as the next send/packet, so if the application is waiting for that CRLF as a record separator, it needs two packets. So best to treat UDP as a stream. Angus
  4. Angus Robertson

    Twsocket udp how to get the exact buffersize that received ? ?

    The most important issue about the DataAvailable event is not the size of your Receive/ReceiveFrom buffer, but that you should loop within the event continually reading all waiting data into a larger public receive buffer or stream until Receive/ReceiveFrom returns 0 or less. If you don't do that, the event will be called again immediately you exit it to empty the internal receive buffers. There is no guarantee about the length of data any call to Receive/ReceiveFrom will return even for UDP, it might take several events for a full packet to be assembled, rarely, but it can happen. As I said before, all this is done for you in the OverbyteIcsIpStreamLog component . Angus
  5. Your patches don't work on my working copy, I look for changes manually. The samples were never designed or tested to build on Win64, only the components, although we do test the actively supported samples periodically. Angus
  6. Angus Robertson

    Twsocket udp how to get the exact buffersize that received ? ?

    You can use the OverbyteIcsUdpLstn sample to see how to receive UDP data. Your won't have megabytes of data waiting when that event is called, in fact you will never know how much UDP data is being sent since it only arrives one packet at a time. So typically you use ReceiveFrom to receive a maximum of say 4K, and then add that to a large receive buffer. Much easier to use the new OverbyteIcsIpStreamLog component which does all this for you, look at the OverbyteIcsIpStmLogTst sample. Angus
  7. Angus Robertson

    Bug in OverbyteIcsHttpAsy1

    Some of these old samples do illustrate programming techniques or features that the SSL samples don't, and it takes effort to remove old things... Angus
  8. Angus Robertson

    Bug in OverbyteIcsHttpAsy1

    That is a very old sample that does not support SSL/TLS. The current active HTTPS client samples are OverbyteIcsHttpsTst.dpr and OverbyteIcsHttpRestTst.dpr in the sslinternet directory. Angus
  9. Angus Robertson

    SetURL & SetProxyURL helper methods for TWSocket

    The proxy setters changes are now in SVN, with an updated OverbyteIcsSocksTst sample that now also tests HTTP Tunnelling, which we did not seem to do. Will be zipped overnight. I tested the HTTP Tunnelling changes against the ICS proxy server, which currently deliberately only tunnels HTTP, need to fix that, but have not tested socks since 7Proxy failed my 10 minutes to find out how to configure it limit, sure it works fine once you find some non-empty help files. Angus
  10. Angus Robertson

    OverbyteIcsTicks64 missing include file

    I added OverbyteIcsDefs.inc last week, not in SVN yet, other stuff pending. But OverbyteIcsTicks64 has always compiled okay, it is in the IcsCommonDxx package which is built weekly, so your problem must be something else. Angus
  11. Angus Robertson

    SetURL & SetProxyURL helper methods for TWSocket

    I've added SetSocks and SetHTTPTunnel to TCustomSocksWSocket, with a new ProxyURL property. Not in SVN yet. I can test HTTP Tunnelling through the ICS Proxy Server I have running on my public servers, but can not find any samples that use it. We do have OverbyteIcsSocksTst, but I don't currently have a SOCKS server running. Less sure about SetURL() which only sets the wsocket host and port, is that really worthwhile? Angus
  12. Angus Robertson

    GetAsync in other Thread

    You need a message handler in the thread execute loop, to handle all the events, these lines are from TMailQuThread.Execute; in OverbyteIcsMailQueue.pas. FIcsWndControl.ProcessMessages ; if FIcsWndControl.Terminated then break ; if NOT FActive then break ; // component if Terminated then break ; // thread if (errorcounter > 10000) then break ; // sanity check Angus
  13. Angus Robertson

    8.66 installation for D2007 problems

    Thanks, seems my local version of the D2007 package with VCLZip has slipped into SVN, will fix that shortly. Always hate updating ICS packages, over 100 units to modify. Angus
  14. Angus Robertson

    SetURL & SetProxyURL helper methods for TWSocket

    Url is not a large unit and probably linked into most applications anyway, except the simplest, so it can happen. I've also just saved a lot of space by removing a lot of legacy OpenSSL support code. Angus
  15. Angus Robertson

    SetURL & SetProxyURL helper methods for TWSocket

    Thanks, will have a look next week. BTW, your last proxy fix is in SVN now, seems I broke it adding international domain name support. Angus
  16. Angus Robertson

    8.66 installation for D2007 problems

    ICS is maintained using Delphi 2007, so is the best tested platform, provided I put the correct files in SVN. VCLZlip is controlled by OverbyteVclZip.inc, and the version in my SVN has {.DEFINE Zipping}. TIcsTwitter, etc were added six months ago to OverbyteIcsSslHttpRest.pas, so you probably have an old version somewhere. Angus
  17. Angus Robertson

    OverbyteIcsTicks64 missing include file

    That unit does not have the definitions include, but does not use any of them either, and seems to compile fine in all the packages Angus
  18. Thanks, will apply shortly. Don't often look at socks or tunnels. Angus
  19. Angus Robertson

    Read out signed executable certificate possible?

    I have a component that checks signing certificates: https://www.magsys.co.uk/delphi/magtrustchk.asp Angus
  20. Angus Robertson

    ICS 8.65 design installation failed

    Also ensure the ICS source directory is in the path, and the path is set for the correct language and target. Angus
  21. Angus Robertson

    ICS 8.65 design installation failed

    Don't read French, so no idea what error. But quite common to get a false error saying can not install, but they are installed okay next time you start RAD Studio. Angus
  22. Angus Robertson

    Max string literal length = 255

    Agreed. annoying when creating SSL certificates as literals to embed in an application. Angus
  23. Sockets stream single bytes, so each end needs to agree on whether single or double byte characters are being sent, and handle them the same way. It is relatively unusual to send two byte characters over the internet, due to most western languages having a lot of one byte Unicode characters. So generally conversion to UTF-8 is more efficient. To avoid Delphi doing it's own code page conversions it is better to use TBytes to send and receive data, then functions IcsMoveStrinngToTbytes and IcsMoveTBytesToString with your desired CodePage. Angus
  24. No, TSslWSocket still needs an TSslContext, although you don't usually need to change any defaults unless you want to restrict protocols. However, you can use the high level component TIcsIpStrmLog in client mode to send and receive simple data, and that does not need an TSslContext. It's sample OverbyteIcsIpStmLogTst.dpr can be set to client or server mode, or local when it does both and send lines of data to itself. In server mode it is configured using IcsHosts so it might be a quick swap. Angus
×