Commit Graph

13 Commits

Author SHA1 Message Date
Paul Lindner b09cd377d7 Switch to stdlib context from golang.org/x/net/context
This switches most usages of the pre-1.7 context library to use the
standard library.  Remaining usages are in:

  app/publisher/main.go
  pkg/fs/...

Change-Id: Ia74acc39499dcb39892342a2c9a2776537cf49f1
2017-11-26 01:12:26 -08:00
mpl 7f59a27060 website: run on staging instance
Add the -staging flag to camweb so one can deploy on a staging
instance.
The instance name is then "camweb-staging" instead of "camweb", and its
hostname is "staging.camlistore.net", instead of "camlistore.org".

server/camnetdns: automatically and regularly discovers the IP of the
"camweb-staging" instance, so it can keep the record for
"staging.camlistore.net" up to date.

Change-Id: I7d64a774049ac01472666ee7e351fd6fb5e4c287
2017-01-24 15:34:37 +01:00
mpl b0eefd74fa server/camnetdns: get certificate from Lets Encrypt
Change-Id: Icd67eca36a153fe142d07b39df9ace6ef8301992
2016-12-17 23:38:40 +01:00
mpl 9a32570a48 server/camnetdns: persist records in datastore
Store records in Google Datastore in production (on GCE), with an LRU
cache in front.

Keep dev mode that stores in sorted mem key value though.

Change-Id: I17b088b56a68a019f4e253b60c6bd42395a64984
2016-12-16 00:36:08 +01:00
mpl 0ab95c3f13 server/camnetdns: reply with NXDOMAIN when needed
When we get a query for a name we are authoritative about, we should
reply with NXDOMAIN when this name does not exist.

This change moves the name lookup to as early as possible to make sure
of that. This means we're now doing lookups even for cases where we
technically wouldn't have needed them, so maybe a substantial increase
in load? We'll see.

Change-Id: I5e9946dd67757856f626f484b547197c6246cccd
2016-10-21 19:14:35 +02:00
mpl 0273e6c5f5 server/camnetdns: implement more of the DNS protocol
As Let's Encrypt DNS server (Unbound) is pretty strict, it
wouldn't resolve names camlistore.net until we implemented more of the
DNS protocol and fix various things.

Since I had no way at first to know what exactly it didn't like, I
started by fixing all errors and warnings reported at:
http://dnsviz.net/d/camlistore.net/dnssec/

Therefore, this CL adds:
-TCP support
-NS response
-SOA response
-MX (empty) response
-DNSKEY (empty) response
-TXT (empty) response
-explicit non-support of EDNS

Then I found out we also needed this:

-https://tools.ietf.org/html/draft-vixie-dnsext-dns0x20-00
-CAA response. A proper response is optional here, as Let's Encrypt only
enforces the response if it finds one. But we do have to reply.

Fixes #867

Change-Id: Ib45f8a642cd83cf19c8ab36435644a2c645a70e7
2016-10-20 17:53:11 +02:00
mpl 39a33c7fa9 server/camnetdns: make it work
Before that change, one would only get a response to a DNS query, if
directly sending the query to the dns server.

I think the main problem was that one has to copy the question section
of the query in the response message, which is part of what SetReply
does.

With this change, I seem to get responses (for e.g. www.camlistore.net
and 6401800c.camlistore.net), without having to specify a server to
query to dig (or nslookup), so by letting the resolver and the DNS
hierarchy follow its normal course.

Issue #722

Change-Id: I530529920fdaa3e5fb025c7684b563e3f05772ac
2016-10-06 16:26:18 +02:00
mpl 2c4332ada2 make.go: optionally build camnetdns
server/camnetdns: update to cloud.google.com/go imports.

vendor: add github.com/miekg/dns at rev
3f1f7c8ec9ead89493df11f2c3d8bec353a2c2c0 as a dep of server/camnetdns

Change-Id: Ief8e0ad3e09a6c3511c72a7991309808f855d3df
2016-10-04 01:58:50 +02:00
Jeromy 444b2a81f3 server/camnetdns: set authority flag on dns response
Updates #722

Change-Id: I18277a0181234e9a9e497100a5f86613fca2dba4
2016-04-25 18:07:52 -07:00
Jeromy d77d4b8b51 server/camnetdns: log all incoming requests
Updates #722

Change-Id: Ief6b172d8ec4e62f22332a117f379ea4998a3f76
2016-04-25 16:53:50 -07:00
Jeromy e53f91085b server/camnetdns: default to port 53 on gce
Updates #722

Change-Id: I4d435634b6c78a4d4d1392616870d50f0c458e5c
2016-04-25 16:38:04 -07:00
Jeromy 4841ce270f server/camnetdns: add cloudlaunch config
Updates #722

Change-Id: Ia7532118183b5c38dfedc3aaa437f5284301b4c9
2016-04-25 16:26:26 -07:00
Jeromy 21c5373a0b server/camnetdns: start of camlistore.net DNS server
Updates #722

Change-Id: Ie4c2d6d036f13d7fb6f5545131397f55d1d9a91c
2016-04-25 16:05:25 -07:00