| Age | Commit message (Collapse) | Author |
|
The telemetry collect the Go runtime/metrics and forward it to questdb
instance in localhost.
|
|
The latest share module has several fixes and enhancements regarding
DNS library, including
* lib/dns: simplify unpackDomainName return value for end
* lib/dns: use the packet length to derive current offset
* lib/dns: handle zone file with CRLF line ending
* lib/dns: allow parsing TXT rdata without quote in zone file
* lib/dns: fix parsing SRV record from zone file
* lib/dns: fix packing and unpacking resource record HINFO
* lib/dns: fix packing, parsing, and saving MINFO resource data
|
|
|
|
|
|
This changes affect the dns Server where all caches related methods has
been moved to field Caches.
|
|
This also allow the latest/released documentation viewed on
the web user interface under /doc path.
While at it, reformat HTML and CSS files using js-beautify and
JavaScript files using clang-format [1].
[1] https://google.github.io/styleguide/jsguide.html#formatting
|
|
345ee16 lib/dns: return the removed record on caches RemoveCachesByRR
a44f87f lib/dns: disable JSON marshaling Zone Records field
3f8e9c6 lib/dns: print the field Value on ResourceRecord Stringer instead
of rdlen
|
|
The latest changes on share module changes type Zone.SOA field type,
which affect the zone.d page.
|
|
The command has the following signature,
resolver hosts.d rr delete <name> <domain>
Given the hosts name "hosts" and domain "my.hosts" it will delete
all records that have domain name "my.hosts" inside the file.
|
|
This changes add new directory called "block.d" under rescached.
This directory contains hosts file fetched from URL defined in hosts
block configuration.
In this way, we did not mixed between user created hosts file and
external hosts file.
In the configuration file, we changes the hosts block format from
single line
hosts_block = <URL>
into subsection with dynamic name,
[block.d "<name>"]
name = <name>
url = <URL>
|
|
On the HTTP side, if the query parameter "name" for "DELETE /api/caches"
is "all" it will remove all caches.
On the resolver side, if the parameter for "caches remove" is "all"
it will remove all caches.
This changes require latest lib/dns on share module.
|
|
The "caches" command accept second sub command "remove" that accept
single domain name to be removed from caches.
This changes affect the HTTP API for caches delete to return the removed
answer on the response data.
|
|
|
|
The latest share module move the Watcher and DirWatcher from package io
to package memfs, also it simplify watching files on existing MemFS
instance using method Watch.
|
|
See https://kilabit.info/journal/2022/gpl/ for more information.
|
|
|
|
Changes,
* lib/memfs: skip mount if the Root node has been initialized
* lib/http: remove field memfs.Options in ServerOptions
|
|
Previously, the options for HTTP server initialized internally, which
make it uneasy to changes the default rescached instance when running
in development mode.
This commit move the HTTP server initialization inside the Environment
init method. If its nil, the init will set the default HTTP server
options along with the Memfs.
|
|
The latest share module remove the ContentEncoding from memfs
EmbedOptions.
This option turns out break the HTTP content negotiation [1] of
accept-encoding header, if the HTTP server does not handle it properly,
like in default Go HTTP server that we use on rescached server.
Update #10.
[1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_negotiation
|
|
This changes update the code based on refactoring on lib/dns package
on share module.
|
|
The update bring new features and enhancements for DNS server.
* add support to save and load caches to/from storage
rescached now able to save and load caches to local storage upon
restart.
On POSIX, the caches is stored in /var/cache/rescached/rescached.gob,
encoded using gob.
Update #9
* remove the fallback name servers (NS) from server options
The original idea of fallback NS is to send the query to the one
define in resolv.conf, instead of using the one defined by user in
ServerOptions NameServers, when an error occured.
But, most of error usually caused by network (disconnected, time out),
so re-sending query to fallback NS does not have any effect if the
network it self is not working.
This changes remove the unnecessary and complex fallback NS from
server.
* do not cache truncated answer
Previously only answer with non-zero response code is ignored.
This changes ignore also answer where response header is truncated.
* lib/dns: make the TCP forwarders as complementary of UDP
The TCP forwarders only active when client send the DNS request as TCP.
When the server receive that request it should also forward the request
as TCP not as UDP to prevent the truncated response.
Another use case for TCP is when the response is truncated, the client
will send the query back through TCP connection. The server should
forward this request using TCP instead of UDP.
|
|
|
|
Changes affected by update,
* lib/http: changes on Endpoint.Call function signature
* lib/http: changes on CORS configuration
* lib/test: changes on the Assert function signature
|
|
== New features
Rescached now have a web user interface (wui) that can be accessed at
http://127.0.0.1:5380.
The interface can be used to monitoring caches, managing caches, environment,
blocked hosts, internal hosts files, and zone files.
== Breaking changes
* The `rescached::dir.hosts` now default to "/etc/rescached/hosts.d"
* The `rescached::dir.master` now default to "/etc/rescached/zone.d"
|
|
When user open the rescached web interface, the front page will
render and refresh the list of non-local caches per 10 seconds.
|
|
|
|
This changes affect how the memfs.New and GoGenenerate called, does not
affect the user.
|
|
While at it, add more DNS RR types for displaying in the dashboard.
|
|
* Add function to search and remove non-local caches
* Refactoring no how to create and remove record from hosts file
|
|
* Trim dot "." suffix on RR.Name before creating new one
* Decrease the notification from default (5 seconds) to 3 seconds
* Use the phrase "zone file" instead of "master file"
* Update the SOA fields information to be less technical.
|
|
Previously, the fields to create new record is name, type, and value.
This commit move the type field to the top so when the type changes,
the fields below it also changes according to its type.
This is to simplify the field format for PTR record.
|
|
Since each zone file only allow one SOA record, the form for creating,
updating, or deleting the SOA record should be separated from others
resource record.
|
|
Fix hostname not converted to lowercase when parsing hosts files.
|
|
Add second parameter to method PopulateCachesByXxx for clearity.
|
|
|
|
Fix multiple empty lines generated when environment saved on file.
|
|
While at it,
* update code with latest dns library
* check for empty name servers when updating environment
|
|
|
|
Currently, it allow user to add or remove new resource record from the
master zone file.
|
|
The UI will update (insert or remove) the records on cache on the fly.
|
|
|
|
To be able to edit the hosts or master file through web UI, we need to
store it some where. This changes is premilinary commit before we add
the actual UI to edit hosts file.
|
|
This is the first web UI (wui) where user can change configuration on
the fly.
The wui is implemented using svelte.dev and can be accessed on
http://127.0.0.1:5380.
|
|
This cause package is unbuildable using normal go get or clone.
Fix #6.
|
|
|
|
|
|
The latest dns.Server now replace Start and Wait with ListenAndServe()
|
|
|
|
|
|
|