def wrapped(id): err=authenticated(groups) if err: return err path=ca._incoming+'/'+request.path.split('/')[3] print "certifying", path cert=ca.signcsr(load(path)) mailsigned([cert]) os.unlink(path) return redirect('/tlsauth/csrs/')
def wrapped(id): err = authenticated(groups) if err: return err path = ca._incoming + '/' + request.path.split('/')[3] print "certifying", path cert = ca.signcsr(load(path)) mailsigned([cert]) os.unlink(path) return redirect('/tlsauth/csrs/')
def certify(request, id): """ provides facility for users belonging to `groups` to sign incoming CSRs """ err = authenticated(request, settings.TLS_ADMINGROUPS) if err: return err path = settings.TLS_CA._incoming + "/" + request.path.split("/")[3] print "certifying", path cert = settings.TLS_CA.signcsr(load(path)) mailsigned([cert]) os.unlink(path) return HttpResponseRedirect("/tlsauth/csrs/")
def accept(self): """ provides facility for users belonging to `groups` to sign incoming CSRs """ email=authorized(self.environ, CONFIG['admins']) if not email: return _404(self.environ, self.resp) path=self.ca._incoming+'/'+self.environ.get('REQUEST_URI').split('/')[3] print "certifying", path cert=self.ca.signcsr(load(path)) mailsigned([cert]) os.unlink(path) status = '302 Found' response_headers = [('Location', '/settings/requests')] self.resp(status, response_headers) return []
def accept(self): """ provides facility for users belonging to `groups` to sign incoming CSRs """ email = authorized(self.environ, CONFIG['admins']) if not email: return _404(self.environ, self.resp) path = self.ca._incoming + '/' + self.environ.get('REQUEST_URI').split( '/')[3] print "certifying", path cert = self.ca.signcsr(load(path)) mailsigned([cert]) os.unlink(path) status = '302 Found' response_headers = [('Location', '/settings/requests')] self.resp(status, response_headers) return []