aloopkin / WinCertes

An ACMEv2 client for Windows
GNU General Public License v3.0
118 stars 28 forks source link

While issuing a certificate, getting the 404 or 500 response #48

Open NoobXXX890290 opened 1 year ago

NoobXXX890290 commented 1 year ago

Describe the bug While issuing a certificate, getting the 404 or 500 response

To Reproduce Steps to reproduce the behavior:

  1. Open CMD / Powershell with administrator privillages
  2. Insert a command: WinCertes.exe -s https://acme-v02.api.letsencrypt.org/directory -e -d terminale.krakow.pl -w=C:\inetpub\wwwroot -b "terminale.krakow.pl" -p

Expected behavior Get the certificate and bind it automatically to a website using wincertes

Screenshots or Logs [DEBUG] PFX password will be: d8af09ac3de64731 [DEBUG] Current certificate expiration date is: [DEBUG] Initiating HTTP Validation for terminale.krakow.pl [DEBUG] Error while trying to register and validate order System.Exception: Could not validate HTTP challenge: 78.11.55.165: Invalid response from http://terminale.krakow.pl/.well-known/acme-challenge/g8_hOUODJ3wvEIaVZwZUj_XX8aMCPpkA5r2O-YBvhdY: 500 w WinCertes.CertesWrapper.d17.MoveNext() w D:\a\WinCertes\WinCertes\WinCertes\CertesWrapper.cs:wiersz 218 --- Koniec śladu stosu z poprzedniej lokalizacji, w której wystąpił wyjątek --- w System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() w System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) w System.Runtime.CompilerServices.TaskAwaiter.GetResult() w WinCertes.CertesWrapper.d16.MoveNext() w D:\a\WinCertes\WinCertes\WinCertes\CertesWrapper.cs:wiersz 172 [DEBUG] Failed to register and validate order with CA: Could not validate HTTP challenge: 78.11.55.165: Invalid response from http://terminale.krakow.pl/.well-known/acme-challenge/g8_hOUODJ3wvEIaVZwZUj_XX8aMCPpkA5r2O-YBvhdY: 500 Failed to register and validate order with CA: Could not validate HTTP challenge: 78.11.55.165: Invalid response from http://terminale.krakow.pl/.well-known/acme-challenge/g8_hOUODJ3wvEIaVZwZUj_XX8aMCPpkA5r2O-YBvhdY: 500

Desktop (please complete the following information):

Additional context I've tried many different configs, started with one that involved different location for the root directory (not in c:/inetpub/wwwroot, but in i://wwroot, now it is in the default location), windows privilliges cant be the case cause i checked it multiple times, i've added the mime type recognision in web.config like: <?xml version="1.0" encoding="UTF-8"?>

I've also tried many diffrerent configs when it comes to the -w option: -w "c\inetpub\wwwroot" -w "c\inetpub\wwwroot\" -w and nothing seems to make a difference... Also, i've checked some third party validation software like: https://check-your-website.server-daten.de/?q=terminale.krakow.pl and there is someting about DNS problem, i don't get it as the site is available from the outside... One more thing, i checked if wincertes has problems with creting a folder, but don't know, if that is the issue, i've created a folder exactly like: .well-known\acme-challenge (with the right spelling, that was chcecked) and nothing appeared, even with no folder, the wincertes didn't create one