<!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(255, 255, 255, 0.9); /* Halbtransparenter Hintergrund */
            border-radius: 35px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 60px rgba(255, 255, 255, 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: #800000; /* 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(255, 255, 255, 0.7); /* Volle Sättigung, keine Transparenz */
            border-radius: 12px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 90px rgba(255, 255, 255, 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 */
        }

    </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>
    <p><a href="#" onclick="showLoginForm()">Bereits ein Konto? Einloggen</a></p>
</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 _0xfc8e(_0x351301,_0x4cd26c){const _0x303866=_0x3038();return _0xfc8e=function(_0xfc8e21,_0x2944ea){_0xfc8e21=_0xfc8e21-0x1d8;let _0xaa3082=_0x303866[_0xfc8e21];return _0xaa3082;},_0xfc8e(_0x351301,_0x4cd26c);}function _0x3038(){const _0x1a39a0=['remove','hidden','4307888bKAiWB','GET','add','error','POST','medium','innerHTML','json','application/json','Fehler\x20bei\x20der\x20HWID-Verifizierung','480084nCTiCK','login-form','createElement','classList','then','block','http://162.212.154.28:3567/getMitigation','31793qusYlt','welcome-message','hwid-section','style','span','toggle','black','mitigationLevel','510825PeGpon','10239290gYWJts','message','Willkommen\x20im\x20Asamble\x20Dashboard,\x20','getElementById','6zvbgmV','low','hwid-input','Fehler\x20beim\x20Login:','textContent','4764932TuvcKA','appendChild','value','522aqDlgr','Es\x20gab\x20ein\x20Problem\x20beim\x20Einloggen','status','toLowerCase','11645lSLhae','HWID\x20erfolgreich\x20verifiziert!','http://162.212.154.28:3567/verifyHwid','dashboard','</p>','\x20-\x20','HTTP-Error:\x20','mitigation-console','red','color','Mitigation\x20for\x20:\x20','9BrMmCd','register-form','success','forEach','stringify','display','orange','none','catch','high'];_0x3038=function(){return _0x1a39a0;};return _0x3038();}(function(_0x1933a7,_0x171e9d){const _0x25666f=_0xfc8e,_0x24c184=_0x1933a7();while(!![]){try{const _0x2d42af=-parseInt(_0x25666f(0x1fe))/0x1+parseInt(_0x25666f(0x1f7))/0x2*(parseInt(_0x25666f(0x20b))/0x3)+-parseInt(_0x25666f(0x210))/0x4+parseInt(_0x25666f(0x217))/0x5*(-parseInt(_0x25666f(0x213))/0x6)+parseInt(_0x25666f(0x206))/0x7+parseInt(_0x25666f(0x1ed))/0x8+parseInt(_0x25666f(0x1e1))/0x9*(parseInt(_0x25666f(0x207))/0xa);if(_0x2d42af===_0x171e9d)break;else _0x24c184['push'](_0x24c184['shift']());}catch(_0x1b1865){_0x24c184['push'](_0x24c184['shift']());}}}(_0x3038,0xa86a1));function loadMitigationLevels(){const _0x60b299=_0xfc8e;fetch(_0x60b299(0x1fd),{'method':_0x60b299(0x1ee),'headers':{'Content-Type':'application/json'}})[_0x60b299(0x1fb)](_0x3b66c9=>{const _0x19a4c2=_0x60b299;if(!_0x3b66c9['ok'])throw new Error(_0x19a4c2(0x1dc)+_0x3b66c9[_0x19a4c2(0x215)]);return _0x3b66c9[_0x19a4c2(0x1f4)]();})[_0x60b299(0x1fb)](_0x3da930=>{const _0x4141da=_0x60b299,_0x53cb82=document[_0x4141da(0x20a)](_0x4141da(0x1dd));_0x53cb82['innerHTML']='',_0x3da930&&_0x3da930['length']>0x0?_0x3da930[_0x4141da(0x1e4)](_0x3084d5=>{const _0xfea2c0=_0x4141da,_0x408ef2=document['createElement']('p'),_0xcc9d9f=document[_0xfea2c0(0x1f9)](_0xfea2c0(0x202));_0xcc9d9f[_0xfea2c0(0x20f)]=_0xfea2c0(0x1e0),_0xcc9d9f[_0xfea2c0(0x201)][_0xfea2c0(0x1df)]='red';const _0x218015=document[_0xfea2c0(0x1f9)](_0xfea2c0(0x202));_0x218015[_0xfea2c0(0x20f)]=_0x3084d5['username'],_0x218015[_0xfea2c0(0x201)]['color']=_0xfea2c0(0x204);const _0x2a1629=document[_0xfea2c0(0x1f9)]('span');_0x2a1629[_0xfea2c0(0x20f)]=_0xfea2c0(0x1db)+_0x3084d5[_0xfea2c0(0x205)];switch(_0x3084d5[_0xfea2c0(0x205)][_0xfea2c0(0x216)]()){case _0xfea2c0(0x20c):_0x2a1629[_0xfea2c0(0x201)][_0xfea2c0(0x1df)]='green';break;case _0xfea2c0(0x1f2):_0x2a1629[_0xfea2c0(0x201)][_0xfea2c0(0x1df)]=_0xfea2c0(0x1e7);break;case _0xfea2c0(0x1ea):_0x2a1629[_0xfea2c0(0x201)][_0xfea2c0(0x1df)]=_0xfea2c0(0x1de);break;default:_0x2a1629[_0xfea2c0(0x201)][_0xfea2c0(0x1df)]='black';break;}_0x408ef2['appendChild'](_0xcc9d9f),_0x408ef2['appendChild'](_0x218015),_0x408ef2[_0xfea2c0(0x211)](_0x2a1629),_0x53cb82['appendChild'](_0x408ef2);}):_0x53cb82['innerHTML']='<p>Keine\x20Mitigation\x20Levels\x20verfügbar.</p>';})['catch'](_0x5388fe=>{const _0x496042=_0x60b299;console[_0x496042(0x1f0)]('Fehler\x20beim\x20Abrufen\x20der\x20Mitigation\x20Levels:',_0x5388fe);const _0xf3d23c=document['getElementById'](_0x496042(0x1dd));_0xf3d23c[_0x496042(0x1f3)]='<p>Fehler\x20beim\x20Abrufen\x20der\x20Mitigation\x20Levels:\x20'+_0x5388fe[_0x496042(0x208)]+_0x496042(0x1da);});}function showMitigationConsole(){const _0x41d68b=_0xfc8e,_0x22fc3e=document[_0x41d68b(0x20a)]('mitigation-console'),_0xa8b400=_0x22fc3e[_0x41d68b(0x201)][_0x41d68b(0x1e6)]===_0x41d68b(0x1e8)||_0x22fc3e[_0x41d68b(0x201)][_0x41d68b(0x1e6)]==='';_0x22fc3e[_0x41d68b(0x201)][_0x41d68b(0x1e6)]=_0xa8b400?_0x41d68b(0x1fc):_0x41d68b(0x1e8),_0xa8b400&&loadMitigationLevels();}setInterval(()=>{const _0x8e71d3=_0xfc8e,_0x16b042=document[_0x8e71d3(0x20a)]('mitigation-console');_0x16b042[_0x8e71d3(0x201)][_0x8e71d3(0x1e6)]===_0x8e71d3(0x1fc)&&loadMitigationLevels();},0x1388);function login(_0x46c510){const _0x4a5225=_0xfc8e;_0x46c510['preventDefault']();const _0x2b976e=document[_0x4a5225(0x20a)]('username')['value'],_0x51dc7f=document[_0x4a5225(0x20a)]('password')['value'],_0x16409d='http://162.212.154.28:3567/login',_0x2896e1={'username':_0x2b976e,'password':_0x51dc7f};fetch(_0x16409d,{'method':_0x4a5225(0x1f1),'headers':{'Content-Type':_0x4a5225(0x1f5)},'body':JSON[_0x4a5225(0x1e5)](_0x2896e1)})[_0x4a5225(0x1fb)](_0x4264c6=>_0x4264c6[_0x4a5225(0x1f4)]())[_0x4a5225(0x1fb)](_0x19249c=>{const _0x46402a=_0x4a5225;_0x19249c[_0x46402a(0x1e3)]?(currentUsername=_0x2b976e,document[_0x46402a(0x20a)](_0x46402a(0x1f8))[_0x46402a(0x1fa)][_0x46402a(0x1ef)]('hidden'),document[_0x46402a(0x20a)](_0x46402a(0x1d9))[_0x46402a(0x1fa)]['remove'](_0x46402a(0x1ec)),document[_0x46402a(0x20a)](_0x46402a(0x1ff))[_0x46402a(0x20f)]=_0x46402a(0x209)+_0x2b976e):alert('Ungültiger\x20Benutzername\x20oder\x20Passwort');})[_0x4a5225(0x1e9)](_0x4e3fad=>{const _0x412d26=_0x4a5225;console['error'](_0x412d26(0x20e),_0x4e3fad),alert(_0x412d26(0x214));});}function showRegisterForm(){const _0x58973a=_0xfc8e;document[_0x58973a(0x20a)](_0x58973a(0x1f8))[_0x58973a(0x1fa)][_0x58973a(0x1ef)](_0x58973a(0x1ec)),document[_0x58973a(0x20a)](_0x58973a(0x1e2))['classList'][_0x58973a(0x1eb)](_0x58973a(0x1ec));}function logout(){const _0x5b4931=_0xfc8e;currentUsername='',document[_0x5b4931(0x20a)](_0x5b4931(0x1f8))[_0x5b4931(0x1fa)]['remove'](_0x5b4931(0x1ec)),document['getElementById'](_0x5b4931(0x1d9))[_0x5b4931(0x1fa)][_0x5b4931(0x1ef)](_0x5b4931(0x1ec));}function showHwidVerification(){const _0x5fef79=_0xfc8e,_0x576a37=document[_0x5fef79(0x20a)](_0x5fef79(0x200));_0x576a37['classList'][_0x5fef79(0x203)](_0x5fef79(0x1ec));}function submitHwid(){const _0x93643a=_0xfc8e,_0x47c2f3=document[_0x93643a(0x20a)](_0x93643a(0x20d))[_0x93643a(0x212)],_0x38b6bd={'username':currentUsername,'hwid':_0x47c2f3};fetch(_0x93643a(0x1d8),{'method':_0x93643a(0x1f1),'headers':{'Content-Type':'application/json'},'body':JSON[_0x93643a(0x1e5)](_0x38b6bd)})[_0x93643a(0x1fb)](_0x134654=>_0x134654[_0x93643a(0x1f4)]())[_0x93643a(0x1fb)](_0x1a08ce=>{const _0x4bab17=_0x93643a;_0x1a08ce[_0x4bab17(0x1e3)]?alert(_0x4bab17(0x218)):alert(_0x4bab17(0x1f6));})[_0x93643a(0x1e9)](_0x3f15e=>{console['error']('Fehler\x20beim\x20Senden\x20der\x20HWID:',_0x3f15e);});}
</script>

</body>
</html>
