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

Multiple domain names are not supported And wildcard domain names #8

Closed
originnets opened this issue Jun 14, 2019 · 1 comment
Closed

Comments

@originnets
Copy link

originnets commented Jun 14, 2019

Multiple domain names are not supported
Creating new order for domains: [www.aaa.com aaa.com]
2019/06/14 15:23:49 Error creating new order: acme: error code 400 "urn:ietf:params:acme:error:rejectedIdentifier": Error creating new order :: Invalid character in DNS name
wildcard domain names ( ChallengeTypeDNS01)
acme: error code 400 "urn:ietf:params:acme:error:rejectedIdentifier": Error creating new order :: DNS name had a malformed wildcard label

@eggsampler
Copy link
Owner

Hi,

Are you able to demonstrate some code where you are experiencing these errors? I'm not able to replicate your error without deliberately adding invalid characters. For example, the following works to create a new order,

package main

import (
	"crypto/ecdsa"
	"crypto/elliptic"
	cryptorand "crypto/rand"
	"log"

	"github.com/eggsampler/acme/v2"
)

func main() {
	accountKey, err := ecdsa.GenerateKey(elliptic.P256(), cryptorand.Reader)
	if err != nil {
		log.Fatalf("error creating account private key: %v", err)
	}
	client, err := acme.NewClient("https://acme-staging-v02.api.letsencrypt.org/directory")
	if err != nil {
		log.Fatalf("error creating client: %v", err)
	}
	account, err := client.NewAccount(accountKey, false, true)
	if err != nil {
		log.Fatalf("error creating new account: %v", err)
	}
	order, err := client.NewOrderDomains(account, "aaa.com", "*.aaa.com")
	if err != nil {
		log.Fatalf("error creating order: %v", err)
	}
	log.Printf("order created: %+v", order)
}

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

No branches or pull requests

2 participants