<feed xmlns='http://www.w3.org/2005/Atom'>
<title>claudomator.git/internal/notify/vapid_test.go, branch story/task-project-fk</title>
<subtitle>claudomator — task automation server
</subtitle>
<id>https://git.terst.org/claudomator.git/atom?h=story%2Ftask-project-fk</id>
<link rel='self' href='https://git.terst.org/claudomator.git/atom?h=story%2Ftask-project-fk'/>
<link rel='alternate' type='text/html' href='https://git.terst.org/claudomator.git/'/>
<updated>2026-03-17T08:04:04+00:00</updated>
<entry>
<title>fix: validate VAPID public key on load, regenerate if swapped</title>
<updated>2026-03-17T08:04:04+00:00</updated>
<author>
<name>Claudomator Agent</name>
<email>agent@claudomator</email>
</author>
<published>2026-03-17T08:04:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.terst.org/claudomator.git/commit/?id=b9039dbf194f66738766cb4296ba6d141d6d433e'/>
<id>urn:sha1:b9039dbf194f66738766cb4296ba6d141d6d433e</id>
<content type='text'>
The DB may contain keys generated before the swap fix, with the private
key stored as the public key. Add ValidateVAPIDPublicKey() and use it in
serve.go to detect and regenerate invalid stored keys on startup.

Co-Authored-By: Claude Sonnet 4.6 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>fix: swap VAPID key return order in GenerateVAPIDKeys wrapper</title>
<updated>2026-03-17T02:12:31+00:00</updated>
<author>
<name>Claudomator Agent</name>
<email>agent@claudomator</email>
</author>
<published>2026-03-17T02:12:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.terst.org/claudomator.git/commit/?id=94e45575a34e8672f8b405c54cabd8e524281fef'/>
<id>urn:sha1:94e45575a34e8672f8b405c54cabd8e524281fef</id>
<content type='text'>
webpush.GenerateVAPIDKeys() returns (privateKey, publicKey) but the
claudomator wrapper declared (publicKey, privateKey), causing the
32-byte private key to be sent to browsers as the applicationServerKey.
Browsers require a 65-byte uncompressed P256 point, so they rejected
it with "The provided applicationServerKey is not valid."

Adds a regression test that asserts public key is 87 chars/65 bytes
with 0x04 prefix and private key is 43 chars/32 bytes.

Co-Authored-By: Claude Sonnet 4.6 &lt;noreply@anthropic.com&gt;
</content>
</entry>
</feed>
