diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-11-19 18:39:07 -0500 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-11-19 18:39:07 -0500 |
commit | ccb418c3a26fd687bfcd01cb42151f9507fcbe66 (patch) | |
tree | 4ef214e5517e73ce38ad77915a47d6f2518cd184 | |
parent | 198e0680822e2371bf256b0c39017bfe202f3e85 (diff) |
tls-pem2html: s/Link/Url/g
-rw-r--r-- | tls-pem2html.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tls-pem2html.go b/tls-pem2html.go index 50d5104..be93b44 100644 --- a/tls-pem2html.go +++ b/tls-pem2html.go @@ -94,10 +94,10 @@ var tmpl = template.Must(template.New("pem2html"). </tr> {{range $cert := .certs}} <tr class="{{$cert.Class}}"> - <td style="background-color: {{$cert.X509.NotBefore | green}}"><a href="{{$cert.Link}}" title="{{$cert.Error}}">{{$cert.X509.NotBefore.Local.Format "2006-01-02"}}</a></td> - <td style="background-color: {{$cert.X509.NotAfter | red }}"><a href="{{$cert.Link}}" title="{{$cert.Error}}">{{$cert.X509.NotAfter.Local.Format "2006-01-02"}}</a></td> - <td><a href="{{$cert.Link}}" title="{{$cert.Error}}">{{$cert.X509.Subject.CommonName | html}}</a></td> - <td><a href="{{$cert.Link}}" title="{{$cert.Error}}">{{$cert.Socket | html}}</a></td> + <td style="background-color: {{$cert.X509.NotBefore | green}}"><a href="{{$cert.Url}}" title="{{$cert.Error}}">{{$cert.X509.NotBefore.Local.Format "2006-01-02"}}</a></td> + <td style="background-color: {{$cert.X509.NotAfter | red }}"><a href="{{$cert.Url}}" title="{{$cert.Error}}">{{$cert.X509.NotAfter.Local.Format "2006-01-02"}}</a></td> + <td><a href="{{$cert.Url}}" title="{{$cert.Error}}">{{$cert.X509.Subject.CommonName | html}}</a></td> + <td><a href="{{$cert.Url}}" title="{{$cert.Error}}">{{$cert.Socket | html}}</a></td> </tr> {{end}} </table> @@ -168,7 +168,7 @@ type Cert struct { X509 *x509.Certificate } -func (cert Cert) Link() string { +func (cert Cert) Url() string { return fmt.Sprintf("https://crt.sh/?serial=%036x", cert.X509.SerialNumber) } |