list

hooks

Hooks to be used to receive/send emails.

curl -O https://dovel.email/hooks.tar.gz tar.gz

74fb1a5

Author: blmayer (bleemayer@gmail.com)

Date: Fri Jan 19 16:30:01 2024 -0300

Parent: 59d3b4e

Improved boundary support

Diff

receive-example.domain

diff --git a/receive-example.domain b/receive-example.domain
index b2c6277..370cae6 100755
--- a/receive-example.domain
+++ b/receive-example.domain
@@ -125,7 +125,7 @@ emails() {
 				printf "$k $v\n"
 				case "$k" in
 				"Content-Type:") ctype="${v%%;*}" ;;
-				"boundary="*) boundary="${k#*\"}" ;;
+				"boundary="*) boundary="$(printf "%s" "${k#*=}" | tr -d ';"')" ;;
 				"Content-Disposition:")
 					cdisp="${v%%;*}"
 
@@ -149,7 +149,6 @@ emails() {
 
 			case "$ctype" in
 			"multipart"*)
-				boundary="${boundary%\"*}"
 				printf "<pre>\n"
 				while read -r line
 				do