Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proof of concept #2

Closed
campadrenalin opened this issue May 3, 2013 · 2 comments
Closed

Proof of concept #2

campadrenalin opened this issue May 3, 2013 · 2 comments

Comments

@campadrenalin
Copy link
Owner

Serve static content from local files as DNS data.

@campadrenalin
Copy link
Owner Author

The tricky bit is the JSON representation format, which I'd like to nail down (at least in a basic sense) for POC. It's more of a standard API of sorts, allowing for flexibility of metadata.

The standard

Every DJDNS document must contain a resource of type "direct/json" and path "/djdns-branch". The contents of the top-level map must contain the following keys according to specifications. Other keys may be present, they will simply be ignored for DJDNS purposes.

branches

The first required property is "branches", which is a list of branches, using list order to infer priority (first = highest, perfect for traversal).

branch

Each branch is an mapping with the following properties:

  • selector : String containing a match regex. May contain capture groups.
  • targets : A list of URI targets this branch points to.
  • records : A list of pymads-style record data objects.

Targets support the following pseudoprotocols:

  • "deje://987979fd89a789" - Points to DEJE object as a DJDNS document.
  • "dns://8.9.10.11" - defers responsibility to DNS server.

The correct behavior of the server is to check if "records" has items in it, return them all via DNS if so, and otherwise recurse through the targets (in whatever order the server feels like) until it finds a matching branch with records.

reverse

Reserved. Will be a very branches-like approach to reverse DNS.

meta

Human-readable metadata about this DJDNS document.

  • authority - String, possibly a URI, describing who has authority over the contents of this document.
  • contact - Array of contact objects, which may be arbitrary strings, or a TBD JSONic version of the vCard specification.
  • about - String, arbitrary information about the document. Optional.
  • policy - String, arbitrary information about how to request a change to this document. Optional.

@campadrenalin
Copy link
Owner Author

For the purpose of the POC, I'm just going to implement a very simplistic branch traversal system.

campadrenalin added a commit that referenced this issue May 19, 2013
campadrenalin added a commit that referenced this issue May 19, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant