Skip to content

Commit 0faba6f

Browse files
committedNov 18, 2022
Include certificate chain in example
1 parent b43823c commit 0faba6f

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed
 

‎timestamp_example_test.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,14 @@ func ExampleCreateRequest_ParseResponse() {
4545

4646
fmt.Println(tsResp.HashedMessage)
4747
fmt.Println(tsResp.Policy)
48-
if len(tsResp.Certificates) > 0 {
49-
fmt.Println(tsResp.Certificates[0].Subject.Organization)
48+
for _, c := range tsResp.Certificates {
49+
fmt.Println(c.Subject.Organization, c.Subject.OrganizationalUnit)
5050
}
5151

5252
// Output:
5353
// [140 222 43 143 28 80 96 97 4 176 145 205 188 119 197 142 149 101 26 96 188 163 178 64 230 162 199 171 176 178 173 128]
5454
// 1.2.3.4.1
55-
// [Free TSA]
55+
// [Free TSA] [TSA]
56+
// [Free TSA] [Root CA]
5657

5758
}

0 commit comments

Comments
 (0)
Please sign in to comment.