YES !

YES !

I've successfully registered my first domain on Let's Encrypt with a Delphi Tokyo application !

Now it's time to clean the code, handling errors...you can prepare your credit card :D

Comments

  1. You are lucky, I spent two days without success, then I bought one from godaddy for $10, which was more cheaper than the time spent trying all the ways with let's encrypt.

    ReplyDelete
  2. Mohammed Nasman and you can use the certificat in a Delphi WebBroker application ?

    ReplyDelete
  3. Prepared, if it works with mORMot :)

    ReplyDelete
  4. LE certs work with any Delphi thing if you just install them right. IntraWeb has been running using optinoal LetsEncrypt certificates for a while now and we have more support coming.

    ReplyDelete
  5. Chad Hower it's not about using a LE certificate, it's about requesting one and renew it from Delphi :)

    ReplyDelete
  6. Paul TOTH IntraWeb servers will auto renew them for you transparently.

    ReplyDelete
  7. What do you mean by this exactly? Security certs are mainly for installing into websites. I'm puzzled what either one has to do with a Delphi app?

    ReplyDelete
  8. David Schwartz put a TidHTTPServer component on a form and you have a website, add a TidServerIOHandlerSSLOpenSSL component and you have a HTTPS server that needs a certificate

    you can also start a new WebBroker or DataSnap standalone server with HTTPS and you need also a certificate (AFAIK Indy is used also)

    ReplyDelete
  9. David Schwartz Web apps in Delphi. LE certificates expire every 3 months or so and have to be renewed....

    ReplyDelete
  10. Paul TOTH Well, a little more info goes a long way sometimes! Thanks.

    ReplyDelete
  11. Looking forward this. Are you going to release it as a commercial or whatever?

    ReplyDelete
  12. I'll try to make some money for once :)

    you can find the compiled component on my Github repository

    github.com - tothpaul/LetsEncryptDelphi

    ReplyDelete
  13. Any benefits compared to using free win-acme tool as described in this post, for example? https://www.tmssoftware.com/site/blog.asp?post=454

    ReplyDelete
  14. Wagner Landgraf you can use HTTPS with Let's Encrypt for free with a lot of tools, just follow the tutorial and try harded if it fails.

    With my component you can embedded the process in your Delphi WebApplication by settings 3 properties and 2 events. The choice is yours.

    ReplyDelete
  15. Paul TOTH Does it handle renewal? Can it be integrated with the HTTP server in the mORMot framework? Thanks.

    ReplyDelete
  16. Edwin Yip Yes, just call periodically RegisterDomain()

    I don't know mORMot but the component is compatible with anything, you just have to adapt the OnHttpChallenge event to your configuration.

    For instance, for my own application, the HTTP port is handled by IIS so my event just stores the challenge file on disk instead of using a self hosted TidHTTPServer.

    procedure TMain.OnHttpChallenge(Sender: TObject; const Domain, Token,
    Thumbprint: string);
    var
    Stream: TFileStream;
    Content: AnsiString;
    begin
    Stream := TFileStream.Create('D:\Data\www\.well-known\acme-challenge\' + Token, fmCreate);
    try
    Content := AnsiString(Token) + '.' + AnsiString(Thumbprint);
    Stream.Write(Content[1], Length(Content));
    finally
    Stream.Free;
    end;
    end;

    you also have to reload the certificate

    procedure TMain.OnCertificate(Sender: TObject; Certificat: TStrings);
    begin
    Certificat.SaveToFile('..\keystore\domain.crt');
    ButtonStopClick(Self);
    StartServer(); // HTTPOptions.CertFile := '...'
    end;

    ReplyDelete

Post a Comment