skx / dhcp.io Goto Github PK
View Code? Open in Web Editor NEWDynamic DNS - Via Redis, Perl, and Amazon Route53.
License: Other
Dynamic DNS - Via Redis, Perl, and Amazon Route53.
License: Other
Allow updates to be logged.
As per feedback from joet3ch
Once you've claimed a sub-domain you cannot release it, or delete it.
You can delete the existing IP which is associated with the name, if any, though.
Homepage links to steve.org.uk. I'm now using steve/kemp.fi since I live in Finland.
At the moment:
UPSERT
.At the moment the site looks pretty dated, and terrible.
Move over to a similar layout to that used in the commercial site - i.e. Use bootstrap and hope for the best.
The password-reset process is ugly and can be improved via more bootstrap.
Currently there are two ways to change the value of a record:
bin/set-name
.curl
.It might be nice to add an Edit Record
page. I've added a stub link in the live version - repository is out of date - but it is a NOP.
Seems the docker-container doesn't have sendmail installed/configured.
Currently we pull the complete zone out, to get the most current records, for the /edit/
operation.
By contrast at /home/
we just use Net::DNS
. At the time I considered this too expensive to lookup constantly, but Net::DNS
isn't responsive enough.
Suggestion:
Net::DNS
.DHCP::Records
to cache, in Redis, the return value of getRecords
- with TTL of 60 seconds.Invalidate on hits to /edit/
+ /set
obviously. (Or wait for cache to expire via TTL, if the cache-time is the same as the zone..?)
There is no ability to delete a user-account from the web-interface.
The site-admin can use bin/delete-user --username=foo
to delete a user, and their associated records, manually though.
sigh
It would be nice to be able to set IPv4 and IPv6 addresses for a record in one call.
This cannot be done unless both are specified though, because if no address is specified then the source is used - clearly a request may arrive at the dhcp.io host on either IPv4 or IPv6 but not both a once.
If we restrict ourselves to the case where both addresses are specified then it becomes a simple enough job. Something like :
curl http://dhcp.io/set/$token/$ipv4/$ipv6
Or via the post:
curl -X POST -data 'token=xx&ip4=1.2.3.4&ipv6=fe80::1'
The only thing to note is that we need to handle the case where the endpoint might receive only one argument, ip
, as is currently the case. That means to set both they must be named appropriately (i.e. ipv4
+ ipv6
.)
Shouldn't be a big change, but no rush ..
The profile page shows the following fields which are directly editable:
Rather than allowing these to be edited in-place we should make the profile page just show the details, and add two new routes for making changes:
The specific problem we're trying to solve is twofold:
This might involve a world of pain - but should we allow users to set an MX record too?
Again this is easy for a free v.s. paid discussion. Free users can have an A/AAAA record, but you must pay for MX.
Since we're not really going down that path ..
This is regression, but if there is no value set for a given name you cannot edit it.
e.g. Create a new record foo.dhcp.io
and it will be empty. After you run a curl command to set (any) value you can then edit it. But until then it is impossible.
As per the comments on #17
The deployed code uses hashed passwords - this repository is a little out of date.
If a user forgets their password and has a registered email address we should allow a reset operation.
If the user has no registered email address they are out of luck. Or must mail me.
A common request is the support for sub-records.
For example rather than restricting names to things such as skx.dhcp.io
, me.dhcp.io
users would like the ability to have names of the form:
gateway.office.dhcp.io
.printer.office.dhcp.io
.I won't add this support, and explicitly do not support sub-records.
Pull requests implementing this will be accepted providing the behaviour can be disabled via the configuration file lib/DHCP/Config.pm[.example]
.
(This issue just created for reference.)
Assume you have the user-account "skx", which has the following records:
deagol
smeagol
shelob
(Manually) edit the records for shelob
, and it is logged deagol
. Suspect this is an artefact of earlier releases where a single account was available - which in this case would be skx
.
As a result of #14 we no longer fetch the current value(s) of the complete hosted zone from Amazon.
Because we don't fetch the complete zone we no longer cache it in memory.
This means we can drop some of the redis-usage, as it is orphaned.
NOTE: We still use redis, we just use it for rate-limiting/throttling, and for storing transient password-reset tokens, etc. So while we can remove it in some places it does continue to be necessary (and awesome)!
That makes it hard, but not impossible, to set an IPv6 address to a specific value.
It can be done with curl, but it's only documented via the source-code.
(The record was dropped, but I didn't appreciate that would cause breakage. Dropped because the docker setup wasn't working with IPv6 at the time I handled the migration and I forgot to track it as a TODO)
A twitter user reports that logs aren't showing updates some/all of the time.
Secondly they say that they "can't connect". There are no details on that, so I assume that means the dynamic hostname they've set isn't reachable - that would be outside the scope of this issue and code.
It might be the case that we want to allow users to have more than one name.
If so that requires a redesign of the home-page - perhaps a dropdown that will change the text in the home panel.
Alternatively we could use a tab-interface running across the top, with one tab for each name.
Implementation of either would be simple. I just need to decide whether it should be supported or not.
Were this commercial it would be easy to say "One domain for free, if you want more pay". Though I guess the obvious concern would be people registering N-accounts..
We're moving to a situation where several users are going to need to be updated because their details are wrong, and we can't contact them.
Suggest we create:
All the records owned by bogus users will be remapped into CNAME records pointing to that, unless/until they update themselves. If they never update themselves we can delete the accounts after a month or two.
We don't expect a compromise, but using something better is absolutely 100% essential.
This will buy us per-user salting, and if we ever are compromised that'll reduce the risk of exposure.
The login form is ugly and can be improved.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.