forked from gokalkan/gokalkan
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcert_info.go
More file actions
49 lines (45 loc) · 887 Bytes
/
cert_info.go
File metadata and controls
49 lines (45 loc) · 887 Bytes
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
package gokalkan
import "time"
const (
CertTypeIndividual = "individual"
CertTypeOrganization = "organization"
)
const (
CertSubjectRoleUndefined CertSubjectRole = iota
CertSubjectRoleCEO
CertSubjectRoleSign
CertSubjectRoleSignFinance
CertSubjectRoleHR
CertSubjectRoleEmployee
)
type (
Summary struct {
Type CertType
Subject CertSubject
Organization *CertOrganization
Issuer CertIssuer
PublicKey string
SerialNumber string
NotAfter time.Time
NotBefore time.Time
}
CertType string
CertSubjectRole int
CertSubject struct {
CommonName string
LastName string
Country string
IIN string
DN string
}
CertOrganization struct {
Name string
BIN string
SubjectRole CertSubjectRole
}
CertIssuer struct {
CommonName string
Country string
DN string
}
)