Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception if ACME Server sends empty TOS path #1319

Closed
oregano87 opened this issue Dec 11, 2019 · 1 comment
Closed

Exception if ACME Server sends empty TOS path #1319

oregano87 opened this issue Dec 11, 2019 · 1 comment
Milestone

Comments

@oregano87
Copy link

I am trying to test this client on a test environment with a self hosted ca. The acme-server has no TOS information configured and sends therefore an empty path to the client. But the client does not like an empty path value ;-)

PS C:\win-acme.v2.1.0.539.x64.pluggable> .\wacs.exe --baseuri "https://pgwy.domain.test/acme/directory" --emailaddress "admi
n@domain.test" --validationmode dns-01 --validation acme-dns --acmednsserver "https://acme-dns.domain.test" --verbose
 [VERB] Verbose mode logging enabled
 [VERB] Looking for settings.json in C:\win-acme.v2.1.0.539.x64.pluggable
 [DBUG] Config folder: C:\ProgramData\win-acme\pgwy.domain.testacmedirectory
 [DBUG] Log path: C:\ProgramData\win-acme\pgwy.domain.testacmedirectory\Log
 [DBUG] Cache path: C:\ProgramData\win-acme\pgwy.domain.testacmedirectory\Certificates

 [INFO] A simple Windows ACMEv2 client (WACS)
 [INFO] Software version 2.1.0.539 (RELEASE, PLUGGABLE)
 [INFO] IIS version 10.0
 [INFO] Running with administrator credentials
 [WARN] Scheduled task not configured yet
 [INFO] Please report issues at https://github.com/PKISharp/win-acme
 [VERB] Test for international support: 語言 язык لغة
 [VERB] Verbose mode logging enabled
 [VERB] Arguments: --baseuri https://pgwy.domain.test/acme/directory --emailaddress admin@domain.test --validationmode dns-01 --
validation acme-dns --acmednsserver https://acme-dns.domain.test --verbose
 [DBUG] Renewal period: 55 days

 N: Create new certificate (simple for IIS)
 M: Create new certificate (full options)
 L: List scheduled renewals
 R: Renew scheduled
 S: Renew specific
 A: Renew *all*
 O: More options...
 Q: Quit

 Please choose from the menu: n

 [INFO] Running in mode: Interactive, Simple

  Please specify how the list of domain names that will be included in the
  certificate should be determined. If you choose for one of the "all bindings"
  options, the list will automatically be updated for future renewals to
  reflect the bindings at that time.

 1: Single binding of an IIS website
 2: All bindings of an IIS website
 3: All bindings of multiple IIS websites
 4: Manual input
 5: Read a CSR created by another program
 C: Abort

 How shall we determine the domain(s) to include in the certificate?: 4

 Enter comma-separated list of host names, starting with the common name: win.domain.test

 [INFO] Target generated using plugin Manual: win.domain.test

 1: win.domain.test

 Choose site to create new bindings: 1

 [VERB] Checking [Manual] win.domain.test
 [VERB] Loading ACME account signer...
 [VERB] Constructing ACME protocol client...
 [DBUG] Send GET request to https://pgwy.domain.test/acme/directory
 [VERB] Request completed with status OK
 [DBUG] Send HEAD request to https://pgwy.domain.test/acme/new-nonce
 [VERB] Request completed with status OK
 [EROR] (ArgumentNullException): Value cannot be null. (Parameter 'path2')
 [DBUG] Exception details: ArgumentNullException {Message="Value cannot be null. (Parameter 'path2')", ParamName="path2"
, TargetSite=System.String Combine(System.String, System.String), StackTrace="   at System.IO.Path.Combine(String path1,
 String path2)\r\n   at PKISharp.WACS.Acme.AcmeClient.LoadAccount(IJwsTool signer)\r\n   at PKISharp.WACS.Acme.AcmeClien
t.ConfigureAcmeClient()\r\n   at PKISharp.WACS.Acme.AcmeClient.EnsureInitialized()\r\n   at PKISharp.WACS.Acme.AcmeClien
t.Retry[T](Func`1 executor)\r\n   at PKISharp.WACS.Acme.AcmeClient.CreateOrder(IEnumerable`1 identifiers)\r\n   at PKISh
arp.WACS.RenewalExecutor.Renew(Renewal renewal, RunLevel runLevel)\r\n   at PKISharp.WACS.RenewalManager.SetupRenewal(Ru
nLevel runLevel)\r\n   at PKISharp.WACS.Host.Wacs.MainMenu()\r\n   at PKISharp.WACS.Host.Wacs.Start()", Data=[], InnerEx
ception=null, HelpLink=null, Source="System.Private.CoreLib", HResult=-2147467261}
 [VERB] Exiting with status code -2147467261
@WouterTinus
Copy link
Member

Nice catch, always useful to test with alternative ACME implementations!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants