diff options
| author | Shulhan <ms@kilabit.info> | 2022-06-12 12:28:21 +0700 |
|---|---|---|
| committer | Shulhan <ms@kilabit.info> | 2022-06-12 13:02:22 +0700 |
| commit | dbbf768254182ad12be3ecedf61685f8e18201a3 (patch) | |
| tree | a909984a6af151ef3e68804f2932ce09a2883f53 | |
| parent | b76e182e94f55ce542ba336ea35bcb108e924c3f (diff) | |
| download | rescached-dbbf768254182ad12be3ecedf61685f8e18201a3.tar.xz | |
all: trim the zone's name from request on HTTP API zone.d record delete
When calling API for zone.d record delete, client send the fully
qualified domain name on record to be deleted, but caches store only
the subdomains internally.
This cause the delete action fail, because no internal record match
with request.
| -rw-r--r-- | httpd.go | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -1498,6 +1498,7 @@ func (srv *Server) apiZonedRRDelete(epr *libhttp.EndpointRequest) (resbody []byt } rr.Name = strings.TrimRight(rr.Name, ".") + rr.Name = strings.TrimRight(rr.Name, zone.Name) if rr.Type == dns.RecordTypePTR { if len(rr.Name) == 0 { |
