diff --git a/src/components/account/ChangeToPassword.vue b/src/components/account/ChangeToPassword.vue new file mode 100644 index 0000000..86b7c8e --- /dev/null +++ b/src/components/account/ChangeToPassword.vue @@ -0,0 +1,106 @@ + + + + + diff --git a/src/components/account/ChangeToTOTP.vue b/src/components/account/ChangeToTOTP.vue new file mode 100644 index 0000000..c04197c --- /dev/null +++ b/src/components/account/ChangeToTOTP.vue @@ -0,0 +1,92 @@ + + + + + diff --git a/src/components/account/PasswordChange.vue b/src/components/account/PasswordChange.vue new file mode 100644 index 0000000..268e5bc --- /dev/null +++ b/src/components/account/PasswordChange.vue @@ -0,0 +1,109 @@ + + + + + diff --git a/src/components/account/TotpCheckAndScan.vue b/src/components/account/TotpCheckAndScan.vue new file mode 100644 index 0000000..a9ba5ef --- /dev/null +++ b/src/components/account/TotpCheckAndScan.vue @@ -0,0 +1,83 @@ + + + + + diff --git a/src/helpers/crypto.ts b/src/helpers/crypto.ts new file mode 100644 index 0000000..06b32cf --- /dev/null +++ b/src/helpers/crypto.ts @@ -0,0 +1,7 @@ +export async function hashString(message = ""): Promise { + const msgUint8 = new TextEncoder().encode(message); + const hashBuffer = await window.crypto.subtle.digest("SHA-256", msgUint8); + const hashArray = Array.from(new Uint8Array(hashBuffer)); + const hashHex = hashArray.map((b) => b.toString(16).padStart(2, "0")).join(""); + return hashHex; +} diff --git a/src/views/Login.vue b/src/views/Login.vue index 2ad96f7..6ef5c6b 100644 --- a/src/views/Login.vue +++ b/src/views/Login.vue @@ -8,13 +8,28 @@ -
+
-
- -
-
+
+
+ + + +
+
+
+ +
- TOTP verloren +

+ Benutzer wechseln +

+ Zugang verloren
@@ -53,6 +81,7 @@ import FormBottomBar from "@/components/FormBottomBar.vue"; import AppLogo from "@/components/AppLogo.vue"; import { mapState } from "pinia"; import { useConfigurationStore } from "@/stores/configuration"; +import { hashString } from "../helpers/crypto"; diff --git a/src/views/invite/Verify.vue b/src/views/invite/Verify.vue index f2cbed2..0547f3f 100644 --- a/src/views/invite/Verify.vue +++ b/src/views/invite/Verify.vue @@ -14,17 +14,62 @@

Einladungslink nicht gültig - Melde dich bei einem Admin.

+
+

+ TOTP +

+

+ Passwort +

+

Dein Nutzername: {{ username }}

- totp +
+ totp - + -
-
- +
+
+ +
+
+ + +

Passwörter stimmen nicht überein

+