Weboberfläche (erste Version) mit Anmeldung per Passwort zum Testen
- SPA unter /omega/ ohne Bibliotheken; HTML, CSS, JS und IBM-Plex-Schriften eingebettet, Content-Security-Policy nur für den Proxy selbst - Browser auf / werden nach /omega/ umgeleitet, Ollama-Clients nicht - Anmeldung mit Passwort (Argon2) nur mit ui.password_login; Sitzung im HttpOnly-Cookie (SameSite=Strict), Änderungen nur mit X-Omega-CSRF - Seiten nach den Mockups: Übersicht, API-Keys mit Aufzeichnung, Konto, Gruppen & Kontingente, Sparks & Modelle, Zeitplan, Benutzer, Audit-Log, öffentliches Dashboard - tests/multispark/demo.sh (admin, dozent, student; Passwort 1234), ui_test.py Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2c66f7fd0d
commit
7aeb6f9d44
25 files changed
+1581
-6
No files matched your search
@@ -429,6 +429,18 @@ impl<'a> Service<'a> {
|
||||
self.user(username)
|
||||
}
|
||||
|
||||
/// Passwort setzen: Administratoren für alle, sonst nur das eigene
|
||||
pub fn set_password(&self, username: &str, password: &str) -> Result<()> {
|
||||
if self.actor.role() < Role::Admin && self.who() != username {
|
||||
return Err(forbidden("nur das eigene Passwort, außer als Administrator"));
|
||||
}
|
||||
if password.chars().count() < 4 {
|
||||
return Err(invalid("das Passwort braucht mindestens 4 Zeichen"));
|
||||
}
|
||||
self.user(username)?;
|
||||
self.db.set_password(self.who(), username, password)
|
||||
}
|
||||
|
||||
// Gruppen (Lecturer)
|
||||
|
||||
pub fn create_group(&self, name: &str) -> Result<Group> {
|
||||
|
||||
Reference in new issue
Block a user