# $Id$
import rpki.https, tlslite.api, rpki.config
cfg = rpki.config.parser("http-demo.conf")
section = "server"
privateKey = rpki.x509.RSA_Keypair(PEM_file = cfg.get(section, "https-key"))
certChain = rpki.x509.X509_chain()
certChain.load_from_PEM(cfg.multiget(section, "https-cert"))
def handler(query, path):
return 200, "Path: %s\nQuery: %s" % (path, query)
rpki.https.server(privateKey=privateKey, certChain=certChain, handlers=handler)
 |
index : sra/rpki.net | |
Dragon Research Labs RPKI Toolkit | git user |
blob: 01d66fd3a327d9e591b5091ed3ef339790bf7e8b (
plain) (
blame)