Refactor some utils.go; add another tool 'tiledump'

This commit is contained in:
2026-01-11 07:12:48 +01:00
parent 25d07030d5
commit 1633ad52c9
5 changed files with 216 additions and 108 deletions

View File

@@ -1,20 +1,25 @@
# ctfetch
Fetch and dump leaf entries from Certificate Transparency logs.
Tools for working with Certificate Transparency log tiles.
## Install
```bash
go install ./cmd/ctfetch
go install ./cmd/tiledump
```
## Usage
## Commands
### ctfetch
Fetch and dump leaf entries from CT logs.
```bash
ctfetch [--dumpall] <log-url> <leaf-index>
```
### Examples
**Examples:**
Dump a specific entry:
```bash
@@ -26,6 +31,25 @@ Dump all entries in the tile:
ctfetch --dumpall https://halloumi2026h1.mon.ct.ipng.ch 629794635
```
## Options
**Options:**
- `--dumpall`: Dump all entries in the tile instead of just the specified leaf
### tiledump
Read a CT log tile file or URL and dump all entries.
```bash
tiledump <tile-file-or-url>
```
**Examples:**
From a file:
```bash
tiledump tile.data
```
From a URL:
```bash
tiledump https://halloumi2026h1.mon.ct.ipng.ch/tile/data/x002/x460/135
```