<!DOCTYPE html>
<html lang="de">
<head>
    <meta charset="UTF-8">
    <title>Login</title>
    <style>
        /* Allgemeine Einstellungen */
        body {
            font-family: Arial, sans-serif;
            background: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(139, 0, 0, 0.8)); /* Roter Farbverlauf */
            margin: 0;
            padding: 0;
            display: flex;
            justify-content: center;
            align-items: center;
            height: 100vh;
            backdrop-filter: blur(8px); /* Hintergrundunschärfe */
        }

        .container {
            width: 320px;
            margin: 0 auto;
            padding: 20px;
            background: rgba(5, 5, 5, 0.3); /* Halbtransparenter Hintergrund */
            border-radius: 35px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 60px rgba(5, 5, 5, 1); /* Verstärkter Weißer Glow */
            backdrop-filter: blur(60px); /* Weiche Unschärfe */
            transition: all 0.3s ease; /* Sanfter Übergang */
        }

        .container:hover {
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4), 0 0 20px rgba(255, 255, 255, 1); /* Stärkerer Schatten und Glow bei Hover */
        }

        .hidden {
            display: none;
        }

        /* Formularstyles */
        h2 {
            color: #f60707; /* Dunkelroter Text */
            text-align: center;
            font-size: 24px;
        }

        label {
            color: #333;
            font-size: 16px;
        }

        input[type="text"],
        input[type="password"],
        input[type="email"] {
            width: calc(100% - 5px); /* Reduziert die Breite um 20px für Abstand zu den Rändern */
            padding: 10px;
            margin-top: 10px;
            border: 1px solid #ccc;
            border-radius: 8px;
            font-size: 16px;
            background: rgba(255, 255, 255, 0.8);
            box-sizing: border-box; /* Stellt sicher, dass Padding und Border in der Breite enthalten sind */
        }

        input[type="submit"] {
            background-color: #800000; /* Dunkelrot */
            color: white;
            padding: 10px;
            border: none;
            border-radius: 8px;
            width: 100%;
            cursor: pointer;
            font-size: 16px;
            transition: background-color 0.3s;
        }

        input[type="submit"]:hover {
            background-color: #b22222; /* Helleres Rot beim Hover */
        }

        #hwid-section {
            margin-top: 20px;
            text-align: center;
        }

        button {
            background-color: #800000;
            color: white;
            border: none;
            padding: 10px 20px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 16px;
            transition: background-color 0.3s;
            width: 100%;
            margin-bottom: 10px;
        }

        button:hover {
            background-color: #b22222;
        }

        /* Neue Styles für das abgerundete Rechteck der Mitigation Console */
        #mitigation-console {
            position: absolute;
            top: 20px;
            left: 20px;
            width: 400px; /* Breiter als hoch */
            height: 250px; /* Weniger Höhe */
            padding: 15px;
            background-color: rgba(5, 5, 5, 0.3); /* Volle Sättigung, keine Transparenz */
            border-radius: 34px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 90px rgba(5, 5, 5, 1); /* Starker Schatten wie in der Mitte */
            backdrop-filter: blur(35px); /* Sehr starker Unschärfe-Effekt */
            overflow: auto; /* Scrollen ohne sichtbaren Scrollbalken */
            display: none; /* Standardmäßig verborgen */
        }


        /* Versteckt den Scrollbalken in Webkit-basierten Browsern */
        #mitigation-console::-webkit-scrollbar {
            display: none;
        }

        p {
            text-align: center;
        }

        /* Responsiveness */
        @media (max-width: 500px) {
            .container {
                width: 80%;
                padding: 15px;
            }
        }

        button {
            background-color: #800000; /* Dunkelrot */
            color: white;
            border: none;
            padding: 10px 20px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 16px;
            transition: background-color 0.3s;
            width: 100%;
            margin-bottom: 10px;
        }

        button:hover {
            background-color: #b22222; /* Helleres Rot beim Hover */
        }

        /* Zentrierung des Buttons im Dashboard */
        #dashboard .centered {
            display: flex;
            justify-content: center;
            align-items: center;
            margin-top: 20px;
            gap: 10px; /* Lücke zwischen den Buttons */
        }
        a {
            text-decoration: none; /* Entfernt die Standard-Unterstreichung */
        }

        button {
            background-color: #800000; /* Dunkelrot */
            color: white;
            border: none;
            padding: 10px 20px;
            border-radius: 8px;
            cursor: pointer;
            font-size: 16px;
            transition: background-color 0.3s;
            width: 100%;
            margin-bottom: 10px;
        }

        button:hover {
            background-color: #b22222; /* Helleres Rot beim Hover */
        }


        #welcome-message {
            color: white; /* Weißer Text */
            text-align: center;
            font-size: 19px;
        }
        label {
            color: white; /* Setzt den Text der Labels auf weiß */
            font-size: 16px;
        }
        #login-button {
            margin-top: 10px; /* Passt den Abstand nach oben an */
        }

    </style>
