iter-17: DNSSEC, wildcard certs, and DNS record scans#26
Conversation
Adds DNSSEC enable/disable/status, wildcard TLS certificate issuance, and async DNS record discovery scans to the DNS service. Hand-written API clients in `bunny-api-core` and corresponding `hoppy dns zone …` CLI subcommands, with wiremock + insta tests and live-API E2E lifecycles. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
Warning Rate limit exceeded
To unlock additional reviews, purchase usage credits in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Free Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThis PR extends the Bunny DNS API client and CLI with three new capabilities: DNSSEC management (enable/disable/status), free wildcard TLS certificate issuance, and DNS record discovery scanning. New API client methods wire the endpoints; CLI commands expose them with JSON or table output; and full E2E test coverage validates the flows. ChangesDNS Security and Discovery Features
🎯 3 (Moderate) | ⏱️ ~25 minutes
Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
There was a problem hiding this comment.
Pull request overview
Adds new DNS security and migration features to Hoppy’s DNS surface area, spanning the bunny-api-core client, CLI subcommands, fixtures, and test coverage.
Changes:
- Implement DNSSEC enable/disable/status in
bunny-api-coreand expose viahoppy dns zone dnssec ..., including DS record display on enable. - Add wildcard certificate issuance (
hoppy dns zone issue-cert) backed by a new core client endpoint. - Add async DNS record discovery scans (trigger + results) with new types, fixtures, and wiremock/E2E coverage.
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| tests/e2e/cli_dns.rs | Adds CLI E2E coverage for DNSSEC, wildcard cert issuance, and scan trigger/results (plus live-api lifecycle tests). |
| src/commands/dns.rs | Implements new DNSSEC, wildcard cert, and scan handlers/output formatting in the CLI command layer. |
| src/cli.rs | Adds new clap subcommands/args for dnssec, issue-cert, and scan start/results. |
| README.md | Documents new DNS subcommands and capabilities. |
| hoppy-knowledgebase/iterations/iteration-17-dns-security.md | Updates iteration status and marks tasks complete. |
| fixtures/core/dnszone_scan_trigger.json | Adds fixture for scan trigger response. |
| fixtures/core/dnszone_scan_result.json | Adds fixture for scan results response. |
| fixtures/core/dnssec_enable.json | Adds fixture for DNSSEC enable response. |
| fixtures/core/dnssec_disable.json | Adds fixture for DNSSEC disable response. |
| crates/bunny-api-core/tests/e2e/dns_api.rs | Adds wiremock tests for DNSSEC, wildcard cert issuance, and record scan endpoints. |
| crates/bunny-api-core/src/types.rs | Introduces new DNSSEC + scan request/response types and enums. |
| crates/bunny-api-core/src/lib.rs | Re-exports newly added DNSSEC/scan types from the crate root. |
| crates/bunny-api-core/src/client.rs | Adds core client methods for DNSSEC, wildcard cert issuance, and scan trigger/results. |
| let json = serde_json::to_string_pretty(ds).expect("failed to serialize to JSON"); | ||
| println!("{json}"); |
- Enforce one-of --id/--domain at parse time via clap ArgGroup - Propagate JSON serialization errors from print_dnssec (no panic) - Fix wildcard cert doc to correctly reference DNS-01 only - Clarify DnsDiscoveredRecordType numbering doc Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Summary
bunny-api-coreandhoppy dns zone dnssecsubcommands. Enable returns the DS record details users need to copy to their domain registrar; disable warns about resolution breakage and prompts for confirmation (--yesto skip).POST /dnszone/{id}/certificate/issueandhoppy dns zone issue-cert --id <zone-id>.POST /dnszone/records/scan(accepts eitherzone_idordomain) plusGET /dnszone/{zoneId}/records/scan. CLI exposes them ashoppy dns zone scan startandhoppy dns zone scan results(option (a) from the iteration plan — separate trigger and fetch, matching the API shape).DnsSecDsRecord,DnsScanJobStatus,DnsDiscoveredRecordType,DnsDiscoveredRecord,DnsRecordScanTrigger,DnsRecordScanResult,TriggerDnsRecordScan. Fixtures and wiremock+insta tests added.in-progress.Test plan
cargo fmt --allcleancargo clippy --workspace --all-targets -- -D warningscleancargo test --workspace --quietall green (new wiremock tests cover DNSSEC enable/disable/404, cert issue success/404, scan trigger by zone-id and by domain, scan results with three discovered records)dnssec enabletable mode and thescan startarg-validation pathlive_dns_zone_dnssec_lifecycle,live_dns_zone_record_scan_lifecycle) — gated behind--features live-api; require a real bunny.net account🤖 Generated with Claude Code
Summary by CodeRabbit
Release Notes
New Features
Documentation