Use XML format when writing HTML artifacts

This commit is contained in:
HiPhish 2022-11-22 23:28:02 +01:00
parent 9dfb78ea06
commit aefa02fe1a

View file

@ -36,9 +36,10 @@
(template hssg.artifact::template) (template hssg.artifact::template)
(output hssg.artifact::output)) (output hssg.artifact::output))
artifact artifact
(let ((contents (plump:serialize (let* ((plump:*tag-dispatchers* plump:*xml-tags*)
(sexp->plump-tree (cdr (assoc :content (funcall template data)))) (contents (plump:serialize
nil))) (sexp->plump-tree (cdr (assoc :content (funcall template data))))
nil)))
(make-instance 'hssg.filesystem:write-string-contents (make-instance 'hssg.filesystem:write-string-contents
:contents (format nil "<!DOCTYPE html>~%~A" contents) :contents (format nil "<!DOCTYPE html>~%~A" contents)
:path output)))) :path output))))