@evanp/activitypub-bot 0.26.1 → 0.26.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -49,6 +49,9 @@ export class HTTPSignatureAuthenticator {
49
49
  try {
50
50
  const keyId = this.#signer.keyId(signature)
51
51
  const ok = await this.#remoteKeyStorage.getPublicKey(keyId)
52
+ if (!ok) {
53
+ throw createHttpError(400, 'public key not found')
54
+ }
52
55
  let owner = ok.owner
53
56
  let publicKeyPem = ok.publicKeyPem
54
57
  let result = await this.#signer.validate(publicKeyPem, signature, method, originalUrl, headers)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@evanp/activitypub-bot",
3
- "version": "0.26.1",
3
+ "version": "0.26.2",
4
4
  "description": "server-side ActivityPub bot framework",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",