@musakui/fedi
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -81,12 +81,2 @@ const HS2019 = 'hs2019' | ||
/** | ||
* @typedef {object} SignatureField | ||
* @property {string} keyId | ||
* @property {string} signature | ||
* @property {string} [algorithm] | ||
* @property {string} [headers] signed headers | ||
* @property {number} [created] creation timestamp | ||
* @property {number} [expires] expiry timestamp | ||
*/ | ||
/** | ||
* parse headers from request | ||
@@ -108,5 +98,3 @@ * @param {Partial<Request> & { path?: string }} req | ||
/** | ||
* @type {SignatureField} | ||
*/ | ||
/** @type {import('./types').SignatureField} */ | ||
const sig = Object.fromEntries(req.headers.signature.split(',').map((s) => { | ||
@@ -113,0 +101,0 @@ const m = SIG_REGEX.exec(s.trim()) |
@@ -9,3 +9,3 @@ import * as core from './core.js' | ||
const arr = Array.from(new Uint8Array(buf)) | ||
return btoa(arr.reduce((s, c) => s + String.fromCharCode(c), '')) | ||
return window.btoa(arr.reduce((s, c) => s + String.fromCharCode(c), '')) | ||
} | ||
@@ -12,0 +12,0 @@ |
@@ -1,3 +0,3 @@ | ||
import * as Keys from './keys.js' | ||
import * as WebFinger from './webfinger.js' | ||
import * as Keys from './keys/index.js' | ||
import * as WellKnown from './well-known/index.js' | ||
import * as ActivityPub from './activitypub/index.js' | ||
@@ -8,5 +8,5 @@ import * as ActivityStreams from './activitystreams/index.js' | ||
Keys, | ||
WebFinger, | ||
WellKnown, | ||
ActivityPub, | ||
ActivityStreams, | ||
} |
@@ -10,3 +10,3 @@ { | ||
"repository": "github:musakui/fedi", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"type": "module", | ||
@@ -16,2 +16,3 @@ "files": [ | ||
], | ||
"types": "./lib/types.d.ts", | ||
"exports": { | ||
@@ -24,3 +25,7 @@ "./activitypub": "./lib/activitypub/index.js", | ||
}, | ||
"./webfinger": "./lib/webfinger.js", | ||
"./keys": { | ||
"node": "./lib/keys/node.js", | ||
"default": "./lib/keys/index.js" | ||
}, | ||
"./well-known": "./lib/well-known/index.js", | ||
".": "./lib/index.js" | ||
@@ -27,0 +32,0 @@ }, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15227
18
513