Switch from HTTP basic auth to MCIAS

Replace HTTP basic auth with MCIAS session cookies. Adds mcdsl auth,
csrf, and web packages. Chi router for route-level auth middleware.
Short code redirects (GET /{short}) remain public; all management
pages require MCIAS login. Nord dark theme, layout+page template
pattern matching other platform services.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-03-28 18:13:44 -07:00
parent d3c174d9b0
commit 9db3883706
11 changed files with 513 additions and 107 deletions

27
templates/list.html Normal file
View File

@@ -0,0 +1,27 @@
{{define "title"}} — All Links{{end}}
{{define "content"}}
<h2>All Links</h2>
<p><a href="/">Shorten a URL</a></p>
{{if .URLs}}
<table>
<thead>
<tr>
<th>Short</th>
<th>URL</th>
<th>Created</th>
</tr>
</thead>
<tbody>
{{range .URLs}}
<tr>
<td><a href="/{{.Short}}">{{.Short}}</a></td>
<td><a href="{{.URL}}">{{.NURL}}</a></td>
<td>{{.Timestamp}}</td>
</tr>
{{end}}
</tbody>
</table>
{{else}}
<p>No links yet.</p>
{{end}}
{{end}}