From 0bf12e1d2c8e552ffe0a1b94d73a43b5797c45fd Mon Sep 17 00:00:00 2001 From: kaa Date: Sun, 26 Jan 2025 09:22:58 -0800 Subject: Jank --- check | 8 ++++++++ dec | 2 ++ enc | 2 ++ explain.html | 5 +++++ form.html | 12 ++++++++++++ h | 1 + index.nginx-debian.html | 25 +++++++++++++++++++++++++ msg | 2 ++ msg.asc | 16 ++++++++++++++++ msg.signed | 18 ++++++++++++++++++ multipart | Bin 0 -> 7586 bytes multipart-parser-c | 1 + pretty.css | 10 ++++++++++ pubkey | 41 +++++++++++++++++++++++++++++++++++++++++ qr | 6 ++++++ qr.png | Bin 0 -> 6382 bytes sign | 2 ++ upload | 9 +++++++++ upload.py | 22 ++++++++++++++++++++++ verify | 3 +++ 20 files changed, 185 insertions(+) create mode 100755 check create mode 100755 dec create mode 100755 enc create mode 100644 explain.html create mode 100755 form.html create mode 160000 h create mode 100644 index.nginx-debian.html create mode 100644 msg create mode 100644 msg.asc create mode 100644 msg.signed create mode 100644 multipart create mode 160000 multipart-parser-c create mode 100644 pretty.css create mode 100644 pubkey create mode 100755 qr create mode 100644 qr.png create mode 100755 sign create mode 100755 upload create mode 100755 upload.py create mode 100755 verify diff --git a/check b/check new file mode 100755 index 0000000..0dd9ab3 --- /dev/null +++ b/check @@ -0,0 +1,8 @@ +#!/bin/sh + +echo 'Content-Type: text/html' +echo + +cat pretty.css +cat form.html +cat explain.html diff --git a/dec b/dec new file mode 100755 index 0000000..9e34c8e --- /dev/null +++ b/dec @@ -0,0 +1,2 @@ +#!/bin/sh +zbarimg -q --raw qr.png diff --git a/enc b/enc new file mode 100755 index 0000000..951847c --- /dev/null +++ b/enc @@ -0,0 +1,2 @@ +#!/bin/sh +qrencode -l L -r pubkey -o qr.png diff --git a/explain.html b/explain.html new file mode 100644 index 0000000..1536430 --- /dev/null +++ b/explain.html @@ -0,0 +1,5 @@ +

+The QR Code is the public key, transferred by camera. +The Message is the original sent message. +Verify that these match, and you know the identity matches. +

diff --git a/form.html b/form.html new file mode 100755 index 0000000..653d74b --- /dev/null +++ b/form.html @@ -0,0 +1,12 @@ +
+
+ + +
+ +
+ + +
+ +
diff --git a/h b/h new file mode 160000 index 0000000..01bcfa8 --- /dev/null +++ b/h @@ -0,0 +1 @@ +Subproject commit 01bcfa89fc3b3b754e40a979a1fa983ba49fbae2 diff --git a/index.nginx-debian.html b/index.nginx-debian.html new file mode 100644 index 0000000..2ca3b95 --- /dev/null +++ b/index.nginx-debian.html @@ -0,0 +1,25 @@ + + + +Welcome to nginx! + + + +

Welcome to nginx!

+

If you see this page, the nginx web server is successfully installed and +working. Further configuration is required.

+ +

For online documentation and support please refer to +nginx.org.
+Commercial support is available at +nginx.com.

+ +

Thank you for using nginx.

