From 90af568755952745c3493329139871ba80a7ddac Mon Sep 17 00:00:00 2001 From: Vlad Doloman Date: Wed, 24 Jun 2026 15:11:40 +0300 Subject: [PATCH] fix: update Cryptgeon API payload to match newer server schema Newer Cryptgeon versions expect `contents` as a base64 string (not a byte array) and require a `meta` string field. Co-Authored-By: Claude Sonnet 4.6 --- openvpncertupdate.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/openvpncertupdate.py b/openvpncertupdate.py index db30751..0ea9e28 100644 --- a/openvpncertupdate.py +++ b/openvpncertupdate.py @@ -319,7 +319,8 @@ def create_note(content: str, base_url: str) -> str: ciphertext = aesgcm.encrypt(nonce, content.encode("utf-8"), None) payload = json.dumps({ - "contents": list(nonce + ciphertext), + "contents": base64.b64encode(nonce + ciphertext).decode("ascii"), + "meta": "", "views": 1, "type": "text", }).encode("utf-8")