</head>
<body>


<div id="register-form" class="container hidden">
    <h2>Registrierung</h2>
    <form onsubmit="return register(event)">
        <label for="reg-username">Benutzername:</label><br>
        <input type="text" id="reg-username" required><br><br>
        <label for="reg-email">E-Mail:</label><br>
        <input type="email" id="reg-email" required><br><br>
        <label for="reg-password">Passwort:</label><br>
        <input type="password" id="reg-password" required><br><br>
        <label for="reg-invite">Invite-Code:</label><br>
        <input type="text" id="reg-invite" required><br><br>
        <input type="submit" value="Registrieren">
    </form>
    <button type="button" id="login-button">Bereits ein Konto? Einloggen</button>
</div>

<!-- Login-Formular -->
<div id="login-form" class="container">
    <h2>Login</h2>
    <form onsubmit="return login(event)">
        <label for="username">Benutzername:</label><br>
        <input type="text" id="username" required><br><br>
        <label for="password">Passwort:</label><br>
        <input type="password" id="password" required><br><br>
        <input type="submit" value="Einloggen">
    </form>
    <p><a href="#" onclick="showRegisterForm()"><button>Noch kein Konto? Jetzt registrieren!</button></a></p>
</div>

<!-- Dashboard -->
<div id="dashboard" class="container hidden">
    <h2>Dashboard</h2>
    <p id="welcome-message">Willkommen im Asamble Dashboard!</p>

    <!-- Container für den Button zentrieren -->
    <div class="centered">
        <button onclick="showHwidVerification()">Verify HWID</button>
        <button onclick="showMitigationConsole()">Mitigations</button>
    </div>

    <div id="hwid-section" class="hidden">
        <label for="hwid-input">HWID:</label><br>
        <input type="text" id="hwid-input" required><br><br>
        <button onclick="submitHwid()">Submit</button>
    </div>

    <p><a href="#" onclick="logout()"><button>Abmelden</button></a></p>
</div>

<!-- Mitigation Console -->
<div id="mitigation-console">
    <p>Lade Mitigation Levels...</p>
</div>

