File tree Expand file tree Collapse file tree 5 files changed +12
-12
lines changed
Expand file tree Collapse file tree 5 files changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ Automatically generates certificates to intercept and decrypt SSL messages.
33
44# Dependencies
55
6- - SBCL + Ultralisp
6+ - SBCL + [ Ultralisp] ( https://ultralisp.org )
77- [ FiloSottile/mkcert] ( https://github.com/FiloSottile/mkcert )
88- SQLite
99- GTK4 or Tcl/Tk
Original file line number Diff line number Diff line change 22
33(defun redraw-modeline ()
44 (setf (text (modeline *main-app* ))
5- (uiop :strcat
6- " Server: "
7- (format nil " ~a :~a "
8- (ignore-errors (http :server-host mx-proxy :*server* ))
9- (ignore-errors (http :server-port mx-proxy :*server* )))
10- " | Project: "
11- mx-proxy :*db-file* )))
5+ (format nil " Server: ~a :~a | Project: ~a "
6+ (ignore-errors (http :server-host mx-proxy :*server* ))
7+ (ignore-errors (http :server-port mx-proxy :*server* ))
8+ mx-proxy :*db-file* )))
129
1310(register-hook (:on-command :redraw-modeline ) (command)
1411 (declare (ignore command))
Original file line number Diff line number Diff line change 11(in-package :mx-proxy )
22
33(defvar *db-file* nil
4- " Filename of the current Sqlite connection." )
4+ " Filename of the current SQLite connection." )
55
66(defun migrate-database (&key recreate ensure)
77 (loop :for table :in ' (http :request http :response http :message-pair)
1010 (t (mito :migrate-table table)))))
1111
1212(defun connect-database (&key (file " /tmp/proxy.sqlite3" ))
13- " Connect to a Sqlite database. This serves as a 'project file' for proxy sessions."
13+ " Connect to a SQLite database. This serves as a 'project file' for proxy sessions."
1414 (mito :connect-toplevel :sqlite3 :database-name file)
1515 (setf *db-file* file)
1616 (migrate-database :ensure t ))
Original file line number Diff line number Diff line change 1313 :replay
1414
1515 ; ; ssl.lisp
16+ :*cert-directory*
1617 :send-request-ssl
1718
1819 ; ; config.lisp
Original file line number Diff line number Diff line change 11(in-package :mx-proxy )
22
3+ (defparameter *cert-directory* " /tmp/mx-proxy/certs/" )
4+
35(defun cert-file (name)
46 (namestring
57 (merge-pathnames
6- ( format nil " certs/ ~a " name)
7- (asdf :system-source-directory :mx-proxy ))))
8+ name
9+ (ensure-directories-exist *cert-directory* ))))
810
911(defun certificate (host &key create)
1012 " Retrieve or generate certificate and key for host."
You can’t perform that action at this time.
0 commit comments