-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapi.go
90 lines (72 loc) · 1.91 KB
/
api.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
package kmip
import "time"
type KmipGetAPIResponse struct {
Id string `json:"id"`
Value string `json:"value"`
Algorithm string `json:"algorithm"`
}
type KmipGetAPIRequest struct {
Id string `json:"id"`
}
type KmipCreateAPIResponse struct {
Id string `json:"id"`
}
type KmipCreateAPIRequest struct {
Algorithm string `json:"algorithm"`
}
type KmipDestroyAPIRequest struct {
Id string `json:"id"`
}
type KmipDestroyAPIResponse struct {
Id string `json:"id"`
}
type KmipGetAttributeAPIRequest struct {
Id string `json:"id"`
}
type KmipGetAttributeAPIResponse struct {
Id string `json:"id"`
Algorithm string `json:"algorithm"`
IsActive bool `json:"isActive"`
CreatedAt time.Time `json:"createdAt"`
UpdatedAt time.Time `json:"updatedAt"`
}
type KmipActivateAPIRequest struct {
Id string `json:"id"`
}
type KmipActivateAPIResponse struct {
Id string `json:"id"`
IsActive bool `json:"isActive"`
}
type KmipRevokeAPIRequest struct {
Id string `json:"id"`
}
type KmipRevokeAPIResponse struct {
Id string `json:"id"`
}
type KmipLocateAPIResponse struct {
Objects []struct {
Id string `json:"id"`
IsActive bool `json:"isActive"`
Algorithm string `json:"algorithm"`
Name string `json:"name"`
} `json:"objects"`
}
type KmipRegisterAPIRequest struct {
Name string `json:"name"`
Key string `json:"key"`
Algorithm string `json:"algorithm"`
}
type KmipRegisterAPIResponse struct {
Id string `json:"id"`
}
type KmipServerRegistrationAPIRequest struct {
HostnamesOrIps string `json:"hostnamesOrIps"`
CommonName string `json:"commonName"`
TTL string `json:"ttl"`
}
type KmipServerRegistrationAPIResponse struct {
Certificate string `json:"certificate"`
CertificateChain string `json:"certificateChain"`
PrivateKey string `json:"privateKey"`
ClientCertificateChain string `json:"clientCertificateChain"`
}