<script>
    let currentUsername = '';

    (function(_0x2885cf,_0x421a5f){const _0x4e4893=_0x43b1,_0xbd60dd=_0x2885cf();while(!![]){try{const _0x34f545=parseInt(_0x4e4893(0x14a))/0x1+-parseInt(_0x4e4893(0x14e))/0x2*(parseInt(_0x4e4893(0x132))/0x3)+parseInt(_0x4e4893(0x153))/0x4+parseInt(_0x4e4893(0x131))/0x5+-parseInt(_0x4e4893(0x123))/0x6*(parseInt(_0x4e4893(0x12b))/0x7)+parseInt(_0x4e4893(0x155))/0x8+-parseInt(_0x4e4893(0x129))/0x9;if(_0x34f545===_0x421a5f)break;else _0xbd60dd['push'](_0xbd60dd['shift']());}catch(_0x4d6343){_0xbd60dd['push'](_0xbd60dd['shift']());}}}(_0x26f3,0xda169));function loadMitigationLevels(){const _0x119c7a=_0x43b1;fetch(_0x119c7a(0x157),{'method':_0x119c7a(0x160),'headers':{'Content-Type':'application/json'}})[_0x119c7a(0x126)](_0x2af634=>{const _0x48a6eb=_0x119c7a;if(!_0x2af634['ok'])throw new Error(_0x48a6eb(0x12f)+_0x2af634[_0x48a6eb(0x140)]);return _0x2af634[_0x48a6eb(0x15a)]();})[_0x119c7a(0x126)](_0x4bec31=>{const _0xf97eaa=_0x119c7a,_0x4099b6=document[_0xf97eaa(0x127)](_0xf97eaa(0x12d));_0x4099b6[_0xf97eaa(0x15f)]='',_0x4bec31&&_0x4bec31[_0xf97eaa(0x15e)]>0x0?_0x4bec31[_0xf97eaa(0x138)](_0x240621=>{const _0x337d21=_0xf97eaa,_0x1e0d7e=document[_0x337d21(0x15d)]('p'),_0x414a5b=document[_0x337d21(0x15d)](_0x337d21(0x122));_0x414a5b[_0x337d21(0x147)]='Mitigation\x20for\x20:\x20',_0x414a5b[_0x337d21(0x159)][_0x337d21(0x12c)]='red';const _0x22a910=document[_0x337d21(0x15d)](_0x337d21(0x122));_0x22a910[_0x337d21(0x147)]=_0x240621[_0x337d21(0x145)],_0x22a910[_0x337d21(0x159)]['color']=_0x337d21(0x14c),_0x22a910['style'][_0x337d21(0x13a)]=_0x337d21(0x12e);const _0x141c10=document[_0x337d21(0x15d)]('span');_0x141c10[_0x337d21(0x147)]=_0x337d21(0x134)+_0x240621[_0x337d21(0x150)];switch(_0x240621['mitigationLevel'][_0x337d21(0x146)]()){case _0x337d21(0x142):_0x141c10[_0x337d21(0x159)][_0x337d21(0x12c)]=_0x337d21(0x148);break;case _0x337d21(0x133):_0x141c10['style'][_0x337d21(0x12c)]=_0x337d21(0x143);break;case _0x337d21(0x151):_0x141c10[_0x337d21(0x159)][_0x337d21(0x12c)]=_0x337d21(0x13e);break;default:_0x141c10['style'][_0x337d21(0x12c)]=_0x337d21(0x161);break;}_0x1e0d7e['appendChild'](_0x414a5b),_0x1e0d7e[_0x337d21(0x137)](_0x22a910),_0x1e0d7e[_0x337d21(0x137)](_0x141c10),_0x4099b6['appendChild'](_0x1e0d7e);}):_0x4099b6[_0xf97eaa(0x15f)]='<p>Keine\x20Mitigation\x20Levels\x20verfügbar.</p>';})[_0x119c7a(0x162)](_0x3a8609=>{const _0x51031d=_0x119c7a;console[_0x51031d(0x125)]('Fehler\x20beim\x20Abrufen\x20der\x20Mitigation\x20Levels:',_0x3a8609);const _0xbd3247=document[_0x51031d(0x127)](_0x51031d(0x12d));_0xbd3247['innerHTML']='<p>Fehler\x20beim\x20Abrufen\x20der\x20Mitigation\x20Levels:\x20'+_0x3a8609[_0x51031d(0x14b)]+_0x51031d(0x130);});}function showMitigationConsole(){const _0x345ba4=_0x43b1,_0x3a25f9=document['getElementById'](_0x345ba4(0x12d)),_0x1068b3=_0x3a25f9[_0x345ba4(0x159)][_0x345ba4(0x156)]===_0x345ba4(0x13c)||_0x3a25f9[_0x345ba4(0x159)][_0x345ba4(0x156)]==='';_0x3a25f9[_0x345ba4(0x159)]['display']=_0x1068b3?'block':_0x345ba4(0x13c),_0x1068b3&&loadMitigationLevels();}function _0x26f3(){const _0x1bfccd=['black','catch','span','114pFeIDc','hidden','error','then','getElementById','add','23714352PfMySs','dashboard','24920FqPMfn','color','mitigation-console','bold','HTTP-Error:\x20','</p>','3324820VbayfL','3QvNTxj','medium','\x20-\x20','toggle','Ungültiger\x20Benutzername\x20oder\x20Passwort','appendChild','forEach','POST','fontWeight','password','none','http://162.212.154.28:3567/verifyHwid','red','login-form','status','register-form','low','orange','application/json','username','toLowerCase','textContent','lightgreen','remove','1694553ejtPrp','message','white','stringify','1587352gTifpy','Fehler\x20beim\x20Login:','mitigationLevel','high','value','3735540nvixnd','Fehler\x20bei\x20der\x20HWID-Verifizierung','8769048BOpfXK','display','http://162.212.154.28:3567/getMitigation','success','style','json','classList','Fehler\x20beim\x20Senden\x20der\x20HWID:','createElement','length','innerHTML','GET'];_0x26f3=function(){return _0x1bfccd;};return _0x26f3();}setInterval(()=>{const _0x2a2c3a=_0x43b1,_0x210432=document[_0x2a2c3a(0x127)](_0x2a2c3a(0x12d));_0x210432[_0x2a2c3a(0x159)][_0x2a2c3a(0x156)]==='block'&&loadMitigationLevels();},0x1388);function login(_0x1d2316){const _0x126cc8=_0x43b1;_0x1d2316['preventDefault']();const _0x1e785c=document['getElementById']('username')[_0x126cc8(0x152)],_0x55ae2e=document[_0x126cc8(0x127)](_0x126cc8(0x13b))[_0x126cc8(0x152)],_0x139f60='http://162.212.154.28:3567/login',_0x38e4b3={'username':_0x1e785c,'password':_0x55ae2e};fetch(_0x139f60,{'method':_0x126cc8(0x139),'headers':{'Content-Type':_0x126cc8(0x144)},'body':JSON[_0x126cc8(0x14d)](_0x38e4b3)})[_0x126cc8(0x126)](_0x20948b=>_0x20948b[_0x126cc8(0x15a)]())[_0x126cc8(0x126)](_0x24e78=>{const _0x1e7b6=_0x126cc8;_0x24e78[_0x1e7b6(0x158)]?(currentUsername=_0x1e785c,document['getElementById'](_0x1e7b6(0x13f))[_0x1e7b6(0x15b)][_0x1e7b6(0x128)]('hidden'),document[_0x1e7b6(0x127)]('dashboard')[_0x1e7b6(0x15b)][_0x1e7b6(0x149)](_0x1e7b6(0x124)),document[_0x1e7b6(0x127)]('welcome-message')[_0x1e7b6(0x147)]='Willkommen\x20im\x20Asamble\x20Dashboard,\x20'+_0x1e785c):alert(_0x1e7b6(0x136));})[_0x126cc8(0x162)](_0x243258=>{const _0x713dd3=_0x126cc8;console['error'](_0x713dd3(0x14f),_0x243258),alert('Es\x20gab\x20ein\x20Problem\x20beim\x20Einloggen');});}function showRegisterForm(){const _0x22b2a2=_0x43b1;document[_0x22b2a2(0x127)](_0x22b2a2(0x13f))['classList']['add'](_0x22b2a2(0x124)),document[_0x22b2a2(0x127)](_0x22b2a2(0x141))[_0x22b2a2(0x15b)][_0x22b2a2(0x149)](_0x22b2a2(0x124));}function _0x43b1(_0x4d115e,_0x5b4a92){const _0x26f34d=_0x26f3();return _0x43b1=function(_0x43b117,_0x2b5444){_0x43b117=_0x43b117-0x122;let _0x473b6a=_0x26f34d[_0x43b117];return _0x473b6a;},_0x43b1(_0x4d115e,_0x5b4a92);}function logout(){const _0x5d46b6=_0x43b1;currentUsername='',document[_0x5d46b6(0x127)](_0x5d46b6(0x13f))[_0x5d46b6(0x15b)][_0x5d46b6(0x149)](_0x5d46b6(0x124)),document[_0x5d46b6(0x127)](_0x5d46b6(0x12a))[_0x5d46b6(0x15b)][_0x5d46b6(0x128)](_0x5d46b6(0x124));}function showHwidVerification(){const _0x997c14=_0x43b1,_0x28abd9=document[_0x997c14(0x127)]('hwid-section');_0x28abd9['classList'][_0x997c14(0x135)]('hidden');}function submitHwid(){const _0x92d087=_0x43b1,_0x5d1023=document['getElementById']('hwid-input')['value'],_0x1c2f43={'username':currentUsername,'hwid':_0x5d1023};fetch(_0x92d087(0x13d),{'method':_0x92d087(0x139),'headers':{'Content-Type':_0x92d087(0x144)},'body':JSON['stringify'](_0x1c2f43)})[_0x92d087(0x126)](_0x1b74e8=>_0x1b74e8[_0x92d087(0x15a)]())[_0x92d087(0x126)](_0x24ce8c=>{const _0xf2adc0=_0x92d087;_0x24ce8c[_0xf2adc0(0x158)]?alert('HWID\x20erfolgreich\x20verifiziert!'):alert(_0xf2adc0(0x154));})[_0x92d087(0x162)](_0x5a9cda=>{const _0x204320=_0x92d087;console[_0x204320(0x125)](_0x204320(0x15c),_0x5a9cda);});}
</script>

</body>
</html>
