diff --git a/server.py b/server.py index a38ecc1..e982b2d 100644 --- a/server.py +++ b/server.py @@ -39,7 +39,12 @@ def loadcert_backend(): if allowed_file(cert.filename) and allowed_file(privkey.filename): for i in os.listdir(homefolder + "/certs/"): thisname = "-".join(i.split("-")[:-1]) - if open(homefolder + "/certs/" + thisname + "-privkey.pem").read() == privkey.read() and open(homefolder + "/certs/" + thisname + "-chain.pem").read() == cert.read(): + print("thisname") + print([open(homefolder + "/certs/" + thisname + "-privkey.pem").read()]) + print([privkey.read()]) + print([open(homefolder + "/certs/" + thisname + "-chain.pem").read()]) + print([cert.read()]) + if (open(homefolder + "/certs/" + thisname + "-privkey.pem").read() == privkey.read()) and (open(homefolder + "/certs/" + thisname + "-chain.pem").read() == cert.read()): resp = make_response('The certificate seems to already exist, loading the used file.

Go home

') resp.set_cookie('certname',thisname) return resp