+ + diff --git a/msg b/msg new file mode 100644 index 0000000..ca0b51e --- /dev/null +++ b/msg @@ -0,0 +1,2 @@ +Hello! I am interested in buying your kayaking gear. +My name is Bob. diff --git a/msg.asc b/msg.asc new file mode 100644 index 0000000..239de74 --- /dev/null +++ b/msg.asc @@ -0,0 +1,16 @@ +-----BEGIN PGP MESSAGE----- + +owEBFQLq/ZANAwAKAVCXa+wHYwUJAaxOYgNtc2dnllfmSGVsbG8hIEkgYW0gaW50 +ZXJlc3RlZCBpbiBidXlpbmcgeW91ciBrYXlha2luZyBnZWFyLgpNeSBuYW1lIGlz +IEJvYi4KiQGzBAABCgAdFiEEig3p6jDKFYI20pGpUJdr7AdjBQkFAmeWV+YACgkQ +UJdr7AdjBQnRvwv+O/XrTcumHHIBsSwzPYyE+n7q1AMoUIanaWU36B9kmi9GCTOg +JijP8VlK8HSR2jxJ37D5rFIs5Qz2Vk+IK2sFD+zb2kfY94liipC/5ZN9diPgbLX2 ++bPYUAe4E/CJO5iJZGvJNu3Fq4j6W+IRg1X1/qHakZRGHRcT+03L2fF6cVcotnNq +VlzGBCnMDLkw6e6xiRz2AiRRXLMF+PnVkbZJPfqPt1OjBrf3NBk2yClV1fUamMra +M4YpH/B9WytgWLXAmZuBl8iQb1FFOdY9Kkhz826akmsIezSPlVcuHBwlTFOgnA+R +ea/R0X1xef/d5LvyMDUZ9TDP25f86xPJwNORY5MoVUx3ItFBxEMzaAm2Axx//wEU +6WTS4sGXSrWKdHkTtSwH5XSz7SzUiG8ApujRsCA0gYPrtVJhinTyUkGl/8Yvvom3 +iWxK2w/WgPWO5uNrGFGV8CS5jCn15d+PdN8N5brZOr4Jk5g8/6aFWoySuGTpvs8A +MH/lMkop5sIlyUIx +=l8IB +-----END PGP MESSAGE----- diff --git a/msg.signed b/msg.signed new file mode 100644 index 0000000..aed85f3 --- /dev/null +++ b/msg.signed @@ -0,0 +1,18 @@ +Hello! I am interested in buying your kayaking gear. +My name is Bob. +-----BEGIN PGP MESSAGE----- + +owEBFQLq/ZANAwAKAVCXa+wHYwUJAaxOYgNtc2dnllfmSGVsbG8hIEkgYW0gaW50 +ZXJlc3RlZCBpbiBidXlpbmcgeW91ciBrYXlha2luZyBnZWFyLgpNeSBuYW1lIGlz +IEJvYi4KiQGzBAABCgAdFiEEig3p6jDKFYI20pGpUJdr7AdjBQkFAmeWV+YACgkQ +UJdr7AdjBQnRvwv+O/XrTcumHHIBsSwzPYyE+n7q1AMoUIanaWU36B9kmi9GCTOg +JijP8VlK8HSR2jxJ37D5rFIs5Qz2Vk+IK2sFD+zb2kfY94liipC/5ZN9diPgbLX2 ++bPYUAe4E/CJO5iJZGvJNu3Fq4j6W+IRg1X1/qHakZRGHRcT+03L2fF6cVcotnNq +VlzGBCnMDLkw6e6xiRz2AiRRXLMF+PnVkbZJPfqPt1OjBrf3NBk2yClV1fUamMra +M4YpH/B9WytgWLXAmZuBl8iQb1FFOdY9Kkhz826akmsIezSPlVcuHBwlTFOgnA+R +ea/R0X1xef/d5LvyMDUZ9TDP25f86xPJwNORY5MoVUx3ItFBxEMzaAm2Axx//wEU +6WTS4sGXSrWKdHkTtSwH5XSz7SzUiG8ApujRsCA0gYPrtVJhinTyUkGl/8Yvvom3 +iWxK2w/WgPWO5uNrGFGV8CS5jCn15d+PdN8N5brZOr4Jk5g8/6aFWoySuGTpvs8A +MH/lMkop5sIlyUIx +=l8IB +-----END PGP MESSAGE----- diff --git a/multipart b/multipart new file mode 100644 index 0000000..c34938a Binary files /dev/null and b/multipart differ diff --git a/multipart-parser-c b/multipart-parser-c new file mode 160000 index 0000000..772639c --- /dev/null +++ b/multipart-parser-c @@ -0,0 +1 @@ +Subproject commit 772639cf10db6d9f5a655ee9b7eb20b815fab396 diff --git a/pretty.css b/pretty.css new file mode 100644 index 0000000..f06d511 --- /dev/null +++ b/pretty.css @@ -0,0 +1,10 @@ + + + diff --git a/pubkey b/pubkey new file mode 100644 index 0000000..72b0e54 --- /dev/null +++ b/pubkey @@ -0,0 +1,41 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mQGNBGeVv4MBDACla+XtxBSyzIu/bOCyx+iXhnVcMYwJgEHTsaCCYnTP+g7V0VCj +yBgkKM7kUgIlU7D76YBa7MNOoUN9W16zD4QpENQ3gqHD/lgts3d2RJJizYyS7sbA +VCDdJXxpEecdaWn5JVjhGC3Vm6/r0IzytRodBxW+A72D21bH8FJkaPMTMb0awnLI +rfuJRKnZgcI3zUmmPOnoghRselnhkaSlIDeYlH1w9qFN0BlFGErBi8n9GywLYtR8 +NlL1iKKA38u1EvdVNqWClfKVf5iwR9ZUX8Mpqp+h1SB7Ku6lNpdYeZhnu/NUBTWB +s8t1JlPREey3tnND7q7zXgjiP5AGKT/6qYr+Ng8sEw1A5AVxx/Pvx1fVsPYhc0eb +3cUvFx69Mw8mgjofR+EkH6+3UmsOy5R+Cl8K6aGewNp4ydOtq4P6ks09AUQb0P+K +E1kijIuR//o5ulKC4zmBgQUykxaE1Y1V0xaj6Rofx2yrzQy4RM7x6eVStAqYi0J4 ++y7U4L5VaSUNZxcAEQEAAbQeSm9obiBTbWl0aCBKb25lcyA8Ym9iQG1vbS5jb20+ +iQHUBBMBCgA+FiEEig3p6jDKFYI20pGpUJdr7AdjBQkFAmeVv4MCG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SNuig7skfl7Mr16C7B2n/GrcgzV+ECff2J/sKZZ7fpFUqZh +wTMAEQEAAYkBvAQYAQoAJhYhBIoN6eowyhWCNtKRqVCXa+wHYwUJBQJnlb+DAhsM +BQkDwmcAAAoJEFCXa+wHYwUJyTAL/2gYaDNxPF4L6bw94g+0NT/CuGid/CZKZpEO +X2Jukdd8IHMfGvEOPgy1m59uRTObHzkQmWugGjbQsWPmHMBhsApv8T+rdN9F9NyG +ysXq9XZaOAwUCQril5xpfE49GwQWVTSWMdVpIigYpe5zBhrYzVNxXqocOlj698K1 +LDCyMq3CMxgOv9z8VaU4FSDB0C4OsfgVyiWGAIwsMo2EPJMCY0q422Rez/J2JXkb +uv4CUkxNyAFDcluhH31s8KKftCYQgNSf6YV4Q7wvwjLtmZmdC5VoIn+eTuB1WJkg +C70/U/9JYwWiVJJ7pyhEUBvju009xZ/JQxxWuGgKhKrZSkiOe5zf1qLdVNeZ5gzl +KKFcCYQNDo2V/d2mTZmFR1/R0ZmSmc1jZrJeMP2XE0x2XN2gteaTEtjfLGM7VoUF +n0nrHcK4cOhgNv7zZLEcyeMJrb76KxoPKsRxWGefhRUtgikSvHF+lpSSFZxKSDHF +GWhFa/dxeR+a1Nt9FFSX3Ql2hee4tg== +=ybce +-----END PGP PUBLIC KEY BLOCK----- diff --git a/qr b/qr new file mode 100755 index 0000000..08c9239 --- /dev/null +++ b/qr @@ -0,0 +1,6 @@ +#!/bin/sh + +echo 'Context-Type: image/png' +echo + +cat qr.png diff --git a/qr.png b/qr.png new file mode 100644 index 0000000..e29fbee Binary files /dev/null and b/qr.png differ diff --git a/sign b/sign new file mode 100755 index 0000000..da69dad --- /dev/null +++ b/sign @@ -0,0 +1,2 @@ +gpg --sign --armor msg +cat msg msg.asc > msg.signed diff --git a/upload b/upload new file mode 100755 index 0000000..4ac83e3 --- /dev/null +++ b/upload @@ -0,0 +1,9 @@ +#!/bin/sh + + +echo 'Content-Type: text/plain' +echo +echo Thanks. +cat > multipart +./upload.py + diff --git a/upload.py b/upload.py new file mode 100755 index 0000000..d81a8f0 --- /dev/null +++ b/upload.py @@ -0,0 +1,22 @@ +#!/usr/bin/python3 + +import python-multipart +import sys +import os + +fields = {} +files = {} +def on_field(field): + fields[field.field_name] = field.value +def on_file(file): + files[file.field_name] = {'name': file.file_name, 'file_object': file.file_object} + +with open ("multipart", mode='rb') as file: + form = file.read() + +multipart_headers = {'Content-Type': os.environ['CONTENT_TYPE']} +multipart_headers['Content-Length'] = os.environ['CONTENT_LENGTH'] +multipart.parse_form(multipart_headers, form, on_field, on_file) + +print(fields) +print(files) diff --git a/verify b/verify new file mode 100755 index 0000000..5fbd9ef --- /dev/null +++ b/verify @@ -0,0 +1,3 @@ +#!/bin/sh + +gpg --verify msg.signed -- cgit v1.2.3