Skip to content

Commit 02a154e

Browse files
authored
Merge pull request #4 from garlic0x1/working
Working
2 parents 2181e96 + ba506c3 commit 02a154e

File tree

5 files changed

+12
-12
lines changed

5 files changed

+12
-12
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff 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

frontend/tk/modeline.lisp

+4-7
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,10 @@
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))

src/database.lisp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
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)
@@ -10,7 +10,7 @@
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))

src/package.lisp

+1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
:replay
1414

1515
;; ssl.lisp
16+
:*cert-directory*
1617
:send-request-ssl
1718

1819
;; config.lisp

src/ssl.lisp

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
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."

0 commit comments

Comments
 (0)