1
0
mirror of https://git.sr.ht/~adnano/go-gemini synced 2024-11-23 12:42:13 +01:00
Commit Graph

83 Commits

Author SHA1 Message Date
adnano
1c89de359c Clarify comment 2020-09-27 22:13:50 -04:00
adnano
4197d51545 Split Redirect into two functions 2020-09-27 22:06:08 -04:00
adnano
148910dade Use helper functions throughout 2020-09-27 22:03:09 -04:00
adnano
c9d03a516d Add SetMimetype convenience function 2020-09-27 21:53:58 -04:00
adnano
c25a128d2e Fix README.md 2020-09-27 21:40:51 -04:00
adnano
304e543637 Check certificate notBefore and notAfter times 2020-09-27 21:37:10 -04:00
adnano
fe1ad28e20 Trim trailing slash from Handler patterns 2020-09-27 21:24:08 -04:00
adnano
a645b03db4 Move package documentation comment 2020-09-27 21:19:34 -04:00
adnano
f1e8b251fe Add more helper functions 2020-09-27 21:13:42 -04:00
adnano
e1a1685f0f Add helper functions 2020-09-27 20:52:24 -04:00
adnano
ac2bf90699 Rename NewProxyRequest to NewRequestTo 2020-09-27 20:37:16 -04:00
adnano
934155feb7 examples/client: Handle relative redirects 2020-09-27 20:34:59 -04:00
adnano
14e569bf92 Change package name to gmi 2020-09-27 20:20:59 -04:00
adnano
8d483b084f Add helper handler functions 2020-09-27 20:11:45 -04:00
adnano
c548e8baa8 Reject invalid status codes 2020-09-27 19:56:33 -04:00
adnano
cafc19aed7 Polish example client 2020-09-27 19:45:48 -04:00
adnano
6ff6bd10df Update README.md 2020-09-27 17:44:49 -04:00
adnano
6f38db41e2 Add function to add a host temporarily 2020-09-27 17:41:41 -04:00
adnano
886e3ba8bb Add client authorization example 2020-09-27 17:39:44 -04:00
adnano
f23f6cb070 Fix README.md 2020-09-27 16:31:41 -04:00
adnano
8ea91e8f56 Update documentation 2020-09-27 16:21:56 -04:00
adnano
4e16af9b26 Make TrustCertificate accept hostname instead of request 2020-09-27 16:10:36 -04:00
adnano
a65334882b Fix hosts not being added to known hosts file 2020-09-27 16:06:17 -04:00
adnano
ef802cacca Temporarily allow common names in certificates 2020-09-27 15:57:55 -04:00
adnano
f19d3b09cd Don't store wildcards in the known hosts file 2020-09-27 15:03:46 -04:00
adnano
1640891c91 Remove port from host when verifying hostnames 2020-09-27 14:25:28 -04:00
adnano
e08ff3c709 Fix client example 2020-09-27 14:23:25 -04:00
adnano
f38da56732 Handle multiple DNS names
Each DNS name gets its own entry in the known hosts file
2020-09-27 14:22:41 -04:00
adnano
d7717577ea Add function to write known hosts to io.Writer 2020-09-27 14:18:30 -04:00
adnano
0a336f84e2 Implement certificate creation 2020-09-27 13:50:48 -04:00
adnano
f3345ae327 Adjust user prompt in client example 2020-09-26 18:56:10 -04:00
adnano
a44bbcb9f9 Reject requests containing '..' in them 2020-09-26 17:13:13 -04:00
adnano
54e76fab3f Implement default client 2020-09-26 16:52:14 -04:00
adnano
1288e1bc31 Implement file server 2020-09-26 16:38:26 -04:00
adnano
749b765aaa Add preliminary CertificateStore API 2020-09-26 15:14:34 -04:00
adnano
7aa139f8ce Update README.md 2020-09-26 14:34:15 -04:00
adnano
b0b5c011d3 Fix client example 2020-09-26 14:01:06 -04:00
adnano
82c374ea96 Update README.md 2020-09-26 13:59:24 -04:00
adnano
557d9b9615 Implement default known hosts path 2020-09-26 13:35:56 -04:00
adnano
a76535c921 Remove (*KnownHosts).Has function 2020-09-26 13:29:29 -04:00
adnano
6a5a7c40c5 Differentiate between unknown and untrusted certificates 2020-09-26 13:27:03 -04:00
adnano
1196c4013b Update README.md 2020-09-26 00:40:28 -04:00
adnano
886a92e54a Specify minimum version of TLS 1.2 2020-09-26 00:31:16 -04:00
adnano
47a6ce56f6 Fix misleading comment 2020-09-25 23:29:26 -04:00
adnano
5dae633597 Distinguish client errors from server errors 2020-09-25 23:23:24 -04:00
adnano
578746550e Refactor TOFU 2020-09-25 23:18:14 -04:00
adnano
134d0277f5 Implement basic TOFU 2020-09-25 21:43:13 -04:00
adnano
130312a1e0 Add KnownHost.Write function 2020-09-25 20:55:37 -04:00
adnano
39b55f4261 Fix known host expires check 2020-09-25 20:31:07 -04:00
adnano
f994f3dbd0 Add method to check if hostname is found in KnownHosts 2020-09-25 20:22:48 -04:00