Skip to content

Commit e1c31e2

Browse files
authored
Document Certificate Transparency logs enumeration with Go
1 parent 58ef0ce commit e1c31e2

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

Threat_Intel.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -572,3 +572,33 @@ fi
572572
```sh
573573
curl -s -H "Accept: application/json" "https://grep.app/api/search?q=-----BEGIN+RSA+PRIVATE+KEY-----" | jq '.'
574574
```
575+
576+
## Certificate Transparency Logs Enumeration with Go
577+
578+
Certificate Transparency (CT) logs are publicly accessible repositories that record all SSL/TLS certificates issued by Certificate Authorities. These logs make it possible to monitor certificate issuance, detect misissued certificates, and discover subdomains and services associated with a target domain.
579+
580+
A popular way to search these logs is via [crt.sh](https://crt.sh), which provides a web interface and API for querying certificate records. For programmatic access in Go applications, the [go-crtsh](https://github.com/The-Infra-Company/go-crtsh) library offers a convenient wrapper around the crt.sh API:
581+
582+
```go
583+
package main
584+
585+
import (
586+
"context"
587+
"fmt"
588+
"log"
589+
590+
gocrtsh "github.com/The-Infra-Company/go-crtsh"
591+
)
592+
593+
func main() {
594+
client := gocrtsh.New()
595+
ctx := context.Background()
596+
597+
records, err := client.BasicSearch(ctx, "target.com")
598+
if err != nil {
599+
log.Fatal(err)
600+
}
601+
602+
fmt.Printf("Found %d certificates for target.com\n", len(records))
603+
}
604+
```

0 commit comments

Comments
 (0)