Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help with Let's Encrypt auto renewal
#10
(08-01-2020, 03:55 AM)joel Wrote:
(06-20-2018, 01:46 AM)Alexandre Machado Wrote:
(06-18-2018, 09:58 PM)ioan Wrote: I found a solution and so far works fine:

Code:
procedure TIWServerController.IWServerControllerBaseNewSession(aSession: TIWApplication);
var
  challengeResponse, challengeFileName: string;
begin
  [...] 
  else if ContainsText(WebApplication.Request.PathInfo, '.well-known/acme-challenge') then
  begin
    // for let's encrypt
    challengeFileName := WebApplication.ApplicationPath + 'wwwroot' + WebApplication.Request.PathInfo.Replace('/', '\');
    if TFile.Exists(challengeFileName) then
      challengeResponse := TFile.ReadAllText(challengeFileName)
    else
      challengeResponse := '';
    WebApplication.Response.WriteString(challengeResponse);
    WebApplication.Terminate;
  end;
end;

Hi Ioan,

We had the same issue recently in one of our applications and I'm seriously thinking about adding built-in support for this kind of stuff in IW 15 code base. It will make life much easier :-)

Thanks for sharing your solution

Alex,

Does iw15.2.10 solve the issue of allowing the let's encrypt renewal process work and find the renewal file under "well-known/acme-challenge/asadfff" work?

I think I found the answer:  https://www.atozed.com/forums/printthread.php?tid=1383
Reply


Messages In This Thread
Help with Let's Encrypt auto renewal - by ioan - 06-18-2018, 05:48 PM
RE: Help with Let's Encrypt auto renewal - by joel - 08-02-2020, 02:25 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)