Security
Headlines
HeadlinesLatestCVEs

Headline

CVE-2022-4591: Ensure e-mail parameters are escaped to avoid XSS attacks. · mschaef/toto@1f27f37

A vulnerability was found in mschaef toto up to 1.4.20. It has been declared as problematic. This vulnerability affects unknown code of the component Email Parameter Handler. The manipulation leads to cross site scripting. The attack can be initiated remotely. Upgrading to version 1.4.21 is able to address this issue. The name of the patch is 1f27f37c1a06f54a76971f70eaa6139dc139bdf9. It is recommended to upgrade the affected component. VDB-216178 is the identifier assigned to this vulnerability.

CVE
#xss#vulnerability

@@ -19,29 +19,37 @@ ;; ;; You must not remove this notice, or any other, from this software.

(ns toto.core.mail (:use hiccup.core) (:use toto.core.util) (:require [clojure.tools.logging :as log] [postal.core :as postal])) [postal.core :as postal] [hiccup.core :as hiccup] [hiccup.util :as hiccup-util]))
(defn- escape-email-params [ params ] (map-values #(if (string? %) (hiccup-util/escape-html %) “”) params))
(defn send-email [config message-info] (let [smtp (:smtp config) {to :to subject :subject content :content params :params} message-info html-content (html [:html (if (fn? content) (content (merge config (or params {}))) content)])] {:keys [ to subject content params ]} message-info html-content (hiccup/html [:html (content (escape-email-params (merge {:base-url (:base-url config)} (or params {}))))])]
(log/info "Sending mail to " to " with subject: " subject) (cond (not (:enabled smtp)) (do (log/warn "E-mail disabled. Message not sent. Message text: ") (log/warn html-content)) (log/warn "E-mail disabled. Message not sent. Message text: " html-content)
(or (nil? to) (= (count to) 0)) (do (log/warn "No destination e-mail address. Message not send. Message text: ") (log/warn html-content)) (log/warn "No destination e-mail address. Message not send. Message text: " html-content)
:else (postal/send-message {:host (:host smtp)

CVE: Latest News

CVE-2023-50976: Transactions API Authorization by oleiman · Pull Request #14969 · redpanda-data/redpanda