Initial import: KeepNote service (dcntrlized-auth consumer)

This commit is contained in:
2026-08-14 23:35:38 +01:00
commit 77dfcaf64a
49 changed files with 2346 additions and 0 deletions
+23
View File
@@ -0,0 +1,23 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Index</title>
<script src="./cookies.js"></script>
<script src="./jwt.js"></script>
<script>
const token = cookieEater("accessToken");
let authed = false;
try {
if (token) {
const res = jwtDecode(token);
authed = new Date().valueOf() / 1000 < res.payload.exp;
}
} catch (e) { /* stale or malformed token */ }
window.location.replace(authed ? "./notes.html" : "./auth.html");
</script>
</head>
<body>
</body>
</html>