aboutsummaryrefslogtreecommitdiff
path: root/messages.go
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2015-12-04 17:40:32 +0100
committerDimitri Sokolyuk <demon@dim13.org>2015-12-04 17:40:32 +0100
commit605b1310fb6e1c1fa1382df76a1d52954fc82ba7 (patch)
treec5228d10b35829114f375ef37e1be43a1a2b0047 /messages.go
parentb87c51d9fd46e446c620b13bf8e8c91f665fe8f4 (diff)
Update Signer
Diffstat (limited to 'messages.go')
-rw-r--r--messages.go19
1 files changed, 12 insertions, 7 deletions
diff --git a/messages.go b/messages.go
index cb10a79..b5a1738 100644
--- a/messages.go
+++ b/messages.go
@@ -1,5 +1,10 @@
package acme
+import (
+ "net"
+ "time"
+)
+
const (
// LEV1 Let's Encrytpt V1
LEV1 = `https://acme-v01.api.letsencrypt.org/directory`
@@ -27,11 +32,11 @@ type Registration struct {
// RegistrationResp ...
type RegistrationResp struct {
- ID int `json:"id"`
- Key Key `json:"key"`
- Contact []string `json:"contact"`
- InitialIP string `json:"initalIp"` // not in draft
- CreatedAt string `json:"createdAt"` // 2006-01-02T15:04:05.999999999Z
+ ID int `json:"id"`
+ Key Key `json:"key"`
+ Contact []string `json:"contact"`
+ InitialIP net.IP `json:"initialIp"` // not in draft
+ CreatedAt time.Time `json:"createdAt"` // 2006-01-02T15:04:05.999999999Z
}
// Key contains public part of jose.JsonWebKey
@@ -50,7 +55,7 @@ type Authorization struct {
// AuthorizationResp Objects
type AuthorizationResp struct {
Identifier Identifier `json:"identifier"`
- Status string `json:"status,omitemtpy"` // e.g. valid
+ Status Status `json:"status,omitemtpy"` // e.g. valid
Expires string `json:"expires,omitempty"` // 2006-01-02
Challenges []Challenge `json:"challenges"`
Combinations [][]int `json:"combinations,omitemtpy"`
@@ -65,7 +70,7 @@ type Identifier struct {
// Challege ...
type Challege struct {
Type string `json:"type"` // http-01
- Status string `json:"status"` // e.g. valid
+ Status Status `json:"status"` // e.g. valid
Validated string `json:"validated"` // 2006-01-02T15:04Z
KeyAuthorization string `json:"keyAuthorization"`
}