From 4c6ba9a572d9fe2666c9ca35f6270f2ff066ec3e Mon Sep 17 00:00:00 2001 From: Malloc of Kuzkycyziklistan Date: Mon, 4 Sep 2017 23:24:40 -0500 Subject: [PATCH] smolchange reer --- client/lib/check.js | 4 ++-- client/lib/loginstration.js | 4 ++-- client/style.css | 5 +++++ server/DAL/User.cs | 3 +++ server/Libraries/Kneesocks/Server.cs | 2 +- server/Socks/MasterConnection.cs | 1 + 6 files changed, 14 insertions(+), 5 deletions(-) diff --git a/client/lib/check.js b/client/lib/check.js index b7815bf..5a51b04 100644 --- a/client/lib/check.js +++ b/client/lib/check.js @@ -1,6 +1,6 @@ // feature checking trashcode (c) obrado 1989 -window.onload = function() { +window.addEventListener("load", function() { var support = { anim: true, canvas: true, @@ -57,4 +57,4 @@ window.onload = function() { } Entrypoint.start(); -} +}); diff --git a/client/lib/loginstration.js b/client/lib/loginstration.js index 5c43ca9..ae25e81 100644 --- a/client/lib/loginstration.js +++ b/client/lib/loginstration.js @@ -8,7 +8,7 @@ var register_button; var login; var register; var create; -window.onload = function () { +window.addEventListener("load", function () { // Define var's for transition; login_header = document.getElementById("loginstration-header"); @@ -19,7 +19,7 @@ window.onload = function () { create = document.getElementById("register-button-submit"); register_button.addEventListener("click" , prepareRegister); create.addEventListener("click" , prepareLogin); -}; +}); function prepareRegister(){ login_header.classList.remove("displayYes"); diff --git a/client/style.css b/client/style.css index a488b5f..6402725 100644 --- a/client/style.css +++ b/client/style.css @@ -102,6 +102,7 @@ body { height:25px; font-size: 20px; background: #000; + margin-bottom:25px; padding:10px; } @@ -113,6 +114,7 @@ body { font-size: 20px; background: #000; padding:10px; + margin-bottom:25px; border: 1px solid white; } @@ -150,6 +152,7 @@ body { width: 300px; height:25px; font-size: 20px; + margin-bottom:25px; background: #000; padding:10px; border: 1px solid white; @@ -161,6 +164,7 @@ body { color: yellow; width: 300px; height:25px; + margin-bottom:25px; font-size: 20px; background: #000; padding:10px; @@ -174,6 +178,7 @@ body { font-size: 20px; background: #000; padding:10px; + margin-bottom:25px; border: 1px solid white; } diff --git a/server/DAL/User.cs b/server/DAL/User.cs index 7ff418b..37d2ad9 100644 --- a/server/DAL/User.cs +++ b/server/DAL/User.cs @@ -13,6 +13,9 @@ namespace SockScape.DAL { [Required, MaxLength(16)] public string Username { get; set; } + [Required, MaxLength(256)] + public string Email { get; set; } + [Required] public byte[] Password { get; set; } diff --git a/server/Libraries/Kneesocks/Server.cs b/server/Libraries/Kneesocks/Server.cs index ac9b7cb..48d0d4e 100644 --- a/server/Libraries/Kneesocks/Server.cs +++ b/server/Libraries/Kneesocks/Server.cs @@ -45,7 +45,7 @@ namespace Kneesocks { while(Started) { if(Socket.Pending()) { - var templatedConnection = new T() { + var templatedConnection = new T { Server = this }; templatedConnection.Initialize(Socket.AcceptTcpClient()); diff --git a/server/Socks/MasterConnection.cs b/server/Socks/MasterConnection.cs index fc4533e..edf6947 100644 --- a/server/Socks/MasterConnection.cs +++ b/server/Socks/MasterConnection.cs @@ -11,6 +11,7 @@ namespace SockScape { class MasterConnection : Connection { private Key Key; public Cipher Encryptor { get; private set; } + protected override void OnOpen() { Key = new Key();